source: projects/specs/trunk/lib/libk/libkkc/libkkc-vl.spec @ 10873

Revision 10873, 7.0 KB checked in by iwaim, 7 years ago (diff)

apply Patch1

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