1 |
fwang |
132143 |
Name: mozc |
2 |
|
|
Summary: Japanese Input Method Editor designed for multi-platform |
3 |
fwang |
132147 |
Version: 1.1.773.102 |
4 |
|
|
Release: %mkrel 1 |
5 |
fwang |
132143 |
Group: System/Internationalization |
6 |
|
|
License: BSD-like |
7 |
|
|
URL: http://code.google.com/p/mozc/ |
8 |
|
|
Source0: http://mozc.googlecode.com/files/mozc-%{version}.tar.bz2 |
9 |
|
|
# zipcode from Japan Post |
10 |
|
|
# http://www.post.japanpost.jp/zipcode/download.html |
11 |
|
|
Source2: KEN_ALL.CSV |
12 |
|
|
Source3: JIGYOSYO.CSV |
13 |
|
|
BuildRequires: python-devel |
14 |
fwang |
132148 |
BuildRequires: ibus-devel >= 1.3.9 |
15 |
fwang |
132143 |
BuildRequires: dbus-devel |
16 |
|
|
BuildRequires: openssl-devel |
17 |
|
|
BuildRequires: zlib-devel |
18 |
|
|
BuildRequires: subversion |
19 |
|
|
BuildRequires: curl-devel |
20 |
|
|
BuildRequires: gtest-devel |
21 |
|
|
BuildRequires: protobuf-devel |
22 |
|
|
BuildRequires: qt4-devel |
23 |
|
|
BuildRequires: zinnia-devel |
24 |
fwang |
132149 |
BuildRequires: pkgconfig(xrandr) |
25 |
|
|
BuildRequires: pkgconfig(xcursor) |
26 |
|
|
BuildRequires: pkgconfig(xinerama) |
27 |
|
|
BuildRequires: pkgconfig(xt) |
28 |
fwang |
132143 |
|
29 |
|
|
%description |
30 |
|
|
Mozc is a Japanese Input Method Editor (IME) designed for |
31 |
|
|
multi-platform such as Chromium OS, Windows, Mac and Linux. |
32 |
|
|
This open-source project originates from Google Japanese Input. |
33 |
|
|
|
34 |
|
|
%package -n ibus-mozc |
35 |
|
|
Group: System/Internationalization |
36 |
|
|
Summary: Ibus - mozc engine |
37 |
|
|
Requires(post,preun): GConf2 |
38 |
|
|
Requires: ibus |
39 |
|
|
Requires: mozc = %{version} |
40 |
|
|
|
41 |
|
|
%description -n ibus-mozc |
42 |
|
|
ibus - mozc engine. |
43 |
|
|
|
44 |
|
|
%post -n ibus-%{name} |
45 |
|
|
%post_ibus_register_engine mozc ja |
46 |
|
|
|
47 |
|
|
%preun -n ibus-%{name} |
48 |
|
|
%preun_ibus_unregister_engine mozc |
49 |
|
|
|
50 |
|
|
%package tools |
51 |
|
|
Group: System/Internationalization |
52 |
|
|
Summary: Mozc config tools |
53 |
|
|
Requires: mozc = %{version} |
54 |
|
|
Requires: qt4-common |
55 |
|
|
|
56 |
|
|
%description tools |
57 |
|
|
Mozc config tools. |
58 |
|
|
|
59 |
|
|
%prep |
60 |
|
|
%setup -q -n mozc-%{version} |
61 |
|
|
|
62 |
|
|
# prepare the zipcode dictionary |
63 |
|
|
cp %SOURCE2 data/dictionary/ |
64 |
|
|
cp %SOURCE3 data/dictionary/ |
65 |
|
|
|
66 |
|
|
cd data/dictionary/ |
67 |
|
|
%__python ../../dictionary/gen_zip_code_seed.py \ |
68 |
|
|
--zip_code=KEN_ALL.CSV --jigyosyo=JIGYOSYO.CSV > ./zip_code_seed.tsv |
69 |
|
|
cd - |
70 |
|
|
|
71 |
|
|
%build |
72 |
|
|
# fix for x86_64 |
73 |
|
|
sed 's|/usr/lib/mozc|%_libdir/mozc|' < base/util.cc > base/util.cc.new |
74 |
|
|
mv -f base/util.cc.new base/util.cc |
75 |
|
|
|
76 |
|
|
%setup_compile_flags |
77 |
|
|
%__python build_mozc.py gyp |
78 |
|
|
%__python build_mozc.py build_tools -c Release |
79 |
|
|
%__python build_mozc.py build unix/ibus/ibus.gyp:ibus_mozc server/server.gyp:mozc_server gui/gui.gyp:mozc_tool -c Release |
80 |
|
|
|
81 |
|
|
%install |
82 |
|
|
rm -rf %buildroot |
83 |
|
|
|
84 |
|
|
# install ibus-mozc |
85 |
|
|
mkdir -p %buildroot/%_libdir/ibus-mozc |
86 |
|
|
cp -p out_linux/Release/ibus_mozc %buildroot/%_libexecdir/ibus-mozc/ibus-engine-mozc |
87 |
|
|
mkdir -p %buildroot/%_datadir/ibus/component/ |
88 |
|
|
sed 's|/usr/libexec/ibus-engine-mozc|%_libexecdir/ibus-mozc/ibus-engine-mozc|' < out_linux/Release/obj/gen/unix/ibus/mozc.xml > %buildroot/%_datadir/ibus/component/mozc.xml |
89 |
|
|
|
90 |
|
|
# install mozc-server |
91 |
|
|
mkdir -p %buildroot/%_libdir/mozc/ |
92 |
|
|
cp -p out_linux/Release/mozc_server %buildroot/%_libexecdir/mozc/ |
93 |
|
|
|
94 |
|
|
# install mozc-tools |
95 |
|
|
cp -p out_linux/Release/mozc_tool %buildroot/%_libexecdir/mozc/ |
96 |
|
|
|
97 |
|
|
%clean |
98 |
|
|
rm -rf $RPM_BUILD_ROOT |
99 |
|
|
|
100 |
|
|
%files |
101 |
|
|
%defattr(-,root,root) |
102 |
|
|
%{_libexecdir}/mozc/mozc_server |
103 |
|
|
|
104 |
|
|
%files -n ibus-mozc |
105 |
|
|
%defattr(-,root,root) |
106 |
|
|
%{_libexecdir}/ibus-mozc/ibus-engine-mozc |
107 |
|
|
%{_datadir}/ibus/component/mozc.xml |
108 |
|
|
|
109 |
|
|
%files tools |
110 |
|
|
%defattr(-,root,root) |
111 |
|
|
%{_libexecdir}/mozc/mozc_tool |
112 |
|
|
|
113 |
|
|
|