libkkc-vl.spec 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265
  1. %define ver 0.3.3
  2. %define rel 1
  3. %define dataver 0.2.7
  4. %define datarel 3
  5. %define from_git 0
  6. %if %{from_git}
  7. %define githash ccfd5c6d
  8. %endif
  9. %if "%{?_dist_release}" == "vl6"
  10. %define with_vala 0
  11. %else
  12. %define with_vala 1
  13. %endif
  14. Summary: Japanese Kana Kanji conversion library (libkkc)
  15. Name: libkkc
  16. Version: %{ver}
  17. %if %{from_git}
  18. Release: %{rel}.git%{githash}%{_dist_release}
  19. %else
  20. Release: %{rel}%{_dist_release}
  21. %endif
  22. License: GPLv3+
  23. Group: System Environment/Libraries
  24. URL: https://bitbucket.org/libkkc/libkkc/
  25. %if %{from_git}
  26. Source0: libkkc-%{githash}.tar.gz
  27. %else
  28. Source0: https://bitbucket.org/libkkc/libkkc/downloads/%{name}-%{version}.tar.gz
  29. %endif
  30. Source1: https://bitbucket.org/libkkc/libkkc-data/downloads/%{name}-data-%{dataver}.tar.xz
  31. BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
  32. %if "%{?_dist_release}" == "vl6"
  33. BuildRequires: libgee-devel
  34. %else
  35. BuildRequires: libgee06-devel
  36. %endif
  37. BuildRequires: json-glib-devel
  38. BuildRequires: marisa-trie-devel
  39. # for libkkc-data
  40. BuildRequires: marisa-trie-python
  41. %if %{with_vala}
  42. BuildRequires: vala-devel
  43. BuildRequires: vala-tools
  44. %endif
  45. Requires: libkkc-data = %{dataver}-%{datarel}%{_dist_release}
  46. Requires: libkkc-common = %{version}-%{release}
  47. Vendor: Project Vine
  48. Distribution: Vine Linux
  49. Packager: iwaim
  50. %description
  51. libkkc provides a converter from Kana-string to
  52. Kana-Kanji-mixed-string. It was named after kkc.el in GNU Emacs, a
  53. simple Kana Kanji converter, while libkkc tries to convert sentences
  54. in a bit more complex way using N-gram language models.
  55. %package devel
  56. Summary: Header files and libraries for developing apps which will use libkkc
  57. Group: Development/Libraries
  58. Requires: %{name} = %{version}-%{release}
  59. %description devel
  60. The libkkc-devel package contains the header files and libraries.
  61. %package tools
  62. Summary: Tools for %{name}
  63. Group: Applications/Accessories
  64. Requires: %{name} = %{version}-%{release}
  65. %description tools
  66. The %{name}-tools package contains tools for developing applications
  67. that use %{name}.
  68. %package common
  69. Summary: Common data files for %{name}
  70. %description common
  71. The %{name}-common package contains the arch-independent data that
  72. %{name} uses at run time.
  73. %package data
  74. Summary: Data files for %{name}
  75. Version: %{dataver}
  76. Release: %{datarel}%{_dist_release}
  77. %description data
  78. The %{name}-data package contains the language model data that %{name}
  79. uses at run time.
  80. %prep
  81. %if %{from_git}
  82. %setup -q -n %{name}-%{githash}
  83. %else
  84. %setup -q
  85. %endif
  86. # for libkkc-data
  87. tar xf %{SOURCE1}
  88. %build
  89. %if %{from_git}
  90. ./autogen.sh
  91. %endif
  92. %configure --enable-shared \
  93. --disable-silent-rules \
  94. %if %{with_vala}
  95. --enable-vala=yes \
  96. %else
  97. --enable-vala=no \
  98. %endif
  99. %__make
  100. # for libkkc-data
  101. pushd %{name}-data-%{dataver}
  102. %configure
  103. %__make
  104. popd
  105. %install
  106. %__rm -rf $RPM_BUILD_ROOT
  107. %makeinstall
  108. # for libkkc-data
  109. pushd %{name}-data-%{dataver}
  110. %makeinstall
  111. popd
  112. %find_lang %{name}
  113. # remove files
  114. %__rm -f $RPM_BUILD_ROOT%{_libdir}/libkkc.la
  115. %clean
  116. %__rm -rf $RPM_BUILD_ROOT
  117. %post -p /sbin/ldconfig
  118. %postun -p /sbin/ldconfig
  119. %files -f %{name}.lang
  120. %defattr(-,root,root,-)
  121. %doc README ChangeLog COPYING AUTHORS NEWS
  122. %doc data/rules/README.rules
  123. %{_libdir}/libkkc.so.*
  124. %{_libdir}/girepository-1.0/Kkc-1.0.typelib
  125. %dir %{_datadir}/libkkc
  126. %{_datadir}/libkkc/rules
  127. %files devel
  128. %defattr(-,root,root,-)
  129. %doc COPYING AUTHORS
  130. %dir %{_includedir}/libkkc
  131. %{_includedir}/libkkc/libkkc.h
  132. %{_libdir}/libkkc.so
  133. %{_libdir}/pkgconfig/kkc-1.0.pc
  134. %{_datadir}/gir-1.0/Kkc-1.0.gir
  135. %{_datadir}/vala/vapi/kkc-1.0.deps
  136. %{_datadir}/vala/vapi/kkc-1.0.vapi
  137. %files tools
  138. %defattr(-,root,root,-)
  139. %doc COPYING AUTHORS
  140. %{_bindir}/kkc
  141. %{_bindir}/kkc-package-data
  142. %files common
  143. %defattr(-,root,root,-)
  144. %doc COPYING AUTHORS
  145. %dir %{_datadir}/libkkc
  146. %dir %{_datadir}/libkkc/templates
  147. %{_datadir}/libkkc/templates/libkkc-data
  148. %files data
  149. %defattr(-,root,root,-)
  150. %doc COPYING AUTHORS
  151. %dir %{_libdir}/libkkc
  152. %dir %{_libdir}/libkkc/models
  153. %{_libdir}/libkkc/models/sorted3
  154. %changelog
  155. * Sun Jun 15 2014 IWAI, Masaharu <iwaim.sub@gmail.com> 0.3.3-1
  156. - update to libkkc 0.3.3
  157. * Wed Dec 18 2013 IWAI, Masaharu <iwaim.sub@gmail.com> 0.3.2-1
  158. - update to libkkc 0.3.2
  159. * Thu Nov 7 2013 IWAI, Masaharu <iwaim.sub@gmail.com> 0.3.1-1
  160. - update to libkkc 0.3.1
  161. - update to libkkc-data 0.2.7
  162. - fix changelog for 0.2.6-1
  163. * Sat Jul 27 2013 IWAI, Masaharu <iwaim.sub@gmail.com> 0.2.6-1
  164. - update to libkkc 0.2.6
  165. - update to libkkc-data 0.2.5
  166. * Tue Jun 18 2013 IWAI, Masaharu <iwaim.sub@gmail.com> 0.2.4-1
  167. - update to libkkc 0.2.4
  168. - update to libkkc-data 0.2.0
  169. - add Version tag for libkkc-data sub package
  170. * Tue Mar 26 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.10-1
  171. - update to libkkc 0.1.10
  172. * Sat Mar 16 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.9-1
  173. - update to libkkc 0.1.9
  174. * Sun Mar 3 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.8-1
  175. - update to libkkc 0.1.8
  176. * Sat Feb 23 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.7-1
  177. - update to libkkc 0.1.7
  178. * Fri Feb 15 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.6-1
  179. - update to libkkc 0.1.6
  180. - update to libkkc-data 0.1.6
  181. * Mon Feb 11 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.5-1
  182. - update to libkkc 0.1.5
  183. * Fri Feb 8 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.3-1
  184. - update to 0.1.3
  185. - update License value: GPLv3 -> GPLv3+
  186. - add BuildRequires: marisa-trie-python for libkkc-data
  187. - sync upstream spec: http://ueno.fedorapeople.org/libkkc/libkkc.spec 0.1.3-2
  188. - create tools sub package
  189. - move %%{_bindir}/kkc
  190. - add %%{_bindir}/kkc-package-data
  191. - create common sub package
  192. - add template for generating libkkc-data
  193. - merge libkkc-data SRPM file
  194. - add libkkc-data source file (Source1)
  195. - create data sub package
  196. - add '--disable-silent-rules' option for configure
  197. - add Requires libkkc-data and libkkc-common
  198. - add document: data/rules/README.rules
  199. * Wed Feb 6 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.2-1
  200. - update to 0.1.2
  201. * Tue Feb 5 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.1-1
  202. - update to 0.1.1
  203. * Fri Feb 1 2013 IWAI, Masaharu <iwai@alib.jp> 0.1.0-1
  204. - update to 0.1.0
  205. - rename libkkc.pc to kkc-1.0.pc by upstream
  206. * Fri Feb 1 2013 IWAI, Masaharu <iwai@alib.jp> 0.0.3-3.gitccfd5c6d
  207. - update to git ccfd5c6d9f913e0a413fe5d0c45bb70032382f68
  208. - add post and postun script
  209. - add translate file
  210. * Tue Jan 29 2013 IWAI, Masaharu <iwai@alib.jp> 0.0.3-2
  211. - support Vine Linux 6
  212. - without Vala
  213. - BR: libgee-devel
  214. * Mon Jan 28 2013 IWAI, Masaharu <iwai@alib.jp> 0.0.3-1
  215. - initial build for Vine Linux