3 %bcond_with foma # use foma by linking with libfoma (GPL v2-strict, which is not compliant)
4 %bcond_without readline # readline in interactive programs
6 Summary: Helsinki Finite-State Transducer (library and application suite)
7 Summary(pl.UTF-8): Helsinki Finite-State Transducer (biblioteka i zestaw aplikacji)
12 Group: Applications/Text
13 Source0: http://downloads.sourceforge.net/hfst/%{name}-%{version}.tar.gz
14 # Source0-md5: 4632cef7aa20564dba25eec3747f069a
15 Patch0: %{name}-pc.patch
16 Patch1: %{name}-link.patch
17 URL: http://www.ling.helsinki.fi/kieliteknologia/tutkimus/hfst/
18 BuildRequires: SFST-devel
19 BuildRequires: autoconf >= 2.62
20 BuildRequires: automake >= 1:1.11
22 BuildRequires: flex >= 2.5.35
23 BuildRequires: glib2-devel >= 1:2.16
24 BuildRequires: libstdc++-devel
25 BuildRequires: libtool >= 2:2.2
26 # would be used only with --enable-expand-equivalences, but header checks are broken (no -I...)
27 #BuildRequires: libxml2-devel >= 2
28 BuildRequires: ncurses-devel
29 BuildRequires: openfst-devel
30 BuildRequires: pkgconfig >= 1:0.14
31 BuildRequires: python >= 2.4
32 %{?with_readline:BuildRequires: readline-devel}
34 BuildRequires: foma-devel
35 BuildRequires: zlib-devel
37 Requires: glib2 >= 1:2.16
38 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41 The Helsinki Finite-State Transducer software is intended for the
42 implementation of morphological analysers and other tools which are
43 based on weighted and unweigted finite-state transducer technology.
45 %description -l pl.UTF-8
46 Pakiet HFST (Helsinki Finite-State Transducer) to oprogramowanie
47 służące do implementacji analizatorów morfologicznych i innych
48 narzędzi opartych na technice przetwarzania ze skończoną liczbą
49 stanów z wagami lub bez.
52 Summary: Header files for HFST library
53 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki HFST
54 Group: Development/Libraries
55 Requires: %{name} = %{version}-%{release}
57 %{?with_foma:Requires: foma-devel}
58 Requires: glib2-devel >= 1:2.16
59 Requires: libstdc++-devel
60 Requires: openfst-devel
63 Header files for HFST library.
65 %description devel -l pl.UTF-8
66 Pliki nagłówkowe biblioteki HFST.
69 Summary: Static HFST library
70 Summary(pl.UTF-8): Statyczna biblioteka HFST
71 Group: Development/Libraries
72 Requires: %{name}-devel = %{version}-%{release}
77 %description static -l pl.UTF-8
78 Statyczna biblioteka HFST.
92 FOMACLI=/usr/bin/foma \
94 --disable-silent-rules \
96 %{?with_readline:--with-readline} \
97 --with-unicode-handler=glib \
98 %{!?with_foma:--without-foma}
103 rm -rf $RPM_BUILD_ROOT
106 DESTDIR=$RPM_BUILD_ROOT
108 # obsoleted by pkgconfig
109 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libhfst.la
111 # for transducer data
112 install -d $RPM_BUILD_ROOT%{_datadir}/hfst
115 rm -rf $RPM_BUILD_ROOT
117 %post -p /sbin/ldconfig
118 %postun -p /sbin/ldconfig
121 %defattr(644,root,root,755)
122 %doc AUTHORS NEWS README THANKS
123 %attr(755,root,root) %{_bindir}/hfst-*
124 %attr(755,root,root) %{_bindir}/htwolcpre*
125 %attr(755,root,root) %{_libdir}/libhfst.so.*.*.*
126 %attr(755,root,root) %ghost %{_libdir}/libhfst.so.28
127 %dir %{_datadir}/hfst
128 %{_mandir}/man1/hfst-*.1*
131 %defattr(644,root,root,755)
132 %attr(755,root,root) %{_libdir}/libhfst.so
134 %{_aclocaldir}/hfst.m4
135 %{_pkgconfigdir}/hfst.pc
138 %defattr(644,root,root,755)