]> git.pld-linux.org Git - packages/hfst.git/blame - hfst.spec
- updated to 3.9.0 (note: new soname)
[packages/hfst.git] / hfst.spec
CommitLineData
fee79ac8
JB
1#
2# Conditional build:
8fe469ce 3%bcond_without python3 # Python 3 binding
f19640b3 4%bcond_without readline # readline in interactive programs
fee79ac8 5#
ca7f1440
JB
6Summary: Helsinki Finite-State Transducer (library and application suite)
7Summary(pl.UTF-8): Helsinki Finite-State Transducer (biblioteka i zestaw aplikacji)
8Name: hfst
8fe469ce 9Version: 3.9.0
1cc1cae0 10Release: 1
fee79ac8 11License: GPL v3
ca7f1440
JB
12Group: Applications/Text
13Source0: http://downloads.sourceforge.net/hfst/%{name}-%{version}.tar.gz
8fe469ce 14# Source0-md5: b1fb133e5ef27bb059bb15cdd558f17d
fee79ac8 15Patch0: %{name}-pc.patch
ca7f1440 16URL: http://www.ling.helsinki.fi/kieliteknologia/tutkimus/hfst/
8fe469ce
JB
17# bundled library is used
18#BuildRequires: SFST-devel
fee79ac8
JB
19BuildRequires: autoconf >= 2.62
20BuildRequires: automake >= 1:1.11
ca7f1440
JB
21BuildRequires: bison
22BuildRequires: flex >= 2.5.35
f19640b3 23BuildRequires: glib2-devel >= 1:2.16
ca7f1440 24BuildRequires: libstdc++-devel
f19640b3 25BuildRequires: libtool >= 2:2.2
8fe469ce 26# disabled in sources
f19640b3
JB
27#BuildRequires: libxml2-devel >= 2
28BuildRequires: ncurses-devel
8fe469ce
JB
29# bundled library is used
30#BuildRequires: openfst-devel
f19640b3 31BuildRequires: pkgconfig >= 1:0.14
8fe469ce
JB
32BuildRequires: python >= 1:2.4
33%{?with_python3:BuildRequires: python3 >= 1:3.2}
f19640b3 34%{?with_readline:BuildRequires: readline-devel}
8fe469ce
JB
35BuildRequires: rpm-pythonprov
36BuildRequires: rpmbuild(macros) >= 1.714
37%{?with_python3:BuildRequires: swig-python}
d788e1f5 38BuildRequires: zlib-devel
f19640b3 39Requires: glib2 >= 1:2.16
ca7f1440
JB
40BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42%description
43The Helsinki Finite-State Transducer software is intended for the
44implementation of morphological analysers and other tools which are
45based on weighted and unweigted finite-state transducer technology.
46
47%description -l pl.UTF-8
48Pakiet HFST (Helsinki Finite-State Transducer) to oprogramowanie
49służące do implementacji analizatorów morfologicznych i innych
50narzędzi opartych na technice przetwarzania ze skończoną liczbą
51stanów z wagami lub bez.
52
8fe469ce
JB
53%package tagger
54Summary: HFST Tagger scripts
55Summary(pl.UTF-8): Skrypty HFST Tagger
56Group: Applications/Text
57Requires: %{name} = %{version}-%{release}
58
59%description tagger
60HFST Tagger scripts written in Python.
61
62%description tagger -l pl.UTF-8
63Skrypty HFST Tagger napisane w Pythonie.
64
ca7f1440
JB
65%package devel
66Summary: Header files for HFST library
67Summary(pl.UTF-8): Pliki nagłówkowe biblioteki HFST
68Group: Development/Libraries
69Requires: %{name} = %{version}-%{release}
8fe469ce 70#Requires: SFST-devel
f19640b3 71Requires: glib2-devel >= 1:2.16
ca7f1440 72Requires: libstdc++-devel
8fe469ce
JB
73#Requires: openfst-devel
74Requires: readline-devel
ca7f1440
JB
75
76%description devel
77Header files for HFST library.
78
79%description devel -l pl.UTF-8
80Pliki nagłówkowe biblioteki HFST.
81
82%package static
83Summary: Static HFST library
84Summary(pl.UTF-8): Statyczna biblioteka HFST
85Group: Development/Libraries
86Requires: %{name}-devel = %{version}-%{release}
87
88%description static
89Static HFST library.
90
91%description static -l pl.UTF-8
92Statyczna biblioteka HFST.
93
8fe469ce
JB
94%package -n python3-hfst
95Summary: Python 3 binding for HFST library
96Summary(pl.UTF-8): Wiązanie Pythona 3 do biblioteki HFST
97Group: Libraries/Python
98Requires: %{name} = %{version}-%{release}
99
100%description -n python3-hfst
101Python 3 binding for HFST library.
102
103%description -n python3-hfst -l pl.UTF-8
104Wiązanie Pythona 3 do biblioteki HFST.
105
ca7f1440
JB
106%prep
107%setup -q
108%patch0 -p1
ca7f1440
JB
109
110%build
ca7f1440
JB
111%{__libtoolize}
112%{__aclocal}
113%{__autoconf}
114%{__autoheader}
115%{__automake}
ca7f1440 116%configure \
8fe469ce
JB
117 --enable-calculate \
118 --enable-foma-wrapper \
942c090f 119 --enable-lexc \
8fe469ce 120 --enable-lexc-wrapper \
fee79ac8 121 --disable-silent-rules \
8fe469ce
JB
122 --enable-tagger \
123 --enable-xfst \
f19640b3 124 %{?with_readline:--with-readline} \
9d1cebdc 125 --with-unicode-handler=glib
ca7f1440 126
575da813
JB
127# parallel build is broken with foma backend
128%{__make} -j1
ca7f1440 129
8fe469ce
JB
130%if %{with python3}
131cd python
132%py3_build
133%endif
134
ca7f1440
JB
135%install
136rm -rf $RPM_BUILD_ROOT
8fe469ce 137install -d $RPM_BUILD_ROOT%{_bindir}
ca7f1440
JB
138
139%{__make} install \
140 DESTDIR=$RPM_BUILD_ROOT
141
8fe469ce 142%py_postclean
fee79ac8
JB
143# obsoleted by pkgconfig
144%{__rm} $RPM_BUILD_ROOT%{_libdir}/libhfst.la
145
7cf9be20
JB
146# for transducer data
147install -d $RPM_BUILD_ROOT%{_datadir}/hfst
148
8fe469ce
JB
149%if %{with python3}
150cd python
151%py3_install
152%endif
153
ca7f1440
JB
154%clean
155rm -rf $RPM_BUILD_ROOT
156
157%post -p /sbin/ldconfig
158%postun -p /sbin/ldconfig
159
160%files
161%defattr(644,root,root,755)
01963880 162%doc AUTHORS NEWS README THANKS
ca7f1440 163%attr(755,root,root) %{_bindir}/hfst-*
9d1cebdc 164%attr(755,root,root) %{_bindir}/hfst_foma
ca7f1440 165%attr(755,root,root) %{_bindir}/htwolcpre*
ca7f1440 166%attr(755,root,root) %{_libdir}/libhfst.so.*.*.*
8fe469ce 167%attr(755,root,root) %ghost %{_libdir}/libhfst.so.42
7cf9be20 168%dir %{_datadir}/hfst
ca7f1440 169%{_mandir}/man1/hfst-*.1*
8fe469ce
JB
170%{_mandir}/man1/htwolcpre?.1*
171
172%files tagger
173%defattr(644,root,root,755)
174%attr(755,root,root) %{_bindir}/hfst_tagger_compute_data_statistics.py
175%{py_sitescriptdir}/hfst_tagger_compute_data_statistics.py[co]
176%{py_sitescriptdir}/tagger_aux.py[co]
177%{_mandir}/man1/hfst_tagger_compute_data_statistics.py.1*
ca7f1440
JB
178
179%files devel
180%defattr(644,root,root,755)
181%attr(755,root,root) %{_libdir}/libhfst.so
fee79ac8 182%{_includedir}/hfst
d788e1f5 183%{_aclocaldir}/hfst.m4
ca7f1440
JB
184%{_pkgconfigdir}/hfst.pc
185
186%files static
187%defattr(644,root,root,755)
188%{_libdir}/libhfst.a
8fe469ce
JB
189
190%if %{with python3}
191%files -n python3-hfst
192%defattr(644,root,root,755)
193%attr(755,root,root) %{py3_sitedir}/_libhfst.cpython-*.so
194%{py3_sitedir}/libhfst.py
195%{py3_sitedir}/__pycache__/libhfst.cpython-*.py[co]
196%{py3_sitedir}/libhfst_swig-%{version}_beta-py*.egg-info
197%endif
This page took 0.096841 seconds and 4 git commands to generate.