aboutsummaryrefslogtreecommitdiff
path: root/japanese/scim-mozc
diff options
context:
space:
mode:
authorDaichi GOTO <daichi@FreeBSD.org>2010-09-04 02:44:13 +0000
committerDaichi GOTO <daichi@FreeBSD.org>2010-09-04 02:44:13 +0000
commit83ac3caa910db581f08ee80e88ca9bb636bab10b (patch)
treece5fc5ff2dfbebba6f8767a106a26c6af0d1a399 /japanese/scim-mozc
parentf22045cc5223567f88227b0a1f20874b4ba2df38 (diff)
downloadports-83ac3caa910db581f08ee80e88ca9bb636bab10b.tar.gz
ports-83ac3caa910db581f08ee80e88ca9bb636bab10b.zip
Notes
Diffstat (limited to 'japanese/scim-mozc')
-rw-r--r--japanese/scim-mozc/Makefile39
-rw-r--r--japanese/scim-mozc/distinfo9
-rw-r--r--japanese/scim-mozc/files/patch-base_iconv.cc (renamed from japanese/scim-mozc/files/patch-src_base_iconv.cc)4
-rw-r--r--japanese/scim-mozc/files/patch-base_mutex.h (renamed from japanese/scim-mozc/files/patch-src_base_mutex.h)4
-rw-r--r--japanese/scim-mozc/files/patch-base_process.cc (renamed from japanese/scim-mozc/files/patch-src_base_process.cc)4
-rw-r--r--japanese/scim-mozc/files/patch-base_util.cc11
-rw-r--r--japanese/scim-mozc/files/patch-build_mozc.py29
-rw-r--r--japanese/scim-mozc/files/patch-build_tools_mozc_version.py11
-rw-r--r--japanese/scim-mozc/files/patch-gui_about_dialog_about_dialog.cc11
-rw-r--r--japanese/scim-mozc/files/patch-gui_about_dialog_version_image_widget.cc11
-rw-r--r--japanese/scim-mozc/files/patch-gyp_common.gypi (renamed from japanese/scim-mozc/files/patch-src_gyp_common.gypi)6
-rw-r--r--japanese/scim-mozc/files/patch-ipc_ipc_path_manager.cc14
-rw-r--r--japanese/scim-mozc/files/patch-ipc_unix_ipc.cc (renamed from japanese/scim-mozc/files/patch-src_ipc_unix_ipc.cc)4
-rw-r--r--japanese/scim-mozc/files/patch-src_base_util.cc11
-rw-r--r--japanese/scim-mozc/files/patch-src_build_mozc.py20
-rw-r--r--japanese/scim-mozc/files/patch-src_unix_scim_scim.gyp38
-rw-r--r--japanese/scim-mozc/files/patch-src_unix_scim_scim_mozc.cc17
-rw-r--r--japanese/scim-mozc/files/patch-unix_ibus_gen_mozc_xml.py20
-rw-r--r--japanese/scim-mozc/files/patch-unix_ibus_mozc.xml24
-rw-r--r--japanese/scim-mozc/files/patch-unix_ibus_path_util.cc19
-rw-r--r--japanese/scim-mozc/files/patch-unix_scim_scim.gyp11
-rw-r--r--japanese/scim-mozc/pkg-plist12
22 files changed, 225 insertions, 104 deletions
diff --git a/japanese/scim-mozc/Makefile b/japanese/scim-mozc/Makefile
index b0ee79feeaa3..41bcfd33b4db 100644
--- a/japanese/scim-mozc/Makefile
+++ b/japanese/scim-mozc/Makefile
@@ -6,7 +6,7 @@
#
PORTNAME= scim-mozc
-PORTVERSION= 0.11.383.102
+PORTVERSION= 0.12.434.102
CATEGORIES= japanese
MASTER_SITES= http://people.freebsd.org/~daichi/distfiles/
DISTNAME= mozc-${PORTVERSION}
@@ -16,6 +16,7 @@ MAINTAINER= daichi@freebsd.org
COMMENT= Mozc engine for SCIM
BUILD_DEPENDS= gsed:${PORTSDIR}/textproc/gsed \
+ ${LOCALBASE}/bin/grep:${PORTSDIR}/textproc/gnugrep \
gyp:${PORTSDIR}/devel/py-gyp-devel \
scim:${PORTSDIR}/textproc/scim
LIB_DEPENDS= curl.6:${PORTSDIR}/ftp/curl \
@@ -56,7 +57,6 @@ post-patch:
do-build:
@cd ${WRKSRC}/; \
${PYTHON_CMD} build_mozc.py gyp --gypdir=${LOCALBASE}/bin; \
- ${SED} -i .bak -e "s/sed/gsed/g" Makefile; \
${PYTHON_CMD} build_mozc.py build_tools -c Release; \
${PYTHON_CMD} build_mozc.py build -c Release \
unix/scim/scim.gyp:scim_mozc \
@@ -64,11 +64,42 @@ do-build:
do-install:
@${INSTALL} -o 0 -g 0 -m 555 \
- ${WRKSRC}/out/Release/lib.target/libscim_mozc.so \
+ ${WRKSRC}/out_linux/Release/lib.target/libscim_mozc.so \
${LOCALBASE}/lib/scim-1.0/1.4.0/IMEngine/mozc.so
@${INSTALL} -o 0 -g 0 -m 555 \
- ${WRKSRC}/out/Release/lib.target/libscim_mozc_setup.so \
+ ${WRKSRC}/out_linux/Release/lib.target/libscim_mozc_setup.so \
${LOCALBASE}/lib/scim-1.0/1.4.0/SetupUI/mozc_setup.so
+ @${MKDIR} ${LOCALBASE}/share/scim-mozc/icons
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-alpha_full.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-alpha_full.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-alpha_half.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-alpha_half.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-dictionary.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-dictionary.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-direct.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-direct.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-hiragana.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-hiragana.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-katakana_full.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-katakana_full.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-katakana_half.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-katakana_half.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-properties.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-properties.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ui-tool.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc-tool.png
+ @${INSTALL} -o 0 -g 0 -m 444 \
+ ${WRKSRC}/data/images/unix/ime_product_icon_opensource-32.png \
+ ${LOCALBASE}/share/scim-mozc/icons/scim-mozc.png
post-install:
@${CAT} ${PKGMESSAGE}
diff --git a/japanese/scim-mozc/distinfo b/japanese/scim-mozc/distinfo
index 3f51e9eb66e5..e30e92a2743c 100644
--- a/japanese/scim-mozc/distinfo
+++ b/japanese/scim-mozc/distinfo
@@ -1,3 +1,6 @@
-MD5 (mozc-0.11.383.102.tar.bz2) = 42e7b57f617b470528dc00be28ccaf28
-SHA256 (mozc-0.11.383.102.tar.bz2) = 69e8a4daf2165d9e2918af1e7a1a26262099ab453578d8c7456301aa8df047a2
-SIZE (mozc-0.11.383.102.tar.bz2) = 34539981
+MD5 (mozc-0.12.434.102.tar.bz2) = ea760a57120e864feb1370ac03da6306
+SHA256 (mozc-0.12.434.102.tar.bz2) = 7256549a83537a8d63de7e51996c28b11d1431a149985692f9ccfdd3edabe22c
+SIZE (mozc-0.12.434.102.tar.bz2) = 34570612
+MD5 (mozcdic-ut-devel-20100731.tar.bz2) = 6f80e0405d90e169d3a0a9a3166cf52a
+SHA256 (mozcdic-ut-devel-20100731.tar.bz2) = 4f7e48cbc06e2c014e32e1c889a311e4142e33b2d2952a8bc5cea08d5df923f4
+SIZE (mozcdic-ut-devel-20100731.tar.bz2) = 5530330
diff --git a/japanese/scim-mozc/files/patch-src_base_iconv.cc b/japanese/scim-mozc/files/patch-base_iconv.cc
index 5a928e254b27..fd1f0fd28e43 100644
--- a/japanese/scim-mozc/files/patch-src_base_iconv.cc
+++ b/japanese/scim-mozc/files/patch-base_iconv.cc
@@ -1,5 +1,5 @@
---- base/iconv.cc.org 2010-06-17 15:59:08.032915669 +0900
-+++ base/iconv.cc 2010-06-26 14:52:20.086054034 +0900
+--- base/iconv.cc.org 2010-08-13 19:48:06.000000000 +0900
++++ base/iconv.cc 2010-09-03 11:18:15.807359114 +0900
@@ -52,7 +52,7 @@
size_t olen_org = olen;
iconv(ic, 0, &ilen, 0, &olen); // reset iconv state
diff --git a/japanese/scim-mozc/files/patch-src_base_mutex.h b/japanese/scim-mozc/files/patch-base_mutex.h
index 4249feff64fc..af372ba36f23 100644
--- a/japanese/scim-mozc/files/patch-src_base_mutex.h
+++ b/japanese/scim-mozc/files/patch-base_mutex.h
@@ -1,5 +1,5 @@
---- base/mutex.h.org 2010-06-17 15:59:08.032915669 +0900
-+++ base/mutex.h 2010-06-26 14:42:34.171132724 +0900
+--- base/mutex.h 2010-08-13 19:48:05.000000000 +0900
++++ base/mutex.h 2010-09-03 11:20:50.849065252 +0900
@@ -87,7 +87,7 @@
#endif
diff --git a/japanese/scim-mozc/files/patch-src_base_process.cc b/japanese/scim-mozc/files/patch-base_process.cc
index 9832c2f21642..41266287602e 100644
--- a/japanese/scim-mozc/files/patch-src_base_process.cc
+++ b/japanese/scim-mozc/files/patch-base_process.cc
@@ -1,5 +1,5 @@
---- base/process.cc.org 2010-06-17 15:59:08.038677016 +0900
-+++ base/process.cc 2010-06-26 15:14:15.207482874 +0900
+--- base/process.cc 2010-08-13 19:48:06.000000000 +0900
++++ base/process.cc 2010-09-03 11:22:43.438900552 +0900
@@ -195,7 +195,7 @@
#endif
diff --git a/japanese/scim-mozc/files/patch-base_util.cc b/japanese/scim-mozc/files/patch-base_util.cc
new file mode 100644
index 000000000000..9232b1b623e4
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-base_util.cc
@@ -0,0 +1,11 @@
+--- base/util.cc.org 2010-09-03 11:24:20.268706017 +0900
++++ base/util.cc 2010-09-03 11:24:57.363718651 +0900
+@@ -1497,7 +1497,7 @@
+ #endif // OS_MACOSX
+
+ #ifdef OS_LINUX
+- return "/usr/lib/mozc";
++ return "@@LOCALBASE@@/bin";
+ #endif // OS_LINUX
+ }
+
diff --git a/japanese/scim-mozc/files/patch-build_mozc.py b/japanese/scim-mozc/files/patch-build_mozc.py
new file mode 100644
index 000000000000..5976188aecb6
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-build_mozc.py
@@ -0,0 +1,29 @@
+--- build_mozc.py.org 2010-09-03 11:25:55.375517357 +0900
++++ build_mozc.py 2010-09-03 14:33:39.472673001 +0900
+@@ -69,7 +69,7 @@
+
+ def IsLinux():
+ """Returns true if the platform is Linux."""
+- return os.name == 'posix' and os.uname()[0] == 'Linux'
++ return os.name == 'posix' and os.uname()[0] == 'FreeBSD'
+
+
+ # TODO(yukawa): Move this function to util.py (b/2715400)
+@@ -510,7 +510,7 @@
+ default='Win32',
+ help='specify the target plaform: [Win32|x64]')
+ # default Qt dir to support the current build procedure for Debian.
+- default_qtdir = '/usr/local/Trolltech/Qt-4.5.2'
++ default_qtdir = '@@LOCALBASE@@/lib/qt4'
+ if IsWindows():
+ default_qtdir = None
+ parser.add_option('--qtdir', dest='qtdir',
+@@ -557,7 +557,7 @@
+ (unused_gyp_file_name, target_name) = ParseTarget(target)
+ target_names.append(target_name)
+
+- make_command = os.getenv('BUILD_COMMAND', 'make')
++ make_command = os.getenv('BUILD_COMMAND', 'gmake')
+ # flags for building in Chrome OS chroot environment
+ envvars = [
+ 'CFLAGS',
diff --git a/japanese/scim-mozc/files/patch-build_tools_mozc_version.py b/japanese/scim-mozc/files/patch-build_tools_mozc_version.py
new file mode 100644
index 000000000000..cdfb90dffaaf
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-build_tools_mozc_version.py
@@ -0,0 +1,11 @@
+--- build_tools/mozc_version.py.org 2010-09-03 14:19:13.609379202 +0900
++++ build_tools/mozc_version.py 2010-09-03 14:18:44.423726277 +0900
+@@ -55,7 +55,7 @@
+
+ def IsLinux():
+ """Returns true if the platform is Linux."""
+- return os.name == 'posix' and os.uname()[0] == 'Linux'
++ return os.name == 'posix' and os.uname()[0] == 'FreeBSD'
+
+
+ def CalculateRevisionForPlatform(revision):
diff --git a/japanese/scim-mozc/files/patch-gui_about_dialog_about_dialog.cc b/japanese/scim-mozc/files/patch-gui_about_dialog_about_dialog.cc
new file mode 100644
index 000000000000..8dc80af3d463
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-gui_about_dialog_about_dialog.cc
@@ -0,0 +1,11 @@
+--- gui/about_dialog/about_dialog.cc.org 2010-09-03 19:41:20.545071308 +0900
++++ gui/about_dialog/about_dialog.cc 2010-09-03 19:43:51.975348061 +0900
+@@ -114,7 +114,7 @@
+ SetLabelText(label_terms);
+ SetLabelText(label_credits);
+
+- product_image_.reset(new QImage(":/product_logo.png"));
++ product_image_.reset(new QImage("@@LOCALBASE@@/share/mozc-tool/icons/product_logo.png"));
+ }
+
+ void AboutDialog::paintEvent(QPaintEvent *event) {
diff --git a/japanese/scim-mozc/files/patch-gui_about_dialog_version_image_widget.cc b/japanese/scim-mozc/files/patch-gui_about_dialog_version_image_widget.cc
new file mode 100644
index 000000000000..7bd46b21404b
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-gui_about_dialog_version_image_widget.cc
@@ -0,0 +1,11 @@
+--- gui/about_dialog/version_image_widget.cc.org 2010-09-03 19:45:25.423577654 +0900
++++ gui/about_dialog/version_image_widget.cc 2010-09-03 19:44:57.400714134 +0900
+@@ -41,7 +41,7 @@
+ void VersionImageWidget::loadImage() {
+ // Currently the version is always latest.
+ // TODO(mukai): add the version checking logic
+- pixmap_.reset(new QPixmap(":/update_uptodate.png"));
++ pixmap_.reset(new QPixmap("@@LOCALBASE@@/share/mozc-tool/icons/update_uptodate.png"));
+ }
+
+ void VersionImageWidget::paintEvent(QPaintEvent* paint_event) {
diff --git a/japanese/scim-mozc/files/patch-src_gyp_common.gypi b/japanese/scim-mozc/files/patch-gyp_common.gypi
index 6bd13450d867..a7e6ffa151a7 100644
--- a/japanese/scim-mozc/files/patch-src_gyp_common.gypi
+++ b/japanese/scim-mozc/files/patch-gyp_common.gypi
@@ -1,6 +1,6 @@
---- gyp/common.gypi.org 2010-06-17 15:59:08.053080522 +0900
-+++ gyp/common.gypi 2010-06-26 14:48:00.645671527 +0900
-@@ -371,6 +371,12 @@
+--- gyp/common.gypi.org 2010-09-03 11:27:13.818109921 +0900
++++ gyp/common.gypi 2010-09-03 11:28:44.023549160 +0900
+@@ -397,6 +397,12 @@
'-lz',
'<@(extra_linux_libs)',
],
diff --git a/japanese/scim-mozc/files/patch-ipc_ipc_path_manager.cc b/japanese/scim-mozc/files/patch-ipc_ipc_path_manager.cc
new file mode 100644
index 000000000000..af41eb56846a
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-ipc_ipc_path_manager.cc
@@ -0,0 +1,14 @@
+--- ipc/ipc_path_manager.cc.org 2010-09-04 07:45:47.421394850 +0900
++++ ipc/ipc_path_manager.cc 2010-09-04 07:50:27.875266222 +0900
+@@ -265,7 +265,10 @@
+ *ipc_name = kIPCPrefix;
+ #endif // OS_WINDOWS
+
+-#ifdef OS_LINUX
++#if !defined(__FreeBSD__) && defined(OS_LINUX)
++// XXX
++// Abstract Namespace of socket is LINUX ONLY incompatible feature.
++// XXX
+ // On Linux, use abstract namespace which is independent of the file system.
+ (*ipc_name)[0] = '\0';
+ #endif
diff --git a/japanese/scim-mozc/files/patch-src_ipc_unix_ipc.cc b/japanese/scim-mozc/files/patch-ipc_unix_ipc.cc
index f0e5dfc02654..ea575d28240d 100644
--- a/japanese/scim-mozc/files/patch-src_ipc_unix_ipc.cc
+++ b/japanese/scim-mozc/files/patch-ipc_unix_ipc.cc
@@ -1,5 +1,5 @@
---- ipc/unix_ipc.cc.org 2010-06-17 15:59:08.061722403 +0900
-+++ ipc/unix_ipc.cc 2010-06-26 14:57:03.788901462 +0900
+--- ipc/unix_ipc.cc.org 2010-09-03 11:29:17.747782268 +0900
++++ ipc/unix_ipc.cc 2010-09-03 11:30:16.703030211 +0900
@@ -41,7 +41,7 @@
#include <sys/time.h>
#include <sys/types.h>
diff --git a/japanese/scim-mozc/files/patch-src_base_util.cc b/japanese/scim-mozc/files/patch-src_base_util.cc
deleted file mode 100644
index b338a19eb60e..000000000000
--- a/japanese/scim-mozc/files/patch-src_base_util.cc
+++ /dev/null
@@ -1,11 +0,0 @@
---- base/util.cc.org 2010-06-17 15:59:08.035797879 +0900
-+++ base/util.cc 2010-06-26 15:18:24.444371641 +0900
-@@ -1493,7 +1493,7 @@
- #endif // OS_MACOSX
-
- #ifdef OS_LINUX
-- return "/usr/lib/mozc";
-+ return "@@LOCALBASE@@/bin";
- #endif // OS_LINUX
- }
-
diff --git a/japanese/scim-mozc/files/patch-src_build_mozc.py b/japanese/scim-mozc/files/patch-src_build_mozc.py
deleted file mode 100644
index ba044b1cad4a..000000000000
--- a/japanese/scim-mozc/files/patch-src_build_mozc.py
+++ /dev/null
@@ -1,20 +0,0 @@
---- build_mozc.py.org 2010-06-17 15:59:08.104932923 +0900
-+++ build_mozc.py 2010-06-26 14:43:42.504687128 +0900
-@@ -68,7 +68,7 @@
-
- def IsLinux():
- """Returns true if the platform is Linux."""
-- return os.name == 'posix' and os.uname()[0] == 'Linux'
-+ return os.name == 'posix' and os.uname()[0] == 'FreeBSD'
-
-
- def GetGeneratorName():
-@@ -403,7 +403,7 @@
- (unused_gyp_file_name, target_name) = ParseTarget(target)
- target_names.append(target_name)
-
-- make_command = os.getenv('BUILD_COMMAND', 'make')
-+ make_command = os.getenv('BUILD_COMMAND', 'gmake')
- # flags for building in Chrome OS chroot environment
- envvars = [
- 'CFLAGS',
diff --git a/japanese/scim-mozc/files/patch-src_unix_scim_scim.gyp b/japanese/scim-mozc/files/patch-src_unix_scim_scim.gyp
deleted file mode 100644
index e1a125fd31f8..000000000000
--- a/japanese/scim-mozc/files/patch-src_unix_scim_scim.gyp
+++ /dev/null
@@ -1,38 +0,0 @@
---- unix/scim/scim.gyp.org 2010-06-17 15:59:08.047320852 +0900
-+++ unix/scim/scim.gyp 2010-06-26 18:03:23.532337010 +0900
-@@ -43,17 +43,15 @@
- # on Ubuntu Hardy. Until it becomes necessary, we will not invoke
- # pkg-config here.
- 'scim_include_dirs': [
-- '/usr/include/atk-1.0',
-- '/usr/include/cairo',
-- '/usr/include/freetype2',
-- '/usr/include/glib-2.0',
-- '/usr/include/gtk-2.0',
-- '/usr/include/libpng12',
-- '/usr/include/pango-1.0',
-- '/usr/include/pixman-1',
-- '/usr/include/scim-1.0',
-- '/usr/lib/glib-2.0/include',
-- '/usr/lib/gtk-2.0/include',
-+ '@@LOCALBASE@@/include/atk-1.0',
-+ '@@LOCALBASE@@/include/cairo',
-+ '@@LOCALBASE@@/include/freetype2',
-+ '@@LOCALBASE@@/include/glib-2.0',
-+ '@@LOCALBASE@@/include/gtk-2.0',
-+ '@@LOCALBASE@@/include/libpng',
-+ '@@LOCALBASE@@/include/pango-1.0',
-+ '@@LOCALBASE@@/include/pixman-1',
-+ '@@LOCALBASE@@/include/scim-1.0',
- ],
- # The libraries come from "pkg-config --libs-only-l scim gtk+-2.0".
- 'scim_libraries': [
-@@ -74,7 +72,7 @@
- '-fPIC',
- ],
- 'scim_defines': [
-- 'SCIM_ICONDIR="/usr/share/scim/icons"',
-+ 'SCIM_ICONDIR="@@LOCALBASE@@/share/mozc-additions/icons/"',
- ]
- },
- 'targets': [
diff --git a/japanese/scim-mozc/files/patch-src_unix_scim_scim_mozc.cc b/japanese/scim-mozc/files/patch-src_unix_scim_scim_mozc.cc
deleted file mode 100644
index 811eda91b2f9..000000000000
--- a/japanese/scim-mozc/files/patch-src_unix_scim_scim_mozc.cc
+++ /dev/null
@@ -1,17 +0,0 @@
---- unix/scim/scim_mozc.cc.org 2010-06-17 15:59:08.050201385 +0900
-+++ unix/scim/scim_mozc.cc 2010-06-26 18:09:40.056488264 +0900
-@@ -45,11 +45,11 @@
- const char kConfigName[] = "/Panel/Gtk/LookupTableVertical";
-
- const char kPropTool[] = "/Mozc/Tool";
--const char kPropToolIcon[] = SCIM_ICONDIR "/scim-mozc-tool.png";
-+const char kPropToolIcon[] = SCIM_ICONDIR "/product_icon.png";
- const char kPropToolDictionary[] = "/Mozc/Tool/dictionary";
--const char kPropToolDictionaryIcon[] = SCIM_ICONDIR "/scim-mozc-dictionary.png";
-+const char kPropToolDictionaryIcon[] = SCIM_ICONDIR "/toolicon_setting.png";
- const char kPropToolProperty[] = "/Mozc/Tool/property";
--const char kPropToolPropertyIcon[] = SCIM_ICONDIR "/scim-mozc-property.png";
-+const char kPropToolPropertyIcon[] = SCIM_ICONDIR "/toolicon_setting.png";
-
- const char kPropCompositionModeIcon[] = "/Mozc/CompositionMode";
-
diff --git a/japanese/scim-mozc/files/patch-unix_ibus_gen_mozc_xml.py b/japanese/scim-mozc/files/patch-unix_ibus_gen_mozc_xml.py
new file mode 100644
index 000000000000..59c98cc23605
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-unix_ibus_gen_mozc_xml.py
@@ -0,0 +1,20 @@
+--- unix/ibus/gen_mozc_xml.py.org 2010-09-03 21:07:35.757153220 +0900
++++ unix/ibus/gen_mozc_xml.py 2010-09-03 21:11:23.381492067 +0900
+@@ -47,7 +47,7 @@
+ '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',
++ 'exec': '@@LOCALBASE@@/libexec/ibus-engine-mozc --ibus',
+ # TODO(mazda): Generate the version number.
+ 'version': '0.0.0.0',
+ 'author': 'Google Inc.',
+@@ -60,7 +60,7 @@
+ IBUS_ENGINE_COMMON_PROPS = {
+ 'description': '%s (Japanese Input Method)',
+ 'language': 'ja',
+- 'icon': '/usr/share/ibus-mozc/product_icon.png',
++ 'icon': '@@LOCALBASE@@/share/ibus-mozc/icons/product_logo.png',
+ 'rank': '0',
+ }
+
diff --git a/japanese/scim-mozc/files/patch-unix_ibus_mozc.xml b/japanese/scim-mozc/files/patch-unix_ibus_mozc.xml
new file mode 100644
index 000000000000..d830d6933935
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-unix_ibus_mozc.xml
@@ -0,0 +1,24 @@
+--- unix/ibus/mozc.xml.org 2010-09-03 11:42:47.253977329 +0900
++++ unix/ibus/mozc.xml 2010-09-03 20:56:17.057164534 +0900
+@@ -0,0 +1,21 @@
++<component>
++ <name>com.google.IBus.Mozc</name>
++ <description>Mozc Component</description>
++ <exec>@@LOCALBASE@@/libexec/ibus-engine-mozc --ibus</exec>
++ <version>0.0.0.0</version>
++ <author>Google Inc.</author>
++ <license>New BSD</license>
++ <homepage>http://code.google.com/p/mozc/</homepage>
++ <textdomain>ibus-mozc</textdomain>
++ <engines>
++ <engine>
++ <rank>0</rank>
++ <description>Mozc (Japanese Input Method)</description>
++ <language>ja</language>
++ <icon>@@LOCALBASE@@/share/ibus-mozc/icons/product_logo.png</icon>
++ <layout>jp</layout>
++ <name>mozc-jp</name>
++ <longname>Mozc</longname>
++ </engine>
++ </engines>
++</component>
diff --git a/japanese/scim-mozc/files/patch-unix_ibus_path_util.cc b/japanese/scim-mozc/files/patch-unix_ibus_path_util.cc
new file mode 100644
index 000000000000..7239e163f057
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-unix_ibus_path_util.cc
@@ -0,0 +1,19 @@
+--- unix/ibus/path_util.cc.org 2010-09-03 11:46:40.275135605 +0900
++++ unix/ibus/path_util.cc 2010-09-03 11:47:34.058766206 +0900
+@@ -30,14 +30,14 @@
+ #include "unix/ibus/path_util.h"
+
+ namespace {
+-const char kInstalledDirectory[] = "/usr/share/ibus-mozc";
++const char kInstalledDirectory[] = "@@LOCALBASE@@/share/ibus-mozc";
+ }
+
+ namespace mozc {
+ namespace ibus {
+
+ string GetIconPath(const string &icon_file) {
+- return kInstalledDirectory + string("/") + icon_file;
++ return string("@@LOCALBASE@@/share/ibus-mozc/icons/") + icon_file;
+ }
+
+ } // namespace ibus
diff --git a/japanese/scim-mozc/files/patch-unix_scim_scim.gyp b/japanese/scim-mozc/files/patch-unix_scim_scim.gyp
new file mode 100644
index 000000000000..ac1e153c7e7c
--- /dev/null
+++ b/japanese/scim-mozc/files/patch-unix_scim_scim.gyp
@@ -0,0 +1,11 @@
+--- unix/scim/scim.gyp.org 2010-09-03 11:48:22.034373161 +0900
++++ unix/scim/scim.gyp 2010-09-03 11:57:21.964398346 +0900
+@@ -44,7 +44,7 @@
+ '../../session/session.gyp:session',
+ ],
+ 'scim_defines': [
+- 'SCIM_ICONDIR="<!@(pkg-config --variable=icondir scim)"',
++ 'SCIM_ICONDIR="@@LOCALBASE@@/share/scim-mozc/icons/"',
+ ]
+ },
+ 'targets': [
diff --git a/japanese/scim-mozc/pkg-plist b/japanese/scim-mozc/pkg-plist
index e5fab80cc77b..d8a713b4da55 100644
--- a/japanese/scim-mozc/pkg-plist
+++ b/japanese/scim-mozc/pkg-plist
@@ -1,2 +1,14 @@
lib/scim-1.0/1.4.0/IMEngine/mozc.so
lib/scim-1.0/1.4.0/SetupUI/mozc_setup.so
+share/scim-mozc/icons/scim-mozc-alpha_full.png
+share/scim-mozc/icons/scim-mozc-alpha_half.png
+share/scim-mozc/icons/scim-mozc-dictionary.png
+share/scim-mozc/icons/scim-mozc-direct.png
+share/scim-mozc/icons/scim-mozc-hiragana.png
+share/scim-mozc/icons/scim-mozc-katakana_full.png
+share/scim-mozc/icons/scim-mozc-katakana_half.png
+share/scim-mozc/icons/scim-mozc-properties.png
+share/scim-mozc/icons/scim-mozc-tool.png
+share/scim-mozc/icons/scim-mozc.png
+@dirrm share/scim-mozc/icons
+@dirrm share/scim-mozc