diff options
author | obache <obache@pkgsrc.org> | 2013-10-08 12:06:23 +0000 |
---|---|---|
committer | obache <obache@pkgsrc.org> | 2013-10-08 12:06:23 +0000 |
commit | ac8cc745420dd28ac78b0a3f366200264b7863ce (patch) | |
tree | 6c5d6d8c07c7779367e408f0bb9be93f2fe707ea /inputmethod | |
parent | 7bf92e8c699241cb735fc8937b3fac548084ef98 (diff) | |
download | pkgsrc-ac8cc745420dd28ac78b0a3f366200264b7863ce.tar.gz |
better PKGLOCALEDIR handling with cmake.
Diffstat (limited to 'inputmethod')
6 files changed, 40 insertions, 14 deletions
diff --git a/inputmethod/ibus-chewing/Makefile b/inputmethod/ibus-chewing/Makefile index 7dc73369f74..7f0135aa8a0 100644 --- a/inputmethod/ibus-chewing/Makefile +++ b/inputmethod/ibus-chewing/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.29 2013/09/20 12:19:02 obache Exp $ +# $NetBSD: Makefile,v 1.30 2013/10/08 12:06:23 obache Exp $ # DISTNAME= ibus-chewing-1.4.3-Source @@ -24,12 +24,6 @@ GCONF_SCHEMAS= ibus-chewing.schemas CMAKE_ARGS+= -DLIBEXEC_DIR=${PREFIX}/libexec CMAKE_ARGS+= -DGCONF_SCHEMAS_INSTALLED_DIR=${GCONF_SCHEMAS_DIR} -SUBST_CLASSES+= localedir -SUBST_STAGE.localedir= pre-configure -SUBST_VARS.localedir= PREFIX PKGLOCALEDIR -SUBST_FILES.localedir+= Modules/ManageTranslation.cmake -SUBST_FILES.localedir+= src/main.c - .include "../../devel/GConf/schemas.mk" .include "../../inputmethod/ibus/buildlink3.mk" .include "../../inputmethod/libchewing/buildlink3.mk" diff --git a/inputmethod/ibus-chewing/distinfo b/inputmethod/ibus-chewing/distinfo index 98ac2b80574..491c78e6b05 100644 --- a/inputmethod/ibus-chewing/distinfo +++ b/inputmethod/ibus-chewing/distinfo @@ -1,8 +1,10 @@ -$NetBSD: distinfo,v 1.11 2013/09/20 12:19:02 obache Exp $ +$NetBSD: distinfo,v 1.12 2013/10/08 12:06:23 obache Exp $ SHA1 (ibus-chewing-1.4.3-Source.tar.gz) = 82ec86daf2b7f3de88410ec01c9f41db0184f91e RMD160 (ibus-chewing-1.4.3-Source.tar.gz) = b08e2f0a34c0168a3b69c6273ac614f81fdb2d0f Size (ibus-chewing-1.4.3-Source.tar.gz) = 84023 bytes SHA1 (patch-Modules_DateTimeFormat.cmake) = 588068914de5db765c1c5d1a623e3b73f720a64f -SHA1 (patch-Modules_ManageTranslation.cmake) = b4b4873e040b64c209e93f0574f4544c440ee575 -SHA1 (patch-src_main.c) = e273965ddc2880471b3dcdd0d468facd1b793582 +SHA1 (patch-Modules_ManageEnvironment.cmake) = 333c7aa542d0555c7bb9cd3913e73a205c0dea94 +SHA1 (patch-Modules_ManageTranslation.cmake) = c5d94a9a7b897aaf932922b2b06e2a7f7f4e234d +SHA1 (patch-src_generate-gconf-schemas.c) = 8800a1ab67dce1848dc516e26c38cece46b9ffab +SHA1 (patch-src_main.c) = cd160807386097de5bee3e24f8bbaae3c420d2d5 diff --git a/inputmethod/ibus-chewing/patches/patch-Modules_ManageEnvironment.cmake b/inputmethod/ibus-chewing/patches/patch-Modules_ManageEnvironment.cmake new file mode 100644 index 00000000000..d2becd5a21b --- /dev/null +++ b/inputmethod/ibus-chewing/patches/patch-Modules_ManageEnvironment.cmake @@ -0,0 +1,15 @@ +$NetBSD: patch-Modules_ManageEnvironment.cmake,v 1.1 2013/10/08 12:06:23 obache Exp $ + +* PKGLOCALEDIR support + +--- Modules/ManageEnvironment.cmake.orig 2012-11-26 07:37:40.000000000 +0000 ++++ Modules/ManageEnvironment.cmake +@@ -163,6 +163,8 @@ IF(NOT DEFINED _MANAGE_ENVIRONMENT_CMAKE + CACHE PATH "Data dir") + SET_COMPILE_ENV(DOC_DIR "${DATA_DIR}/doc" + CACHE PATH "Documentation dir") ++ SET_COMPILE_ENV(LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LOCALEDIR}" ++ CACHE PATH "Locale dir") + SET_COMPILE_ENV(SYSCONF_DIR "/etc" + CACHE PATH "System configuration dir") + SET_COMPILE_ENV(LIBEXEC_DIR "${CMAKE_INSTALL_PREFIX}/libexec" diff --git a/inputmethod/ibus-chewing/patches/patch-Modules_ManageTranslation.cmake b/inputmethod/ibus-chewing/patches/patch-Modules_ManageTranslation.cmake index d047244b94a..c99439dfc97 100644 --- a/inputmethod/ibus-chewing/patches/patch-Modules_ManageTranslation.cmake +++ b/inputmethod/ibus-chewing/patches/patch-Modules_ManageTranslation.cmake @@ -1,4 +1,4 @@ -$NetBSD: patch-Modules_ManageTranslation.cmake,v 1.1 2013/09/20 11:51:44 obache Exp $ +$NetBSD: patch-Modules_ManageTranslation.cmake,v 1.2 2013/10/08 12:06:23 obache Exp $ * PKGLOCALEDIR support @@ -9,7 +9,7 @@ $NetBSD: patch-Modules_ManageTranslation.cmake,v 1.1 2013/09/20 11:51:44 obache #MESSAGE("_absPoFile=${_absPoFile} _absPotDir=${_absPotDir} _lang=${_lang} curr_bin=${CMAKE_CURRENT_BINARY_DIR}") - INSTALL(FILES ${_absGmoFile} DESTINATION share/locale/${_locale}/LC_MESSAGES RENAME ${_potBasename}.mo) -+ INSTALL(FILES ${_absGmoFile} DESTINATION @PKGLOCALEDIR@/locale/${_locale}/LC_MESSAGES RENAME ${_potBasename}.mo) ++ INSTALL(FILES ${_absGmoFile} DESTINATION ${CMAKE_INSTALL_LOCALEDIR}/${_locale}/LC_MESSAGES RENAME ${_potBasename}.mo) LIST(APPEND _absGmoFileList ${_absGmoFile}) LIST(APPEND _absPoFileList ${_absPoFile}) ENDFOREACH(_locale ${_localeList}) diff --git a/inputmethod/ibus-chewing/patches/patch-src_generate-gconf-schemas.c b/inputmethod/ibus-chewing/patches/patch-src_generate-gconf-schemas.c new file mode 100644 index 00000000000..7c8c53646f1 --- /dev/null +++ b/inputmethod/ibus-chewing/patches/patch-src_generate-gconf-schemas.c @@ -0,0 +1,15 @@ +$NetBSD: patch-src_generate-gconf-schemas.c,v 1.1 2013/10/08 12:06:23 obache Exp $ + +* PKGLOCALEDIR support + +--- src/generate-gconf-schemas.c.orig 2012-10-22 05:32:11.000000000 +0000 ++++ src/generate-gconf-schemas.c +@@ -41,7 +41,7 @@ int main (gint argc, gchar *argv[]) + + /* Init i18n messages */ + setlocale (LC_ALL, ""); +- bindtextdomain(quote_me(PROJECT_NAME), quote_me(DATA_DIR) "/locale"); ++ bindtextdomain(quote_me(PROJECT_NAME), quote_me(LOCALE_DIR)); + textdomain(quote_me(PROJECT_NAME)); + + context = g_option_context_new("schemasFile"); diff --git a/inputmethod/ibus-chewing/patches/patch-src_main.c b/inputmethod/ibus-chewing/patches/patch-src_main.c index ec3f1f849cb..78485117cac 100644 --- a/inputmethod/ibus-chewing/patches/patch-src_main.c +++ b/inputmethod/ibus-chewing/patches/patch-src_main.c @@ -1,4 +1,4 @@ -$NetBSD: patch-src_main.c,v 1.2 2013/09/20 12:19:02 obache Exp $ +$NetBSD: patch-src_main.c,v 1.3 2013/10/08 12:06:23 obache Exp $ * PKGLOCALEDIR support @@ -9,7 +9,7 @@ $NetBSD: patch-src_main.c,v 1.2 2013/09/20 12:19:02 obache Exp $ /* Init i18n messages */ setlocale (LC_ALL, "zh_TW.utf8"); - bindtextdomain(quote_me(PROJECT_NAME), quote_me(DATA_DIR) "/locale"); -+ bindtextdomain(quote_me(PROJECT_NAME), "@PREFIX@/@PKGLOCALEDIR@/locale"); ++ bindtextdomain(quote_me(PROJECT_NAME), quote_me(LOCALE_DIR)); textdomain(quote_me(PROJECT_NAME)); context = g_option_context_new ("- ibus chewing engine component"); |