mozc-vl.spec 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251
  1. %define ver 0.11.0
  2. %define rel 9
  3. %define svnrev 28
  4. %define utdic 20100601
  5. %define enable_utdic_jinmei 0
  6. %define enable_utdic_zipcode 0
  7. %define enable_utdic_meisi 0
  8. %define enable_utdic_jigyosyo 0
  9. %define enable_edict_katakanago 0
  10. Name: mozc
  11. Summary: Japanese Input Method Editor designed for multi-platform
  12. Summary(ja): マルチプラットホームで動くように設計された日本語インプットメソッドエディタ
  13. Version: 0.11.0
  14. Release: %{rel}.svn%{svnrev}%{?_dist_release}
  15. Group: System Environment/Libraries
  16. License: BSD-like (and EDICT is CC-by-sa 3.0 Unported)
  17. URL: http://code.google.com/p/mozc/
  18. # Source tar ball is not released yet.
  19. # See http://code.google.com/p/mozc/wiki/LinuxBuildInstructions
  20. Source0: %{name}-%{version}-r%{svnrev}.tar.bz2
  21. # Additional dictionaries by UTUMI Hirosi
  22. Source1: mozcdic-ut-%{utdic}.tar.bz2
  23. # http://twitpic.com/1ouyrr by AWASHIRO Ikuya
  24. Source3: ibus-mozc.png
  25. # http://twitpic.com/1t0zkb by AWASHIRO Ikuya
  26. Source4: ibus-mozc-unknown.png
  27. # Vine Lunux
  28. Source10: README.vine
  29. #Patch0: ibus-mozc-fix-for-x86_64.diff
  30. Patch1: ibus-mozc-0.11.0-fix-compile-w-i386.patch
  31. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  32. BuildRequires: python, ibus-devel, dbus-devel
  33. BuildRequires: openssl-devel, zlib-devel
  34. BuildRequires: curl-devel
  35. BuildRequires: protobuf-devel, gtest-devel
  36. BuildRequires: qt4-devel
  37. BuildRequires: gyp
  38. Requires: mozc-server = %{version}-%{release}
  39. Requires: mozc-utils-gui = %{version}-%{release}
  40. Requires: ibus-mozc = %{version}-%{release}
  41. Packager: kazutaka
  42. %description
  43. Mozc is a Japanese Input Method Editor (IME) designed for
  44. multi-platform such as Chromium OS, Windows, Mac and Linux.
  45. This open-source project originates from Google Japanese Input.
  46. %description -l ja
  47. Mozc は日本語入力用の IME (Imput Method Editor)です。
  48. Chromium OS や Windows、Mac、Linux といったマルチプラット
  49. フォームで利用できるようにデザインされており、「Google日本語
  50. 入力」のオープンソース版です。
  51. %package server
  52. Summary: Server part of the Mozc input method
  53. Summary(ja): Mozc インプットメソッドのサーバ部分
  54. Group: Applications/System
  55. %description server
  56. Server part of the Mozc input method, used by Mozc clients such as
  57. ibus-mozc.
  58. %description server -l ja
  59. Mozc インプットメソッドのサーバ部分。ibus-mozcなどのMozcクライアントから
  60. 使うことができます。
  61. %package -n ibus-mozc
  62. Summary: iBus engine module for Mozc
  63. Summary(ja): Mozc 用 iBus エンジンモジュール
  64. Group: System Environment/Libraries
  65. Requires: mozc-server = %{version}-%{release}
  66. %description -n ibus-mozc
  67. iBus engine module for Mozc.
  68. %description -n ibus-mozc -l ja
  69. Mozc 用 iBus エンジンモジュール。
  70. %package utils-gui
  71. Summary: Mozc GUI utilities
  72. Summary(ja): Mozc GUI ユーティリティー
  73. Group: Applications/System
  74. Requires: qt4
  75. Requires: mozc-server = %{version}-%{release}
  76. %description utils-gui
  77. Mozc GUI uitilities, such as the configuration dialog, user dictionary
  78. tool and about dialog.
  79. %description utils-gui -l ja
  80. Mozc GUI ユーティリティー。設定ツールやユーザ辞書ツールなどが含まれます。
  81. %prep
  82. %setup -q -n %{name}-%{version}-r%{svnrev} -a 1
  83. #%patch0 -p0 -b .fix-x86_64
  84. %patch1 -p1 -b .fix-i386
  85. # update execute files path
  86. %{__sed} -i -e"s|/usr/lib/mozc|%{_libexecdir}|g" base/util.cc
  87. # Add some dictionaries
  88. pushd mozcdic-ut-%{utdic}
  89. %{__cp} mozcdic-ut-jinmei-*.txt ../data/dictionary/
  90. %{__cp} mozcdic-ut-zipcode-*.txt ../data/dictionary/
  91. %{__cp} mozcdic-ut-meisi-*.txt ../data/dictionary/
  92. %{__cp} mozcdic-ut-jigyosyo-*.txt ../data/dictionary/
  93. %{__cp} edict-katakanago/mozcdic-ut-edict-katakanago-*.txt ../data/dictionary/
  94. popd
  95. pushd data/dictionary/
  96. %{__cp} dictionary1.txt dictionary1.txt.new
  97. %if %{enable_utdic_jinmei}
  98. %{__cat} mozcdic-ut-jinmei-*.txt >> dictionary1.txt.new
  99. %endif
  100. %if %{enable_utdic_zipcode}
  101. %{__cat} mozcdic-ut-zipcode-*.txt >> dictionary1.txt.new
  102. %endif
  103. %if %{enable_utdic_meisi}
  104. %{__cat} mozcdic-ut-meisi-*.txt >> dictionary1.txt.new
  105. %endif
  106. %if %{enable_utdic_jigyosyo}
  107. %{__cat} mozcdic-ut-jigyosyo-*.txt >> dictionary1.txt.new
  108. %endif
  109. %if %{enable_edict_katakanago}
  110. %{__cat} mozcdic-ut-edict-katakanago-*.txt >> dictionary1.txt.new
  111. %endif
  112. %{__mv} dictionary1.txt.new dictionary1.txt
  113. popd
  114. %build
  115. %{__python} build_mozc.py gyp --gypdir=%{_bindir}
  116. %{__python} build_mozc.py build_tools -c Release
  117. %{__python} build_mozc.py build -c Release unix/ibus/ibus.gyp:ibus_mozc server/server.gyp:mozc_server gui/gui.gyp:mozc_tool
  118. %install
  119. %{__rm} -rf %{buildroot}
  120. %{__mkdir_p} %{buildroot}%{_libdir}
  121. %{__mkdir_p} %{buildroot}%{_libexecdir}
  122. # ibus-mozc
  123. %{__cp} -p out/Release/ibus_mozc %{buildroot}%{_libdir}/ibus-engine-mozc
  124. %{__mkdir_p} %{buildroot}%{_datadir}/ibus/component/
  125. %{__sed} 's|/usr/libexec|%{_libdir}|' < unix/ibus/mozc.xml > %{buildroot}%{_datadir}/ibus/component/mozc.xml
  126. # mozc-server
  127. %{__cp} -p out/Release/mozc_server %{buildroot}%{_libexecdir}
  128. # mozc_tool
  129. %{__cp} -p out/Release/mozc_tool %{buildroot}%{_libexecdir}
  130. # install icon (temporary)
  131. %{__mkdir_p} %{buildroot}%{_datadir}/ibus-mozc/setup
  132. %{__cp} -p %{SOURCE3} %{buildroot}%{_datadir}/ibus-mozc/product_icon.png
  133. %{__cp} -p %{SOURCE4} %{buildroot}%{_datadir}/ibus-mozc/unknown.ico
  134. # install document
  135. %{__chmod} 644 debian/*
  136. %{__cp} debian/copyright COPYING
  137. %{__cp} %{SOURCE10} .
  138. %{__mkdir} utdic
  139. %{__cp} mozcdic-ut-%{utdic}/{AUTHORS,COPYING,ChangeLog,README} utdic
  140. %{__mkdir} edict
  141. %{__cp} mozcdic-ut-%{utdic}/edict-katakanago/README.edict edict
  142. %clean
  143. rm -rf $RPM_BUILD_ROOT
  144. %files
  145. %defattr(-,root,root)
  146. %doc COPYING README.vine utdic edict
  147. %files server
  148. %defattr(-,root,root)
  149. %doc COPYING README.vine utdic edict
  150. %{_libexecdir}/mozc_server
  151. %files utils-gui
  152. %defattr(-,root,root)
  153. %doc COPYING
  154. %{_libexecdir}/mozc_tool
  155. %files -n ibus-mozc
  156. %defattr(-,root,root)
  157. %doc COPYING
  158. %{_libdir}/ibus-engine-mozc
  159. %{_datadir}/ibus/component/mozc.xml
  160. %dir %{_datadir}/ibus-mozc
  161. %dir %{_datadir}/ibus-mozc/setup
  162. %{_datadir}/ibus-mozc/product_icon.png
  163. %{_datadir}/ibus-mozc/unknown.ico
  164. %changelog
  165. * Wed Jun 9 2010 IWAI, Masaharu <iwai@alib.jp> 0.11.0-9.svn28
  166. - update execute files path: <BTS:VineLinux:998>
  167. * Fri Jun 4 2010 IWAI, Masaharu <iwai@alib.jp> 0.11.0-8.svn28
  168. - disable all mozcdic-ut dictionary (disable jinmei and zipcode)
  169. - update README.vine
  170. - add BuildRequires: gyp
  171. - drop BuildRequires: subversion
  172. * Wed Jun 2 2010 IWAI, Masaharu <iwai@alib.jp> 0.11.0-7.svn28
  173. - add mozc_tool's icon (Source4)
  174. - rename Source0: fixed created directory name "src"
  175. * Tue Jun 1 2010 IWAI, Masaharu <iwai@alib.jp> 0.11.0-6.svn28
  176. - update mozcdic-ut 20100601 (Source10)
  177. - include documents for all dictionaries
  178. - add BuildRequires: qt4-devel
  179. * Tue Jun 1 2010 IWAI, Masaharu <iwai@alib.jp> 0.11.0-5.svn28
  180. - rename base name: mozc
  181. - add new sub packages:
  182. - mozc-server
  183. - mozc-utils-gui
  184. - update source to revision 28
  185. - replace icon (Source3)
  186. - drop mozc-config: upstream implement same tool
  187. * Sun May 23 2010 Kazutaka HARADA <kazutaka@vinelinux.org> 0.11.0-4
  188. - update source to revision 23
  189. - add BuildRequires protobuf-devel, gtest-devel
  190. - drop Patch0 (ibus-mozc-fix-for-x86_64.diff)
  191. - add mozc-config as Source10 and desktop entry as Source11
  192. * Sat May 15 2010 IWAI, Masaharu <iwai@alib.jp> 0.11.0-3
  193. - rebuild with ibus-1.3.3
  194. * Fri May 14 2010 Kazutaka HARADA <kazutaka@vinelinux.org> 0.11.0-2
  195. - add Patch1 to fix compile error on i386 (workaround patch)
  196. * Thu May 13 2010 Kazutaka HARADA <kazutaka@vinelinux.org> 0.11.0-1
  197. - initial build for Vine Liux based on custom mandriva package made by UTUMI-san
  198. * Thu May 13 2010 UTUMI Hirosi <utuhiro78@yahoo.co.jp> 0.11.0-2.20110511.1mdv2010.1
  199. - add some dictionaries
  200. * Wed May 12 2010 UTUMI Hirosi <utuhiro78@yahoo.co.jp> 0.11.0-1.20110511.1mdv2010.1
  201. - first release