2 # - prepare package with web-files and java from contrib
5 %bcond_without dotnet # don't build C# binding
6 %bcond_without java # don't build Java implementation
7 %bcond_without python # don't build python interface
9 %ifnarch %{ix86} %{x8664} alpha arm hppa ppc s390 s390x sparc sparcv9 sparc64
15 Summary: Internationalized string processing library
16 Summary(pl.UTF-8): Biblioteka do przetwarzania umiędzynarodowionych łańcuchów
20 License: LGPL v2.1+ (library), GPL v3+ (utilities)
22 Source0: http://josefsson.org/libidn/releases/%{name}-%{version}.tar.gz
23 # Source0-md5: c2483d26e87cb8ec1ad532bb6b5cf295
24 Patch0: %{name}-info.patch
25 Patch1: %{name}-python.patch
26 Patch2: %{name}-pl.po-update.patch
27 URL: http://www.gnu.org/software/libidn/
28 BuildRequires: autoconf >= 2.61
29 BuildRequires: automake >= 1:1.10
30 %{?with_java:BuildRequires: gcc-java}
31 BuildRequires: gettext-devel >= 0.17
32 %{?with_java:BuildRequires: gjdoc}
33 BuildRequires: libtool >= 2:1.5
34 %{?with_dotnet:BuildRequires: mono}
35 BuildRequires: perl-base
36 %{?with_python:BuildRequires: python-devel >= 1:2.3}
37 %{?with_python:BuildRequires: rpm-pythonprov}
38 BuildRequires: rpmbuild(macros) >= 1.384
39 BuildRequires: texinfo >= 4.7
40 Requires(post,postun): /sbin/ldconfig
41 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
44 %define _emacs_lispdir %{_datadir}/emacs/site-lisp
47 GNU Libidn is an implementation of the Stringprep, Punycode and IDNA
48 specifications defined by the IETF Internationalized Domain Names
49 (IDN) working group, used for internationalized domain names.
51 %description -l pl.UTF-8
52 GNU Libidn to implementacja specyfikacji Stringprep, Punycode i IDNA
53 zdefiniowanych przez grupę roboczą IETF Internationalized Domain Names
54 (IDN), zajmującą się umiędzynarodowionymi nazwami domen.
57 Summary: Header files for libidn library
58 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libidn
60 Group: Development/Libraries
61 Requires: %{name} = %{version}-%{release}
64 Header files for libidn library.
66 %description devel -l pl.UTF-8
67 Pliki nagłówkowe biblioteki libidn.
70 Summary: Static libidn library
71 Summary(pl.UTF-8): Statyczna biblioteka libidn
73 Group: Development/Libraries
74 Requires: %{name}-devel = %{version}-%{release}
77 Static libidn library.
79 %description static -l pl.UTF-8
80 Statyczna biblioteka libidn.
82 %package -n dotnet-libidn
83 Summary: C# binding for libidn
84 Summary(pl.UTF-8): Wiązanie C# dla libidn
87 Requires: %{name} = %{version}-%{release}
89 %description -n dotnet-libidn
90 C# binding for libidn.
92 %description -n dotnet-libidn -l pl.UTF-8
93 Wiązanie C# dla libidn.
95 %package -n emacs-libidn-pkg
96 Summary: IDN support files for emacs
97 Summary(pl.UTF-8): Obsługa IDN dla emacsa
99 Group: Applications/Editors/Emacs
100 Requires: %{name} = %{version}-%{release}
102 %description -n emacs-libidn-pkg
103 IDN support files for emacs.
105 %description -n emacs-libidn-pkg -l pl.UTF-8
106 Obsługa IDN dla emacsa.
108 %package -n java-libidn
109 Summary: Java implementation of libidn
110 Summary(pl.UTF-8): Implementacja libidn w Javie
115 %description -n java-libidn
116 Java implementation of libidn (internationalized domain names
119 %description -n java-libidn -l pl.UTF-8
120 Implementacja libidn (biblioteki umiędzynarodowionych nazw domen) w
123 %package -n python-idn
124 Summary: Python interface to libidn
125 Summary(pl.UTF-8): Pythonowy interfejs do libidn
127 Group: Libraries/Python
128 Requires: %{name} = %{version}-%{release}
129 %pyrequires_eq python-libs
131 %description -n python-idn
132 Python interface to libidn (internationalized domain names library).
134 %description -n python-idn -l pl.UTF-8
135 Pythonowy interfejs do libidn (biblioteki umiędzynarodowionych nazw
149 %{__aclocal} -I m4 -I gl/m4 -I lib/gl/m4
153 JAR=%{_bindir}/fastjar \
155 %{?with_dotnet:--enable-csharp=mono}%{!?with_dotnet:--disable-csharp} \
156 %{?with_java:--enable-java} \
157 --with-lispdir=%{_emacs_lispdir}
162 %{__make} -C contrib/idn-python \
163 INCLUDE="%{py_incdir} %{rpmcflags} -I../../lib -L../../lib/.libs"
167 rm -rf $RPM_BUILD_ROOT
170 DESTDIR=$RPM_BUILD_ROOT
173 install -D contrib/idn-python/idn.so $RPM_BUILD_ROOT%{py_sitedir}/idn.so
178 rm -f $RPM_BUILD_ROOT%{_infodir}/dir
181 rm -rf $RPM_BUILD_ROOT
185 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir %{_infodir} >/dev/null 2>&1
189 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir %{_infodir} >/dev/null 2>&1
191 %files -f %{name}.lang
192 %defattr(644,root,root,755)
193 %doc AUTHORS ChangeLog FAQ NEWS README* THANKS TODO doc/libidn.html contrib
194 %attr(755,root,root) %{_bindir}/idn
195 %attr(755,root,root) %{_libdir}/libidn.so.*.*.*
196 %attr(755,root,root) %ghost %{_libdir}/libidn.so.11
197 %{_mandir}/man1/idn.1*
198 %{_infodir}/libidn.info*
199 %{_infodir}/libidn-*.png
202 %defattr(644,root,root,755)
203 %attr(755,root,root) %{_libdir}/libidn.so
205 %{_includedir}/idn-*.h
206 %{_includedir}/idna.h
207 %{_includedir}/pr29.h
208 %{_includedir}/punycode.h
209 %{_includedir}/stringprep.h
211 %{_pkgconfigdir}/libidn.pc
212 %{_mandir}/man3/idna_*.3*
213 %{_mandir}/man3/pr29_*.3*
214 %{_mandir}/man3/punycode_*.3*
215 %{_mandir}/man3/stringprep*.3*
216 %{_mandir}/man3/tld_*.3*
219 %defattr(644,root,root,755)
223 %files -n dotnet-libidn
224 %defattr(644,root,root,755)
225 # why not in gac? does it work here?
226 %{_libdir}/Libidn.dll
229 %files -n emacs-libidn-pkg
230 %defattr(644,root,root,755)
231 %{_emacs_lispdir}/*.el
234 %files -n java-libidn
235 %defattr(644,root,root,755)
236 %{_datadir}/java/libidn*.jar
241 %defattr(644,root,root,755)
242 %attr(755,root,root) %{py_sitedir}/idn.so