diff options
author | ryoon <ryoon> | 2013-09-07 18:42:14 +0000 |
---|---|---|
committer | ryoon <ryoon> | 2013-09-07 18:42:14 +0000 |
commit | 5309b2109c97f6692204e951cf1b96890a08e822 (patch) | |
tree | b40873cb2f5330b0da25017483b1195c74119a74 /inputmethod/mozc-server | |
parent | b92fdfbe1bdbc381ffe9934e436a724f4de0de19 (diff) | |
download | pkgsrc-5309b2109c97f6692204e951cf1b96890a08e822.tar.gz |
Update to 1.11.1522.102
* Use renderer for ibus-mozc, new candidates window.
Changelog:
r171 2013-08-28 1.11.1522.102
FIX: Safari crashes when surrounding text is requested.
FIX: Mode symbol on the mode indicator is not rendered on Windows.
FIX: Caret position is not updated after commit in WPF's TextBox on Windows.
FIX: UI is not placed at proper position when HiDPI is enabled on Windows 8.1
FIX: GDI handles are not destroyed when classic theme is selected on Windows.
FIX: Fails to connect to mozc_renderer from explorer.exe on Windows.
Enable Touch-optimized on-screen keyboard on Windows 8+.
Enable a developer to configure ibus-mozc path and/or ibus-mozc icon path at build time for GNU/Linux build. See the build instruction about how to customize them. ( Issue 41 )
Add Session command for ConvertPrevPage and ConvertNextPage ( Issue 188 )
Remove ibus-mozc-chewing (Issue 194)
Remove ibus-mozc-pinyin (Issue 194)
Diffstat (limited to 'inputmethod/mozc-server')
21 files changed, 187 insertions, 155 deletions
diff --git a/inputmethod/mozc-server/Makefile b/inputmethod/mozc-server/Makefile index d0497a68028..d85cdffbcf4 100644 --- a/inputmethod/mozc-server/Makefile +++ b/inputmethod/mozc-server/Makefile @@ -1,7 +1,6 @@ -# $NetBSD: Makefile,v 1.11 2013/09/02 19:51:12 adam Exp $ +# $NetBSD: Makefile,v 1.12 2013/09/07 18:42:14 ryoon Exp $ PKGNAME= ${DISTNAME:S/mozc-/mozc-server-/} -PKGREVISION= 1 INSTALLATION_DIRS+= libexec diff --git a/inputmethod/mozc-server/Makefile.common b/inputmethod/mozc-server/Makefile.common index fcd25cd2219..825a27323c3 100644 --- a/inputmethod/mozc-server/Makefile.common +++ b/inputmethod/mozc-server/Makefile.common @@ -1,11 +1,11 @@ -# $NetBSD: Makefile.common,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +# $NetBSD: Makefile.common,v 1.3 2013/09/07 18:42:14 ryoon Exp $ # used by inputmethod/ibus-mozc/Makefile # used by inputmethod/mozc-elisp/Makefile # used by inputmethod/mozc-server/Makefile # used by inputmethod/mozc-tool/Makefile # -DISTNAME= mozc-1.11.1502.102 +DISTNAME= mozc-1.11.1522.102 CATEGORIES= inputmethod MASTER_SITES= http://mozc.googlecode.com/files/ EXTRACT_SUFX= .tar.bz2 @@ -59,8 +59,10 @@ MOZC_BUILD_MODE= Release # or Debug do-configure: cd ${WRKSRC} && env ${MAKE_ENV} \ GYP_DEFINES="use_libprotobuf=1" \ - ${PYTHONBIN} build_mozc.py gyp --os=${LOWER_OPSYS} && \ - ${PYTHONBIN} build_mozc.py build_tools -c ${MOZC_BUILD_MODE} ${_MAKE_JOBS} + ${PYTHONBIN} build_mozc.py gyp --os=${LOWER_OPSYS} \ + --gypdir=${GYPDIR}/bin && \ + ${PYTHONBIN} build_mozc.py build_tools -c ${MOZC_BUILD_MODE} \ + ${_MAKE_JOBS} .include "../../devel/glib2/buildlink3.mk" .include "../../devel/protobuf/buildlink3.mk" diff --git a/inputmethod/mozc-server/distinfo b/inputmethod/mozc-server/distinfo index 669acb4eca8..db6bbd3ed69 100644 --- a/inputmethod/mozc-server/distinfo +++ b/inputmethod/mozc-server/distinfo @@ -1,50 +1,48 @@ -$NetBSD: distinfo,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: distinfo,v 1.3 2013/09/07 18:42:14 ryoon Exp $ -SHA1 (mozc-1.11.1502.102.tar.bz2) = 72c06d409da957d6696bbe1341c118ba4c267877 -RMD160 (mozc-1.11.1502.102.tar.bz2) = 6cee5948fb7e0ab6dc49022caa51a55611ece179 -Size (mozc-1.11.1502.102.tar.bz2) = 58777653 bytes +SHA1 (mozc-1.11.1522.102.tar.bz2) = 0859efcbc6ddb93d9cf5a6e0d27ab8da0a72a1ee +RMD160 (mozc-1.11.1522.102.tar.bz2) = fa08b2433cf42bbb346a19414b268ccb695ed541 +Size (mozc-1.11.1522.102.tar.bz2) = 58418005 bytes SHA1 (patch-base_base.gyp) = 329bd8614282aca28fcba30b2e593f488801118d SHA1 (patch-base_cpu__stats.cc) = cda8bbcbc963d8ed635435375cc80ee5e7ca2191 -SHA1 (patch-base_crash__report__handler.cc) = 210d3750b5252f19e030c1b235d8e8b65ea38fab +SHA1 (patch-base_crash__report__handler.cc) = c901dbb2c8f18d18b479486b2d25ff09b3de356b SHA1 (patch-base_iconv.cc) = 1bf65dfc6152bf152cbe2714835a61436df2a48b SHA1 (patch-base_logging.cc) = 62259820d980bb7e6ddf81b6d168348a46371b40 -SHA1 (patch-base_mutex.cc) = 3a002e5d2430bc62c29950d3602255503753608c +SHA1 (patch-base_mutex.cc) = aed8588d4ff7b057fed072097ef09ddbc2696d31 SHA1 (patch-base_mutex.h) = 6c3c8f0845f0fdad815c4877026894000d5eac2c SHA1 (patch-base_password__manager.cc) = cb11b9b707ab0c361c969eefd4d7c805c0b4b06a -SHA1 (patch-base_process.cc) = 0979686b20ea4b2e77ffb1bda8fd955baa25d7e1 +SHA1 (patch-base_process.cc) = abdd6a955e87506972e7f71fd4bc3a300f49b304 SHA1 (patch-base_run__level.cc) = 8aa169a8be51674898906740cb8f6103b99021b4 -SHA1 (patch-base_system__util.cc) = 5866a8c83f81f060eebf5ec3b67aa4491fdb6dd0 +SHA1 (patch-base_system__util.cc) = f3ef575a15cd518fe7d29264b39f775ccf502802 SHA1 (patch-base_thread.h) = 8aaacbb1421cf0e886f3b58dfd2c653f3d82ef70 -SHA1 (patch-base_util.cc) = db13648d8127e94ec9575752692f31bf81bac68d -SHA1 (patch-build__mozc.py) = 377294ac8c8ccf6b55a63632e9a512f15c479989 +SHA1 (patch-base_util.cc) = c473cb595535075b53c9c235fc28f5e7da26d087 +SHA1 (patch-build__mozc.py) = 76ea6874270348a21059b208894894258f6d4467 SHA1 (patch-build__tools_mozc__version.py) = 47460ca750d8d28652c5c55e5df9b786af4d33c7 -SHA1 (patch-build__tools_util.py) = 1700f2c061bd2501dc78370198cded8cfe7c851a +SHA1 (patch-build__tools_util.py) = 6416884ba288d60eb8e558e8c5de7ef6e538b82e SHA1 (patch-client_client.cc) = 7ca43dde3f207331005599653c6520667e3ca93c SHA1 (patch-config_stats__config__util__test.cc) = db51e6619c5c04ac8fa50890825206ea922dccf2 SHA1 (patch-gui_base_locale__util.cc) = 7d1e9cf3c2c36590298496471a97b8c32010a30b -SHA1 (patch-gui_config__dialog_config__dialog.cc) = e8d1f9adeb9dbc9f25deee82e4ace692d92eeb46 +SHA1 (patch-gui_config__dialog_config__dialog.cc) = 1e53b37c085bd7bdb3d2d2088e4a93b877aadc64 SHA1 (patch-gui_config__dialog_keybinding__editor.cc) = 00a6e4bb2c07e3340e188f108f0285a3aa2aceb9 SHA1 (patch-gui_config__dialog_keymap__editor.cc) = a78a4fb5c484e672b0cfecf38c6713cf74007cb5 -SHA1 (patch-gui_dictionary__tool_dictionary__tool.cc) = d08cc3a91794d0f8eb59a105d0c94eb3f02c0133 -SHA1 (patch-gui_gui.gyp) = a27d0a0a3fb6893a691450917cf2798ace1647ed -SHA1 (patch-gui_qt__libraries.gypi) = 9faaac9b9fc891050e27b4be0fd899265f4a1173 +SHA1 (patch-gui_dictionary__tool_dictionary__tool.cc) = 015d69de20a02eff2a1c2f5de5c3924a1474f83b +SHA1 (patch-gui_gui.gyp) = 70b6d78ca5a482b9e8fa697dbb191cccbdde1c6a +SHA1 (patch-gui_qt__libraries.gypi) = 2b00307c22380d0d1c60b5d98ce08970b0e74f09 SHA1 (patch-gui_word__register__dialog_word__register__dialog.cc) = 34a7cd2a99a0082f490c3f623c7c6a856c984f8b SHA1 (patch-gui_zinnia.gyp) = 0eaad35b829d2c25e751ce6e99207781306934d5 -SHA1 (patch-gyp_common.gypi) = 3a90f34d6f1a34d264abbf59891fd363dbd00848 +SHA1 (patch-gyp_common.gypi) = af22172e630cc742c789ea2d89720bb9897c7f0a SHA1 (patch-handwriting_handwriting.gyp) = 608e45f7bc4edcd434929d9e3a5cb05cee723abc SHA1 (patch-handwriting_zinnia__handwriting.cc) = dd9363f470bf4a27fed40602f02127cb130042b2 SHA1 (patch-ipc_ipc__path__manager.cc) = a424e9eabdfa9cb66492fc85ecf9c2659c8e35f9 SHA1 (patch-ipc_ipc__path__manager__test.cc) = 90ea81daef93dc1ad5cee792ced26a9a2939fbdf SHA1 (patch-ipc_named__event.cc) = 92283261e7580569587e43156f13567b593c9a32 -SHA1 (patch-ipc_unix__ipc.cc) = 5b314ca3eaa0a0036796b98c47d791451688002d -SHA1 (patch-languages_chewing_chewing.gyp) = 26fa18398911609a53cff003943436f003772e64 +SHA1 (patch-ipc_unix__ipc.cc) = d821deb2f38bf77bf6b364eb31d419c0a86c1a7f SHA1 (patch-languages_hangul_hangul.gyp) = 685964cd31e91c96f0d41e729441b17ed9ac24f8 SHA1 (patch-net_net.gyp) = 937b28ad663605373d6b772097318b17dbea2eea -SHA1 (patch-protobuf_genproto.gypi) = c547573192c666607c26d999f60153283c794208 +SHA1 (patch-protobuf_genproto.gypi) = 601165a376bcd05983f87733285737ee043c13fe SHA1 (patch-protobuf_protobuf.gyp) = 41c7fd41e89e163b02b40d4b44947604b3730b79 -SHA1 (patch-session_session.cc) = 1ca8d62e9bff202cbaaec1bd3503c6df4843b13e +SHA1 (patch-session_session.cc) = 0562f8646dc6f68e180d8ae98f00eeb0364fc473 SHA1 (patch-session_session__converter__interface.h) = 93bda6e51b9a9ac7146aa23ac0aa28bb017a4465 SHA1 (patch-session_session__test.cc) = a256caec45a45f4eaab0555ecc18cea09c417d95 -SHA1 (patch-third__party_gyp_buildbot_buildbot__run.py) = 21375df1c6c19233c66b24da4dc23ddad5515b72 -SHA1 (patch-unix_ibus_gen__mozc__xml.py) = 58f6347e8ff448895d2e5996066c8d0d91ffe7ae +SHA1 (patch-unix_ibus_gen__mozc__xml.py) = d2ab62853919a964d3edf574a391d83e9c5e02bd SHA1 (patch-unix_ibus_mozc__engine.cc) = 2ce0a680a0fad1abdc646737b6b5a4c3a9e87e6e diff --git a/inputmethod/mozc-server/patches/patch-base_crash__report__handler.cc b/inputmethod/mozc-server/patches/patch-base_crash__report__handler.cc index f52e63fe70a..8d36aead7b3 100644 --- a/inputmethod/mozc-server/patches/patch-base_crash__report__handler.cc +++ b/inputmethod/mozc-server/patches/patch-base_crash__report__handler.cc @@ -1,13 +1,19 @@ -$NetBSD: patch-base_crash__report__handler.cc,v 1.1 2013/04/29 09:52:16 ryoon Exp $ +$NetBSD: patch-base_crash__report__handler.cc,v 1.2 2013/09/07 18:42:14 ryoon Exp $ ---- base/crash_report_handler.cc.orig 2013-03-29 04:33:43.000000000 +0000 +--- base/crash_report_handler.cc.orig 2013-08-28 05:26:13.000000000 +0000 +++ base/crash_report_handler.cc -@@ -364,7 +364,7 @@ void CrashReportHandler::SetCriticalSect +@@ -321,7 +321,7 @@ void CrashReportHandler::SetCriticalSect } } // namespace mozc -#elif defined(OS_LINUX) // OS_WIN -+#elif defined(OS_LINUX) || defined(OS_NETBSD) // OS_WIN ++#elif defined(OS_LINUX) || defined(OS_NETBSD) // OS_WIN namespace mozc { +@@ -341,4 +341,4 @@ bool CrashReportHandler::Uninitialize() + + } // namespace mozc + +-#endif // OS_WIN OS_LINUX ++#endif // OS_WIN OS_LINUX OS_NETBSD diff --git a/inputmethod/mozc-server/patches/patch-base_mutex.cc b/inputmethod/mozc-server/patches/patch-base_mutex.cc index df6b01d97be..744bb47e642 100644 --- a/inputmethod/mozc-server/patches/patch-base_mutex.cc +++ b/inputmethod/mozc-server/patches/patch-base_mutex.cc @@ -1,6 +1,6 @@ -$NetBSD: patch-base_mutex.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-base_mutex.cc,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- base/mutex.cc.orig 2013-07-17 02:38:04.000000000 +0000 +--- base/mutex.cc.orig 2013-08-28 05:26:13.000000000 +0000 +++ base/mutex.cc @@ -61,7 +61,7 @@ namespace mozc { diff --git a/inputmethod/mozc-server/patches/patch-base_process.cc b/inputmethod/mozc-server/patches/patch-base_process.cc index be3fe5044af..635f315fb10 100644 --- a/inputmethod/mozc-server/patches/patch-base_process.cc +++ b/inputmethod/mozc-server/patches/patch-base_process.cc @@ -1,6 +1,6 @@ -$NetBSD: patch-base_process.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-base_process.cc,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- base/process.cc.orig 2013-07-17 02:38:04.000000000 +0000 +--- base/process.cc.orig 2013-08-28 05:26:13.000000000 +0000 +++ base/process.cc @@ -46,7 +46,7 @@ #include "base/mac_process.h" @@ -11,7 +11,7 @@ $NetBSD: patch-base_process.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ #include <fcntl.h> #include <signal.h> #include <spawn.h> // for posix_spawn(). -@@ -121,8 +121,8 @@ bool Process::OpenBrowser(const string & +@@ -121,12 +121,12 @@ bool Process::OpenBrowser(const string & return ShellExecuteInSystemDir(L"open", wurl.c_str(), NULL, SW_SHOW); #endif @@ -22,6 +22,11 @@ $NetBSD: patch-base_process.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ // xdg-open which uses kfmclient or gnome-open internally works both on KDE // and GNOME environments. return SpawnProcess(kBrowserCommand, url); +-#endif // LINUX ++#endif // OS_LINUX || OS_NETBSD + + #ifdef OS_MACOSX + return MacProcess::OpenBrowserForMac(url); @@ -205,7 +205,7 @@ bool Process::SpawnProcess(const string } #endif diff --git a/inputmethod/mozc-server/patches/patch-base_system__util.cc b/inputmethod/mozc-server/patches/patch-base_system__util.cc index c0844988ee9..8fe5eb92ce1 100644 --- a/inputmethod/mozc-server/patches/patch-base_system__util.cc +++ b/inputmethod/mozc-server/patches/patch-base_system__util.cc @@ -1,6 +1,6 @@ -$NetBSD: patch-base_system__util.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-base_system__util.cc,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- base/system_util.cc.orig 2013-07-17 02:38:04.000000000 +0000 +--- base/system_util.cc.orig 2013-08-28 05:26:13.000000000 +0000 +++ base/system_util.cc @@ -421,14 +421,14 @@ string SystemUtil::GetServerDirectory() #elif defined(OS_MACOSX) @@ -20,7 +20,16 @@ $NetBSD: patch-base_system__util.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ } string SystemUtil::GetServerPath() { -@@ -616,7 +616,7 @@ bool GetCurrentSessionId(DWORD *session_ +@@ -493,7 +493,7 @@ string SystemUtil::GetUserNameAsString() + return ppw->pw_name; + + #else // OS_ANDROID +- // OS_MACOSX or OS_LINUX ++ // OS_MACOSX or OS_LINUX, OS_NETBSD + struct passwd pw, *ppw; + char buf[1024]; + CHECK_EQ(0, getpwuid_r(geteuid(), &pw, buf, sizeof(buf), &ppw)); +@@ -653,7 +653,7 @@ string GetSessionIdString() { #endif // OS_WIN string SystemUtil::GetDesktopNameAsString() { @@ -29,7 +38,16 @@ $NetBSD: patch-base_system__util.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ const char *display = getenv("DISPLAY"); if (display == NULL) { return ""; -@@ -815,7 +815,7 @@ bool SystemUtil::IsPlatformSupported() { +@@ -683,7 +683,7 @@ string SystemUtil::GetDesktopNameAsStrin + } + + return (session_id + "." + window_station_name + "." + desktop_name); +-#endif // OS_LINUX, OS_MACOSX, OS_WIN ++#endif // OS_LINUX, OS_MACOSX, OS_WIN, OS_NETBSD + } + + #ifdef OS_WIN +@@ -858,7 +858,7 @@ bool SystemUtil::IsPlatformSupported() { #if defined(OS_MACOSX) // TODO(yukawa): support Mac. return true; @@ -38,7 +56,7 @@ $NetBSD: patch-base_system__util.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ // TODO(yukawa): support Linux. return true; #elif defined(OS_WIN) -@@ -1104,10 +1104,13 @@ string SystemUtil::GetOSVersionString() +@@ -1157,10 +1157,13 @@ string SystemUtil::GetOSVersionString() #elif defined(OS_LINUX) const string ret = "Linux"; return ret; @@ -54,7 +72,7 @@ $NetBSD: patch-base_system__util.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ } bool SystemUtil::MacOSVersionIsGreaterOrEqual(int32 major, -@@ -1151,7 +1154,7 @@ uint64 SystemUtil::GetTotalPhysicalMemor +@@ -1204,7 +1207,7 @@ uint64 SystemUtil::GetTotalPhysicalMemor return 0; } return total_memory; diff --git a/inputmethod/mozc-server/patches/patch-base_util.cc b/inputmethod/mozc-server/patches/patch-base_util.cc index 446e6843109..e4683a1d9c0 100644 --- a/inputmethod/mozc-server/patches/patch-base_util.cc +++ b/inputmethod/mozc-server/patches/patch-base_util.cc @@ -1,6 +1,6 @@ -$NetBSD: patch-base_util.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-base_util.cc,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- base/util.cc.orig 2013-07-17 02:38:04.000000000 +0000 +--- base/util.cc.orig 2013-08-28 05:26:13.000000000 +0000 +++ base/util.cc @@ -1087,15 +1087,15 @@ class ClockImpl : public Util::ClockInte mach_timebase_info(&timebase_info); @@ -14,10 +14,10 @@ $NetBSD: patch-base_util.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ return 1000000uLL; #endif // HAVE_LIBRT -#else // platforms (OS_WIN, OS_MACOSX, OS_LINUX, ...) -+#else // platforms (OS_WIN, OS_MACOSX, OS_LINUX, OS_NETBSD, ...) ++#else // platforms (OS_WIN, OS_MACOSX, OS_LINUX, OS_NETBSD ...) #error "Not supported platform" -#endif // platforms (OS_WIN, OS_MACOSX, OS_LINUX, ...) -+#endif // platforms (OS_WIN, OS_MACOSX, OS_LINUX, OS_NETBSD. ...) ++#endif // platforms (OS_WIN, OS_MACOSX, OS_LINUX, OS_NETBSD ...) } virtual uint64 GetTicks() { diff --git a/inputmethod/mozc-server/patches/patch-build__mozc.py b/inputmethod/mozc-server/patches/patch-build__mozc.py index 02495aab04d..21ccb3b5f2a 100644 --- a/inputmethod/mozc-server/patches/patch-build__mozc.py +++ b/inputmethod/mozc-server/patches/patch-build__mozc.py @@ -1,15 +1,15 @@ -$NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-build__mozc.py,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- build_mozc.py.orig 2013-07-17 02:37:50.000000000 +0000 +--- build_mozc.py.orig 2013-08-28 05:25:59.000000000 +0000 +++ build_mozc.py -@@ -62,6 +62,7 @@ from build_tools.util import GetRelPath +@@ -60,6 +60,7 @@ from build_tools.util import FindFileFro + from build_tools.util import GetNumberOfProcessors + from build_tools.util import GetRelPath from build_tools.util import IsLinux ++from build_tools.util import IsNetBSD from build_tools.util import IsMac from build_tools.util import IsWindows -+from build_tools.util import IsNetBSD from build_tools.util import PrintErrorAndExit - from build_tools.util import RemoveDirectoryRecursively - from build_tools.util import RemoveFile @@ -116,6 +117,8 @@ def GetBuildBaseName(options, target_pla build_base = 'out_mac' elif target_platform == 'Linux' or target_platform == 'ChromeOS': @@ -19,7 +19,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ elif target_platform == 'Android': build_base = 'out_android' elif target_platform == 'NaCl': -@@ -219,6 +222,12 @@ def GetGypFileNames(options): +@@ -224,6 +227,12 @@ def GetGypFileNames(options): if not PkgExists('ibus-1.0 >= 1.4.1'): logging.info('removing ibus.gyp.') gyp_file_names.remove('%s/unix/ibus/ibus.gyp' % SRC_DIR) @@ -32,7 +32,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ elif options.target_platform == 'ChromeOS': gyp_file_names.extend(glob.glob('%s/unix/ibus/*.gyp' % SRC_DIR)) elif options.target_platform == 'NaCl': -@@ -266,6 +275,7 @@ def AddCommonOptions(parser): +@@ -260,6 +269,7 @@ def AddCommonOptions(parser): help='Specifies the base directory of the built binaries.') parser.add_option('--language', dest='language', default='japanese', help='Specify the target language to build.') @@ -40,7 +40,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ return parser -@@ -286,6 +296,8 @@ def AddTargetPlatformOption(parser): +@@ -280,6 +290,8 @@ def AddTargetPlatformOption(parser): # If you want Android build, specify "Android". if IsLinux(): default_target = 'Linux' @@ -49,7 +49,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ elif IsWindows(): default_target = 'Windows' elif IsMac(): -@@ -490,6 +502,12 @@ def ExpandMetaTarget(options, meta_targe +@@ -478,6 +490,12 @@ def ExpandMetaTarget(options, meta_targe SRC_DIR + '/gui/gui.gyp:mozc_tool'] if PkgExists('ibus-1.0 >= 1.4.1'): targets.append(SRC_DIR + '/unix/ibus/ibus.gyp:ibus_mozc') @@ -62,7 +62,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ elif target_platform == 'ChromeOS': targets.append(SRC_DIR + '/unix/ibus/ibus.gyp:ibus_mozc') elif target_platform == 'Mac': -@@ -517,7 +535,7 @@ def ParseBuildOptions(args=None, values= +@@ -505,7 +523,7 @@ def ParseBuildOptions(args=None, values= """Parses command line options for the build command.""" parser = optparse.OptionParser(usage='Usage: %prog build [options]') AddCommonOptions(parser) @@ -71,16 +71,16 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ default_build_concurrency = GetNumberOfProcessors() * 2 parser.add_option('--jobs', '-j', dest='jobs', default=('%d' % default_build_concurrency), -@@ -537,7 +555,7 @@ def ParseRunTestsOptions(args=None, valu +@@ -525,7 +543,7 @@ def ParseRunTestsOptions(args=None, valu parser = optparse.OptionParser( usage='Usage: %prog runtests [options] [test_targets] [-- build options]') AddCommonOptions(parser) - if IsLinux(): -+ if IsLinux() or IsNetBSD(): ++ if IsLinux() or ISNetBSD(): default_build_concurrency = GetNumberOfProcessors() * 2 parser.add_option('--jobs', '-j', dest='jobs', default=('%d' % default_build_concurrency), -@@ -705,6 +723,8 @@ def GypMain(options, unused_args): +@@ -693,6 +711,8 @@ def GypMain(options, unused_args): command_line.extend(['-D', 'wix_dir=%s' % options.wix_dir]) else: command_line.extend(['-D', 'use_wix=NO']) @@ -89,7 +89,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ android_sdk_home = options.android_sdk_home if version.GetTargetPlatform() == 'Android': -@@ -767,7 +787,7 @@ def GypMain(options, unused_args): +@@ -755,7 +775,7 @@ def GypMain(options, unused_args): def SetCommandLineForFeature(option_name, windows=False, mac=False, linux=False, chromeos=False, android=False, @@ -98,53 +98,51 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ """Updates an option like '--enable_foober' and add a -D argument for gyp. This function ensures an option like '--enable_foober' exists and it has a -@@ -791,6 +811,8 @@ def GypMain(options, unused_args): +@@ -779,6 +799,8 @@ def GypMain(options, unused_args): option on Android platform. nacl: A boolean which replesents the default value of the target option on NaCl. + netbsd: boolean which replesents the default value of the target option -+ on NetBSD platform. ++ on NetBSD platform. Raises: ValueError: An error occurred when 'option_name' is empty. -@@ -804,6 +826,7 @@ def GypMain(options, unused_args): +@@ -792,6 +814,7 @@ def GypMain(options, unused_args): 'Linux': linux, 'ChromeOS': chromeos, 'Android': android, -+ 'NetBSD' : netbsd, ++ 'NetBSD' : netbsd, 'NaCl': nacl}[options.target_platform] enable_option_name = 'enable_%s' % option_name enabled = options.ensure_value(enable_option_name, default_enabled) -@@ -820,15 +843,18 @@ def GypMain(options, unused_args): +@@ -808,15 +831,18 @@ def GypMain(options, unused_args): SetCommandLineForFeature(option_name='webservice_infolist') SetCommandLineForFeature(option_name='cloud_sync', linux=is_official_dev, -+ netbsd=is_official_dev, ++ netbsd=is_official_dev, windows=is_official_dev, mac=is_official_dev, nacl=is_official_dev) SetCommandLineForFeature(option_name='cloud_handwriting', linux=is_official_dev, -+ netbsd=is_official_dev, ++ netbsd=is_official_dev, windows=is_official_dev, mac=is_official_dev) SetCommandLineForFeature(option_name='http_client', - linux=is_official, -+ netbsd=is_official, + linux=False, ++ netbsd=is_official_dev, windows=is_official, mac=is_official, chromeos=False, # not supported. -@@ -872,7 +898,8 @@ def GypMain(options, unused_args): +@@ -856,6 +882,7 @@ def GypMain(options, unused_args): command_line.extend(['-D', 'use_zinnia=NO']) if ((options.target_platform == 'Linux' or -- options.target_platform == 'ChromeOS') and -+ options.target_platform == 'ChromeOS' or -+ options.target_platform == 'NetBSD') and ++ options.target_platform == 'NetBSD' or + options.target_platform == 'ChromeOS') and '%s/unix/ibus/ibus.gyp' % SRC_DIR in gyp_file_names): command_line.extend(['-D', 'use_libibus=1']) - -@@ -917,7 +944,7 @@ def GypMain(options, unused_args): +@@ -901,7 +928,7 @@ def GypMain(options, unused_args): # command for pkg-config. Here we catch the environment variable # and use the specified command instead of actual pkg-config # command. @@ -153,7 +151,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ command_line.extend(['-D', 'pkg_config_command=%s' % GetPkgConfigCommand()]) else: command_line.extend(['-D', 'pkg_config_command=']) -@@ -1082,6 +1109,41 @@ def BuildOnMac(options, targets, origina +@@ -1066,6 +1093,41 @@ def BuildOnMac(options, targets, origina '-parallelizeTargets', 'BUILD_WITH_GYP=1']) @@ -195,7 +193,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ def BuildOnWindows(targets): """Build the target on Windows.""" -@@ -1112,6 +1174,8 @@ def BuildMain(options, targets, original +@@ -1096,6 +1158,8 @@ def BuildMain(options, targets, original BuildOnMac(options, targets, original_directory_name) elif IsLinux(): BuildOnLinux(options, targets, original_directory_name) @@ -204,7 +202,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ elif IsWindows(): BuildOnWindows(targets) else: -@@ -1388,7 +1452,7 @@ def CleanBuildFilesAndDirectories(option +@@ -1367,7 +1431,7 @@ def CleanBuildFilesAndDirectories(option elif IsMac(): directory_names.extend(glob.glob(os.path.join(gyp_directory_name, '*.xcodeproj'))) @@ -213,7 +211,7 @@ $NetBSD: patch-build__mozc.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ file_names.extend(glob.glob(os.path.join(gyp_directory_name, '*.target.mk'))) file_names.extend(glob.glob(os.path.join(gyp_directory_name, -@@ -1436,6 +1500,9 @@ def CleanBuildFilesAndDirectories(option +@@ -1415,6 +1479,9 @@ def CleanBuildFilesAndDirectories(option elif IsWindows(): file_names.append('third_party/breakpad/breakpad.gyp') diff --git a/inputmethod/mozc-server/patches/patch-build__tools_util.py b/inputmethod/mozc-server/patches/patch-build__tools_util.py index f9d4e0d1592..95c4d368bfd 100644 --- a/inputmethod/mozc-server/patches/patch-build__tools_util.py +++ b/inputmethod/mozc-server/patches/patch-build__tools_util.py @@ -1,15 +1,14 @@ -$NetBSD: patch-build__tools_util.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-build__tools_util.py,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- build_tools/util.py.orig 2013-07-17 02:37:50.000000000 +0000 +--- build_tools/util.py.orig 2013-08-28 05:25:59.000000000 +0000 +++ build_tools/util.py -@@ -56,6 +56,10 @@ def IsLinux(): +@@ -56,6 +56,9 @@ def IsLinux(): """Returns true if the platform is Linux.""" return os.name == 'posix' and os.uname()[0] == 'Linux' +def IsNetBSD(): + """Returns true if the platform is NetBSD.""" + return os.name == 'posix' and os.uname()[0] == 'NetBSD' -+ def GetNumberOfProcessors(): """Returns the number of CPU cores available. diff --git a/inputmethod/mozc-server/patches/patch-gui_config__dialog_config__dialog.cc b/inputmethod/mozc-server/patches/patch-gui_config__dialog_config__dialog.cc index d6a00ffb22e..6c578a6cc32 100644 --- a/inputmethod/mozc-server/patches/patch-gui_config__dialog_config__dialog.cc +++ b/inputmethod/mozc-server/patches/patch-gui_config__dialog_config__dialog.cc @@ -1,6 +1,6 @@ -$NetBSD: patch-gui_config__dialog_config__dialog.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-gui_config__dialog_config__dialog.cc,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- gui/config_dialog/config_dialog.cc.orig 2013-07-17 02:38:18.000000000 +0000 +--- gui/config_dialog/config_dialog.cc.orig 2013-08-28 05:26:26.000000000 +0000 +++ gui/config_dialog/config_dialog.cc @@ -97,21 +97,21 @@ ConfigDialog::ConfigDialog() setWindowTitle(tr("Mozc Preferences")); @@ -55,3 +55,12 @@ $NetBSD: patch-gui_config__dialog_config__dialog.cc,v 1.2 2013/07/20 04:34:53 ry if ((initial_preedit_method_ != static_cast<int>(config.preedit_method())) || (initial_use_keyboard_to_change_preedit_method_ != +@@ -472,7 +472,7 @@ bool ConfigDialog::Update() { + initial_use_keyboard_to_change_preedit_method_ = + config.use_keyboard_to_change_preedit_method(); + } +-#endif // OS_WIN or OS_LINUX ++#endif // OS_WIN, OS_LINUX or OS_NETBSD + + #ifdef OS_WIN + if (initial_use_mode_indicator_ != config.use_mode_indicator()) { diff --git a/inputmethod/mozc-server/patches/patch-gui_dictionary__tool_dictionary__tool.cc b/inputmethod/mozc-server/patches/patch-gui_dictionary__tool_dictionary__tool.cc index df371bbef60..f39f9a4e0e8 100644 --- a/inputmethod/mozc-server/patches/patch-gui_dictionary__tool_dictionary__tool.cc +++ b/inputmethod/mozc-server/patches/patch-gui_dictionary__tool_dictionary__tool.cc @@ -1,13 +1,13 @@ -$NetBSD: patch-gui_dictionary__tool_dictionary__tool.cc,v 1.1 2013/04/29 09:52:17 ryoon Exp $ +$NetBSD: patch-gui_dictionary__tool_dictionary__tool.cc,v 1.2 2013/09/07 18:42:14 ryoon Exp $ ---- gui/dictionary_tool/dictionary_tool.cc.orig 2013-03-29 04:34:06.000000000 +0000 +--- gui/dictionary_tool/dictionary_tool.cc.orig 2013-08-28 05:26:30.000000000 +0000 +++ gui/dictionary_tool/dictionary_tool.cc @@ -358,7 +358,7 @@ DictionaryTool::DictionaryTool(QWidget * } // main window -#ifndef OS_LINUX -+#if !defined(OS_LINUX) || !defined(OS_NETBSD) ++#if !defined(OS_LINUX) && !defined(OS_NETBSD) // For some reason setCentralWidget crashes the dictionary_tool on Linux // TODO(taku): investigate the cause of the crashes setCentralWidget(splitter_); diff --git a/inputmethod/mozc-server/patches/patch-gui_gui.gyp b/inputmethod/mozc-server/patches/patch-gui_gui.gyp index 7a5dc336839..b772f3ecb47 100644 --- a/inputmethod/mozc-server/patches/patch-gui_gui.gyp +++ b/inputmethod/mozc-server/patches/patch-gui_gui.gyp @@ -1,6 +1,6 @@ -$NetBSD: patch-gui_gui.gyp,v 1.1 2013/04/29 09:52:17 ryoon Exp $ +$NetBSD: patch-gui_gui.gyp,v 1.2 2013/09/07 18:42:14 ryoon Exp $ ---- gui/gui.gyp.orig 2012-08-31 05:36:43.000000000 +0000 +--- gui/gui.gyp.orig 2013-08-28 05:26:12.000000000 +0000 +++ gui/gui.gyp @@ -387,7 +387,7 @@ '../session/session_base.gyp:session_protocol', diff --git a/inputmethod/mozc-server/patches/patch-gui_qt__libraries.gypi b/inputmethod/mozc-server/patches/patch-gui_qt__libraries.gypi index 5060167bf53..d570118eb2d 100644 --- a/inputmethod/mozc-server/patches/patch-gui_qt__libraries.gypi +++ b/inputmethod/mozc-server/patches/patch-gui_qt__libraries.gypi @@ -1,6 +1,6 @@ -$NetBSD: patch-gui_qt__libraries.gypi,v 1.1 2013/04/29 09:52:17 ryoon Exp $ +$NetBSD: patch-gui_qt__libraries.gypi,v 1.2 2013/09/07 18:42:14 ryoon Exp $ ---- gui/qt_libraries.gypi.orig 2013-03-29 04:33:25.000000000 +0000 +--- gui/qt_libraries.gypi.orig 2013-08-28 05:26:12.000000000 +0000 +++ gui/qt_libraries.gypi @@ -84,7 +84,7 @@ '$(SDKROOT)/System/Library/Frameworks/Carbon.framework', diff --git a/inputmethod/mozc-server/patches/patch-gyp_common.gypi b/inputmethod/mozc-server/patches/patch-gyp_common.gypi index cbf4d44db68..830f9bae4a9 100644 --- a/inputmethod/mozc-server/patches/patch-gyp_common.gypi +++ b/inputmethod/mozc-server/patches/patch-gyp_common.gypi @@ -1,6 +1,6 @@ -$NetBSD: patch-gyp_common.gypi,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-gyp_common.gypi,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- gyp/common.gypi.orig 2013-07-17 02:38:04.000000000 +0000 +--- gyp/common.gypi.orig 2013-08-28 05:26:13.000000000 +0000 +++ gyp/common.gypi @@ -101,6 +101,7 @@ '-include base/namespace.h', @@ -28,6 +28,15 @@ $NetBSD: patch-gyp_common.gypi,v 1.2 2013/07/20 04:34:53 ryoon Exp $ # use_libprotobuf represents if protobuf library is used or not. # This option is only for Linux. +@@ -300,7 +301,7 @@ + ['channel_dev==1', { + 'defines': ['CHANNEL_DEV'], + }], +- ['not(OS=="linux" and use_libprotobuf!=0)', { ++ ['not((OS=="linux" or OS=="netbsd") and use_libprotobuf!=0)', { + 'include_dirs': [ + '../protobuf/files/src', + ], @@ -309,12 +310,12 @@ # additional suffix except for Japanese so that multiple # converter processes can coexist. Note that Mozc on ChromeOS does @@ -43,7 +52,7 @@ $NetBSD: patch-gyp_common.gypi,v 1.2 2013/07/20 04:34:53 ryoon Exp $ 'ldflags': [ '<@(linux_ldflags)', ], -@@ -473,7 +474,7 @@ +@@ -485,7 +486,7 @@ }, }, 'conditions': [ @@ -52,7 +61,7 @@ $NetBSD: patch-gyp_common.gypi,v 1.2 2013/07/20 04:34:53 ryoon Exp $ 'cflags': [ '<@(debug_extra_cflags)', ], -@@ -511,7 +512,7 @@ +@@ -523,7 +524,7 @@ }, }, 'conditions': [ @@ -61,7 +70,7 @@ $NetBSD: patch-gyp_common.gypi,v 1.2 2013/07/20 04:34:53 ryoon Exp $ 'cflags': [ '<@(release_extra_cflags)', ], -@@ -825,6 +826,22 @@ +@@ -832,6 +833,22 @@ }], ], }], diff --git a/inputmethod/mozc-server/patches/patch-ipc_unix__ipc.cc b/inputmethod/mozc-server/patches/patch-ipc_unix__ipc.cc index 354fa8a5a99..de8aa1d1851 100644 --- a/inputmethod/mozc-server/patches/patch-ipc_unix__ipc.cc +++ b/inputmethod/mozc-server/patches/patch-ipc_unix__ipc.cc @@ -1,13 +1,13 @@ -$NetBSD: patch-ipc_unix__ipc.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-ipc_unix__ipc.cc,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- ipc/unix_ipc.cc.orig 2013-07-17 02:37:50.000000000 +0000 +--- ipc/unix_ipc.cc.orig 2013-08-28 05:25:59.000000000 +0000 +++ ipc/unix_ipc.cc @@ -28,7 +28,7 @@ // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // skip all if non-Linux or Android. -#if defined(OS_LINUX) && !defined(OS_ANDROID) -+#if defined(OS_LINUX) && !defined(OS_ANDROID) || defined(OS_NETBSD) ++#if (defined(OS_LINUX) && !defined(OS_ANDROID)) || defined(OS_NETBSD) #include "ipc/ipc.h" @@ -25,7 +25,7 @@ $NetBSD: patch-ipc_unix__ipc.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ *pid = peer_cred.pid; -#endif // __arm__ -+#endif // __arm__, OS_NETBSD ++#endif // __arm__ || OS_NETBSD + +#if defined(OS_NETBSD) + struct unpcbid peer_cred; diff --git a/inputmethod/mozc-server/patches/patch-languages_chewing_chewing.gyp b/inputmethod/mozc-server/patches/patch-languages_chewing_chewing.gyp deleted file mode 100644 index b297ba97335..00000000000 --- a/inputmethod/mozc-server/patches/patch-languages_chewing_chewing.gyp +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-languages_chewing_chewing.gyp,v 1.1 2013/04/29 09:52:18 ryoon Exp $ - ---- languages/chewing/chewing.gyp.orig 2012-08-31 05:36:42.000000000 +0000 -+++ languages/chewing/chewing.gyp -@@ -55,7 +55,7 @@ - }, - ], - 'conditions': [ -- ['OS=="linux"', { -+ ['OS=="linux" or OS=="netbsd"', { - 'targets': [ - { - 'target_name': 'ibus_mozc_chewing', diff --git a/inputmethod/mozc-server/patches/patch-protobuf_genproto.gypi b/inputmethod/mozc-server/patches/patch-protobuf_genproto.gypi index 03e0574ea3c..4bd9db00023 100644 --- a/inputmethod/mozc-server/patches/patch-protobuf_genproto.gypi +++ b/inputmethod/mozc-server/patches/patch-protobuf_genproto.gypi @@ -1,6 +1,6 @@ -$NetBSD: patch-protobuf_genproto.gypi,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-protobuf_genproto.gypi,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- protobuf/genproto.gypi.orig 2013-07-17 02:38:05.000000000 +0000 +--- protobuf/genproto.gypi.orig 2013-08-28 05:26:13.000000000 +0000 +++ protobuf/genproto.gypi @@ -34,7 +34,7 @@ 'protoc_command': 'protoc<(EXECUTABLE_SUFFIX)', diff --git a/inputmethod/mozc-server/patches/patch-session_session.cc b/inputmethod/mozc-server/patches/patch-session_session.cc index db005ac0d22..2607351ba4a 100644 --- a/inputmethod/mozc-server/patches/patch-session_session.cc +++ b/inputmethod/mozc-server/patches/patch-session_session.cc @@ -1,13 +1,13 @@ -$NetBSD: patch-session_session.cc,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-session_session.cc,v 1.3 2013/09/07 18:42:14 ryoon Exp $ ---- session/session.cc.orig 2013-07-17 02:38:03.000000000 +0000 +--- session/session.cc.orig 2013-08-28 05:26:12.000000000 +0000 +++ session/session.cc -@@ -1133,7 +1133,7 @@ void Session::UpdateOperationPreferences +@@ -1139,7 +1139,7 @@ void Session::UpdateOperationPreferences } // Cascading Window. -#ifndef OS_LINUX -+#if defined(OS_LINUX) || defined(OS_NETBSD) ++#if !defined(OS_LINUX) && !defined(OS_NETBSD) if (config.has_use_cascading_window()) { operation_preferences.use_cascading_window = config.use_cascading_window(); } diff --git a/inputmethod/mozc-server/patches/patch-third__party_gyp_buildbot_buildbot__run.py b/inputmethod/mozc-server/patches/patch-third__party_gyp_buildbot_buildbot__run.py deleted file mode 100644 index f935fc96ecc..00000000000 --- a/inputmethod/mozc-server/patches/patch-third__party_gyp_buildbot_buildbot__run.py +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-third__party_gyp_buildbot_buildbot__run.py,v 1.1 2013/04/29 09:52:18 ryoon Exp $ - ---- third_party/gyp/buildbot/buildbot_run.py.orig 2012-02-23 21:18:54.000000000 +0000 -+++ third_party/gyp/buildbot/buildbot_run.py -@@ -74,6 +74,8 @@ def GypBuild(): - retcode += GypTestFormat('ninja') - retcode += GypTestFormat('scons') - retcode += GypTestFormat('make') -+ elif sys.platform == 'netbsd': -+ retcode += GypTestFormat('make') - elif sys.platform == 'darwin': - retcode += GypTestFormat('ninja') - retcode += GypTestFormat('xcode') diff --git a/inputmethod/mozc-server/patches/patch-unix_ibus_gen__mozc__xml.py b/inputmethod/mozc-server/patches/patch-unix_ibus_gen__mozc__xml.py index 798d1a6393d..8bb5507e044 100644 --- a/inputmethod/mozc-server/patches/patch-unix_ibus_gen__mozc__xml.py +++ b/inputmethod/mozc-server/patches/patch-unix_ibus_gen__mozc__xml.py @@ -1,55 +1,70 @@ -$NetBSD: patch-unix_ibus_gen__mozc__xml.py,v 1.2 2013/07/20 04:34:53 ryoon Exp $ +$NetBSD: patch-unix_ibus_gen__mozc__xml.py,v 1.3 2013/09/07 18:42:14 ryoon Exp $ * Fix for pkgsrc installation. ---- unix/ibus/gen_mozc_xml.py.orig 2013-07-17 02:37:50.000000000 +0000 +--- unix/ibus/gen_mozc_xml.py.orig 2013-08-28 05:25:59.000000000 +0000 +++ unix/ibus/gen_mozc_xml.py -@@ -49,7 +49,7 @@ IBUS_COMPONENT_PROPS = { - 'description': '%s Component', - # TODO(yusukes): Support Linux distributions other than Gentoo/ChromeOS. - # For example, Ubuntu uses /usr/lib/ibus-mozc/. -- 'exec': '/usr/libexec/ibus-engine-mozc --ibus', +@@ -47,7 +47,7 @@ import sys + IBUS_COMPONENT_PROPS = { + 'name': 'com.google.IBus.Mozc', + 'description': '%(product_name)s Component', +- 'exec': '%(ibus_mozc_path)s --ibus', + 'exec': '@PREFIX@/libexec/ibus-engine-mozc --ibus', # TODO(mazda): Generate the version number. 'version': '0.0.0.0', 'author': 'Google Inc.', -@@ -62,7 +62,7 @@ IBUS_COMPONENT_PROPS = { +@@ -60,7 +60,7 @@ IBUS_COMPONENT_PROPS = { IBUS_ENGINE_COMMON_PROPS = { - 'description': '%s (Japanese Input Method)', + 'description': '%(product_name)s (Japanese Input Method)', 'language': 'ja', -- 'icon': '/usr/share/ibus-mozc/product_icon.png', +- 'icon': '%(ibus_mozc_icon_path)s', + 'icon': '@PREFIX@/share/ibus-mozc/product_icon.png', 'rank': '80', } -@@ -95,6 +95,13 @@ IBUS_ENGINES_PROPS = { - 'longname': ['%s'], +@@ -93,6 +93,22 @@ IBUS_ENGINES_PROPS = { + 'longname': ['%(product_name)s'], 'layout': ['default'], }, + 'NetBSD': { + # DO NOT change the engine name 'mozc-jp'. The names is referenced by + # unix/ibus/mozc_engine.cc. + 'name': ['mozc-jp'], -+ 'longname': ['%s'], ++ 'longname': ['%(product_name)s'], + 'layout': ['jp'], + }, ++ # On NetBSD (IBus >= 1.5), we use special label 'default' for the keyboard ++ # layout. ++ 'NetBSD-IBus1.5': { ++ # DO NOT change the engine name 'mozc-jp'. The names is referenced by ++ # unix/ibus/mozc_engine.cc. ++ 'name': ['mozc-jp'], ++ 'longname': ['%(product_name)s'], ++ 'layout': ['default'], ++ }, # On Chrome/Chromium OS, we provide three engines. 'ChromeOS': { # DO NOT change the engine name 'mozc-jp'. The names is referenced by -@@ -228,7 +235,15 @@ def main(): +@@ -225,13 +241,21 @@ def main(): platform = options.platform common_props = IBUS_ENGINE_COMMON_PROPS if platform == 'Linux': - setup_arg.append(os.path.join(options.server_dir, 'mozc_tool')) + setup_arg.append(os.path.join("@PREFIX@/libexec", 'mozc_tool')) + setup_arg.append('--mode=config_dialog') + if IsIBus15OrGreater(options): + # A tentative workaround against IBus 1.5 + platform = 'Linux-IBus1.5' + common_props = IBUS_1_5_ENGINE_COMMON_PROPS + ++ if platform == 'NetBSD': ++ setup_arg.append(os.path.join("@PREFIX@/libexec", 'mozc_tool')) + setup_arg.append('--mode=config_dialog') + if IsIBus15OrGreater(options): + # A tentative workaround against IBus 1.5 -+ platform = 'Linux-IBus1.5' ++ platform = 'NetBSD-IBus1.5' + common_props = IBUS_1_5_ENGINE_COMMON_PROPS + -+ if platform == 'NetBSD': -+ setup_arg.append(os.path.join("@PREFIX@/libexec", 'mozc_tool')) - setup_arg.append('--mode=config_dialog') - if IsIBus15OrGreater(options): - # A tentative workaround against IBus 1.5 + param_dict = {'product_name': PRODUCT_NAMES[options.branding], + 'ibus_mozc_path': options.ibus_mozc_path, + 'ibus_mozc_icon_path': options.ibus_mozc_icon_path} |