]> git.pld-linux.org Git - packages/tomoe.git/blame - tomoe.spec
- added ruby patch, package ruby binding
[packages/tomoe.git] / tomoe.spec
CommitLineData
ad34972e
JR
1#
2# Conditional build:
19d2e237
JB
3%bcond_without python # build without Python bindings
4%bcond_without ruby # build without Ruby bindings
ad34972e
JR
5%bcond_without static_libs # don't build static libraries
6#
7Summary: Handwritten input system for Japanese and Chinese
c325a108 8Summary(pl.UTF-8): System wprowadzania pisma ręcznego dla japońskiego i chińskiego
ad34972e
JR
9Name: tomoe
10Version: 0.6.0
bd1c1328 11Release: 8
ad34972e
JR
12License: LGPL v2+
13Group: Libraries
14Source0: http://downloads.sourceforge.net/tomoe/%{name}-%{version}.tar.gz
15# Source0-md5: 0e51e88d097085e101bf722fc04808ed
16Patch0: %{name}-multiarch-conflict.patch
17Patch1: %{name}-bz502662.patch
18Patch2: %{name}-svn-libs.patch
d2cbbb84 19Patch3: %{name}-glib2.32.patch
19d2e237 20Patch4: %{name}-ruby.patch
ad34972e 21URL: http://tomoe.sourceforge.jp/
c325a108 22BuildRequires: apr-util-devel
19d2e237
JB
23BuildRequires: autoconf >= 2.57
24BuildRequires: automake
5fba1661
JB
25BuildRequires: gettext-devel
26BuildRequires: glib2-devel >= 1:2.4.0
27BuildRequires: gtk-doc >= 1.4
c325a108 28BuildRequires: hyperestraier-devel
5fba1661 29BuildRequires: intltool >= 0.35.0
19d2e237 30BuildRequires: libtool
5fba1661 31BuildRequires: libxslt-progs
c325a108
JB
32BuildRequires: mysql-devel
33BuildRequires: pakchois-devel
34BuildRequires: perl-XML-Parser
5fba1661 35BuildRequires: pkgconfig
ad34972e 36BuildRequires: python
c325a108 37BuildRequires: subversion-devel
ad34972e
JR
38%if %{with python}
39BuildRequires: python-devel
40BuildRequires: python-pygobject-devel
41BuildRequires: python-pygtk-devel
42%endif
43%if %{with ruby}
19d2e237 44BuildRequires: ruby-glib2-devel
ad34972e 45%endif
5fba1661 46Requires: glib2 >= 1:2.4.0
ad34972e
JR
47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
49%description
5fba1661 50A program which does Japanese and Chinese handwriting recognition.
ad34972e 51
c325a108 52%description -l pl.UTF-8
5fba1661 53Program rozpoznający japońskie i chińskie pismo ręczne.
c325a108 54
ad34972e 55%package devel
c325a108
JB
56Summary: Header files for tomoe library
57Summary(pl.UTF-8): Pliki nagłówkowe biblioteki tomoe
ad34972e
JR
58Group: Development/Libraries
59Requires: %{name} = %{version}-%{release}
5fba1661 60Requires: glib2-devel >= 1:2.4.0
ad34972e
JR
61
62%description devel
63The tomoe-devel package includes the header files for the tomoe
64package. Install this package if you want to develop programs which
65use tomoe.
66
c325a108
JB
67%description devel -l pl.UTF-8
68Ten pakiet zawiera pliki nagłówkowe biblioteki tomoe. Należy go
69zainstalować, aby rozwijać programy wykorzystujące tomoe.
70
ad34972e
JR
71%package static
72Summary: Tomoe static library
c325a108 73Summary(pl.UTF-8): Statyczna biblioteka tomoe
ad34972e
JR
74Group: Development/Libraries
75Requires: %{name}-devel = %{version}-%{release}
76
77%description static
78Tomoe static library.
79
c325a108
JB
80%description static -l pl.UTF-8
81Statyczna biblioteka tomoe.
82
ad34972e
JR
83%package hyperestraier
84Summary: Hyper Estraier dictionary support for tomoe
c325a108
JB
85Summary(pl.UTF-8): Obsługa słowników Hyper Estraiera dla tomoe
86Group: Libraries
87Requires: %{name} = %{version}-%{release}
ad34972e
JR
88
89%description hyperestraier
90Hyper Estraier dictionary support for tomoe.
91
c325a108
JB
92%description hyperestraier -l pl.UTF-8
93Obsługa słowników Hyper Estraiera dla tomoe.
94
ad34972e 95%package mysql
c325a108
JB
96Summary: MySQL dictionary support for tomoe
97Summary(pl.UTF-8): Obsługa słowników MySQL dla tomoe
98Group: Libraries
99Requires: %{name} = %{version}-%{release}
ad34972e
JR
100
101%description mysql
c325a108
JB
102MySQL dictionary support for tomoe.
103
104%description mysql -l pl.UTF-8
105Obsługa słowników MySQL dla tomoe.
ad34972e
JR
106
107%package svn
108Summary: Subversion dictionary support for tomoe
c325a108
JB
109Summary(pl.UTF-8): Obsługa słowników Subversion dla tomoe
110Group: Libraries
111Requires: %{name} = %{version}-%{release}
ad34972e
JR
112
113%description svn
114Subversion dictionary support for tomoe.
115
c325a108
JB
116%description svn -l pl.UTF-8
117Obsługa słowników Subversion dla tomoe.
118
ad34972e 119%package -n python-tomoe
c325a108
JB
120Summary: Tomoe bindings for Python
121Summary(pl.UTF-8): Wiązania tomoe dla Pythona
122Group: Libraries/Python
ad34972e
JR
123Requires: %{name} = %{version}-%{release}
124
125%description -n python-tomoe
c325a108
JB
126Tomoe bindings for Python.
127
128%description -n python-tomoe -l pl.UTF-8
129Wiązania tomoe dla Pythona.
ad34972e
JR
130
131%package -n ruby-tomoe
c325a108
JB
132Summary: Tomoe bindings for Ruby
133Summary(pl.UTF-8): Wiązania tomoe dla języka Ruby
134Group: Development/Languages
ad34972e 135Requires: %{name} = %{version}-%{release}
19d2e237 136Requires: ruby-glib2
ad34972e
JR
137
138%description -n ruby-tomoe
c325a108
JB
139Tomoe bindings for Ruby.
140
141%description -n ruby-tomoe -l pl.UTF-8
142Wiązania tomoe dla języka Ruby.
ad34972e 143
19d2e237
JB
144%package -n ruby-tomoe-devel
145Summary: Header file for Ruby/Tomoe library
146Summary(pl.UTF-8): Plik nagłówkowy biblioteki Ruby/Tomoe
147Group: Development/Libraries
148Requires: %{name}-devel = %{version}-%{release}
149Requires: ruby-glib2-devel
150Requires: ruby-tomoe = %{version}-%{release}
151
152%description -n ruby-tomoe-devel
153Header file for Ruby/Tomoe library.
154
155%description -n ruby-tomoe-devel -l pl.UTF-8
156Plik nagłówkowy biblioteki Ruby/Tomoe.
157
ad34972e
JR
158%prep
159%setup -q
160%patch0 -p0
161%patch1 -p0
162%patch2 -p1
d2cbbb84 163%patch3 -p1
19d2e237 164%patch4 -p1 -b .orig
ad34972e 165
19d2e237 166%{__sed} -i -e 's|#!/usr/bin/env ruby|#!/usr/bin/ruby|' data/xml2est.rb
ad34972e
JR
167
168%build
169%{__libtoolize}
170%{__aclocal} -I macros
171%{__autoconf}
172%{__automake}
173export CFLAGS="%{rpmcflags} -I/usr/include/apr-util"
174%configure \
5fba1661 175 UNZIP=/usr/bin/unzip \
ad34972e 176 %{!?with_static_libs:--disable-static} \
ad34972e 177 --enable-gtk-doc \
c325a108
JB
178 --with-html-dir=%{_gtkdocdir} \
179 --with-svn-lib=%{_libdir}
ad34972e
JR
180
181%{__make}
182
183%install
184rm -rf $RPM_BUILD_ROOT
ab01150c
JR
185install -d $RPM_BUILD_ROOT%{_datadir}/tomoe/dict
186
ad34972e
JR
187%{__make} install \
188 DESTDIR=$RPM_BUILD_ROOT
189
190%{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la
191%{__rm} $RPM_BUILD_ROOT%{_libdir}/tomoe/module/{dict,recognizer}/*.{a,la}
192%{__rm} $RPM_BUILD_ROOT%{py_sitedir}/tomoe.{a,la}
19d2e237 193%{?with_ruby:%{__rm} $RPM_BUILD_ROOT%{ruby_sitearchdir}/tomoe.{a,la}}
ad34972e 194
c325a108
JB
195%if %{without ruby}
196%{__rm} $RPM_BUILD_ROOT%{_datadir}/tomoe/xml2est.rb
197%endif
198
ad34972e
JR
199%find_lang %{name}
200
201%clean
202rm -rf $RPM_BUILD_ROOT
203
c325a108
JB
204%post -p /sbin/ldconfig
205%postun -p /sbin/ldconfig
ad34972e
JR
206
207%files -f %{name}.lang
208%defattr(644,root,root,755)
209%doc AUTHORS NEWS README TODO data/kanjidic*.html
210%dir %{_sysconfdir}/tomoe
211%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/tomoe/config
212%attr(755,root,root) %{_libdir}/libtomoe.so.*.*.*
c325a108 213%attr(755,root,root) %ghost %{_libdir}/libtomoe.so.0
ad34972e
JR
214%dir %{_libdir}/tomoe
215%dir %{_libdir}/tomoe/module
216%dir %{_libdir}/tomoe/module/dict
217%attr(755,root,root) %{_libdir}/tomoe/module/dict/unihan.so
218%attr(755,root,root) %{_libdir}/tomoe/module/dict/xml.so
219%dir %{_libdir}/tomoe/module/recognizer
220%attr(755,root,root) %{_libdir}/tomoe/module/recognizer/simple.so
221%dir %{_datadir}/tomoe
222%dir %{_datadir}/tomoe/dict
223%dir %{_datadir}/tomoe/recognizer
5fba1661 224%{_datadir}/tomoe/recognizer/handwriting-*.xml
ad34972e
JR
225%{_datadir}/tomoe/dict.dtd
226
227%files devel
228%defattr(644,root,root,755)
229%attr(755,root,root) %{_libdir}/libtomoe.so
230%{_includedir}/tomoe
231%{_pkgconfigdir}/tomoe.pc
232%{_gtkdocdir}/tomoe
233
234%if %{with static_libs}
235%files static
236%defattr(644,root,root,755)
237%{_libdir}/libtomoe.a
238%endif
239
240%files hyperestraier
241%defattr(644,root,root,755)
242%attr(755,root,root) %{_libdir}/tomoe/module/dict/est.so
243
244%files mysql
245%defattr(644,root,root,755)
246%attr(755,root,root) %{_libdir}/tomoe/module/dict/mysql.so
247
248%files svn
249%defattr(644,root,root,755)
250%attr(755,root,root) %{_libdir}/tomoe/module/dict/svn.so
251
ad34972e
JR
252%if %{with python}
253%files -n python-tomoe
254%defattr(644,root,root,755)
ad34972e
JR
255%attr(755,root,root) %{py_sitedir}/tomoe.so
256%{_datadir}/tomoe/python
c325a108 257%{_pkgconfigdir}/pytomoe.pc
ad34972e 258%endif
19d2e237
JB
259
260%if %{with ruby}
261%files -n ruby-tomoe
262%defattr(644,root,root,755)
263%attr(755,root,root) %{_datadir}/tomoe/xml2est.rb
264%attr(755,root,root) %{ruby_sitearchdir}/tomoe.so
265%{ruby_sitelibdir}/tomoe.rb
266
267%files -n ruby-tomoe-devel
268%defattr(644,root,root,755)
269%{ruby_sitearchdir}/rbtomoe.h
270%endif
This page took 0.155064 seconds and 4 git commands to generate.