]> git.pld-linux.org Git - packages/libidn.git/blame - libidn.spec
- BR: jdk only with java
[packages/libidn.git] / libidn.spec
CommitLineData
2bd4615b 1# TODO:
b7ba59bb 2# - prepare package with web-files and java from contrib
2bd4615b 3#
2815d157 4# Conditional build:
acc88d94
ER
5%if "%{pld_release}" == "ac"
6%bcond_with dotnet # don't build C# binding
7%bcond_with java # don't build Java implementation
8%else
a59bf416
ER
9%bcond_without dotnet # don't build C# binding
10%bcond_without java # don't build Java implementation
acc88d94 11%endif
6f6febb4 12%bcond_without python # don't build python interface
2815d157 13#
4c6b08d0 14%ifnarch %{ix86} %{x8664} alpha arm hppa ppc s390 s390x sparc sparcv9 sparc64
043a7186
JB
15%undefine with_dotnet
16%endif
17%ifarch i386
18%undefine with_dotnet
19%endif
e2c9e4f6 20Summary: Internationalized string processing library
21d86bf8 21Summary(pl.UTF-8): Biblioteka do przetwarzania umiędzynarodowionych łańcuchów
e2c9e4f6 22Name: libidn
ffe3da5b 23Version: 1.19
09433a0d 24Release: 2
658a2f28 25License: LGPL v2.1+ (library), GPL v3+ (utilities)
e2c9e4f6 26Group: Libraries
268ecb6e 27Source0: http://ftp.gnu.org/gnu/libidn/%{name}-%{version}.tar.gz
ffe3da5b 28# Source0-md5: a45142126d28162014c995f969bdb5a8
e2c9e4f6 29Patch0: %{name}-info.patch
47ca58ee 30Patch1: %{name}-python.patch
cae643b1 31Patch2: %{name}-pl.po-update.patch
e2c9e4f6 32URL: http://www.gnu.org/software/libidn/
b3692cda
JB
33BuildRequires: autoconf >= 2.61
34BuildRequires: automake >= 1:1.10
b5892520 35%{?with_java:BuildRequires: gcc-java}
1ff0f822 36BuildRequires: gettext-devel >= 0.17
b5892520 37%{?with_java:BuildRequires: gjdoc}
d72098d7 38BuildRequires: help2man
55cffa15 39%{?with_java:BuildRequires: jdk}
5498ae81 40BuildRequires: libtool >= 2:1.5
043a7186 41%{?with_dotnet:BuildRequires: mono}
f22ac790 42BuildRequires: perl-base
d72098d7 43BuildRequires: pkgconfig
6f6febb4 44%{?with_python:BuildRequires: python-devel >= 1:2.3}
d72098d7 45BuildRequires: rpm >= 4.4.9-56
5ea30155 46%{?with_python:BuildRequires: rpm-pythonprov}
a281a682 47BuildRequires: rpmbuild(macros) >= 1.384
faf69423 48BuildRequires: texinfo >= 4.7
e2c9e4f6
JB
49Requires(post,postun): /sbin/ldconfig
50BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
51
ab54d2cd
JB
52# is it correct?
53%define _emacs_lispdir %{_datadir}/emacs/site-lisp
54
e2c9e4f6
JB
55%description
56GNU Libidn is an implementation of the Stringprep, Punycode and IDNA
57specifications defined by the IETF Internationalized Domain Names
58(IDN) working group, used for internationalized domain names.
59
3591cf04 60%description -l pl.UTF-8
e2c9e4f6 61GNU Libidn to implementacja specyfikacji Stringprep, Punycode i IDNA
3591cf04
JR
62zdefiniowanych przez grupę roboczą IETF Internationalized Domain Names
63(IDN), zajmującą się umiędzynarodowionymi nazwami domen.
e2c9e4f6
JB
64
65%package devel
66Summary: Header files for libidn library
21d86bf8 67Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libidn
658a2f28 68License: LGPL v2.1+
e2c9e4f6 69Group: Development/Libraries
5498ae81 70Requires: %{name} = %{version}-%{release}
e2c9e4f6
JB
71
72%description devel
73Header files for libidn library.
74
3591cf04
JR
75%description devel -l pl.UTF-8
76Pliki nagłówkowe biblioteki libidn.
e2c9e4f6
JB
77
78%package static
79Summary: Static libidn library
21d86bf8 80Summary(pl.UTF-8): Statyczna biblioteka libidn
658a2f28 81License: LGPL v2.1+
e2c9e4f6 82Group: Development/Libraries
5498ae81 83Requires: %{name}-devel = %{version}-%{release}
e2c9e4f6
JB
84
85%description static
86Static libidn library.
87
3591cf04 88%description static -l pl.UTF-8
e2c9e4f6
JB
89Statyczna biblioteka libidn.
90
043a7186
JB
91%package -n dotnet-libidn
92Summary: C# binding for libidn
21d86bf8 93Summary(pl.UTF-8): Wiązanie C# dla libidn
658a2f28 94License: LGPL v2.1+
043a7186
JB
95Group: Libraries
96Requires: %{name} = %{version}-%{release}
97
98%description -n dotnet-libidn
99C# binding for libidn.
100
3591cf04
JR
101%description -n dotnet-libidn -l pl.UTF-8
102Wiązanie C# dla libidn.
043a7186 103
ab54d2cd
JB
104%package -n emacs-libidn-pkg
105Summary: IDN support files for emacs
21d86bf8 106Summary(pl.UTF-8): Obsługa IDN dla emacsa
658a2f28 107License: GPL v3+
ab54d2cd 108Group: Applications/Editors/Emacs
5498ae81 109Requires: %{name} = %{version}-%{release}
ab54d2cd
JB
110
111%description -n emacs-libidn-pkg
112IDN support files for emacs.
113
3591cf04
JR
114%description -n emacs-libidn-pkg -l pl.UTF-8
115Obsługa IDN dla emacsa.
ab54d2cd 116
2815d157
JB
117%package -n java-libidn
118Summary: Java implementation of libidn
21d86bf8 119Summary(pl.UTF-8): Implementacja libidn w Javie
658a2f28 120License: LGPL v2.1+
2815d157
JB
121Group: Libraries
122Requires: jre
123
124%description -n java-libidn
125Java implementation of libidn (internationalized domain names
126library).
127
3591cf04
JR
128%description -n java-libidn -l pl.UTF-8
129Implementacja libidn (biblioteki umiędzynarodowionych nazw domen) w
2815d157
JB
130Javie.
131
132%package -n python-idn
133Summary: Python interface to libidn
21d86bf8 134Summary(pl.UTF-8): Pythonowy interfejs do libidn
658a2f28 135License: LGPL v2.1+
2815d157
JB
136Group: Libraries/Python
137Requires: %{name} = %{version}-%{release}
f671595e 138%pyrequires_eq python-libs
2815d157
JB
139
140%description -n python-idn
141Python interface to libidn (internationalized domain names library).
142
3591cf04
JR
143%description -n python-idn -l pl.UTF-8
144Pythonowy interfejs do libidn (biblioteki umiędzynarodowionych nazw
2815d157
JB
145domen).
146
e2c9e4f6
JB
147%prep
148%setup -q
b6e8491f 149%patch0 -p1
47ca58ee 150%patch1 -p1
cae643b1 151%patch2 -p1
48e22e2d
JB
152
153rm -f po/stamp-po
b6e8491f 154
5e5a643e
ER
155# avoid different builds having different timestamps
156# see http://lists.pld-linux.org/mailman/pipermail/pld-devel-en/2008-August/020363.html
55cffa15 157d='$Date: 2010-08-29 18:58:53 $'
aa2c1e29 158d=${d#?Date: }; d=${d%%%% *}; d=$(date -d "$d" '+%d %B %Y')
5e5a643e
ER
159%{__sed} -i -e "s,@value{UPDATED},$d,g" doc/libidn.texi
160
e2c9e4f6 161%build
8c25db64 162%{__gettextize}
ecce1191 163%{__libtoolize}
9242c4a5 164%{__aclocal} -I m4 -I gl/m4 -I lib/gl/m4
ecce1191
JB
165%{__autoconf}
166%{__autoheader}
167%{__automake}
949ca3bf 168JAR=%{_bindir}/fastjar \
ab54d2cd 169%configure \
043a7186 170 %{?with_dotnet:--enable-csharp=mono}%{!?with_dotnet:--disable-csharp} \
2815d157 171 %{?with_java:--enable-java} \
ab54d2cd 172 --with-lispdir=%{_emacs_lispdir}
e2c9e4f6
JB
173
174%{__make}
175
6f6febb4 176%if %{with python}
2815d157 177%{__make} -C contrib/idn-python \
e349ab8a 178 INCLUDE="%{py_incdir} %{rpmcflags} -I../../lib -L../../lib/.libs"
acc88d94 179mv contrib/idn-python/idn.so python-idn.so
6f6febb4 180%endif
2815d157 181
e2c9e4f6
JB
182%install
183rm -rf $RPM_BUILD_ROOT
184
185%{__make} install \
186 DESTDIR=$RPM_BUILD_ROOT
187
6f6febb4 188%if %{with python}
acc88d94 189install -D python-idn.so $RPM_BUILD_ROOT%{py_sitedir}/idn.so
6f6febb4 190%endif
2815d157 191
8c25db64
JB
192%find_lang %{name}
193
777b5108
ER
194rm -f $RPM_BUILD_ROOT%{_infodir}/dir
195
e2c9e4f6
JB
196%clean
197rm -rf $RPM_BUILD_ROOT
198
199%post
200/sbin/ldconfig
201[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir %{_infodir} >/dev/null 2>&1
202
203%postun
204/sbin/ldconfig
205[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir %{_infodir} >/dev/null 2>&1
206
8c25db64 207%files -f %{name}.lang
e2c9e4f6 208%defattr(644,root,root,755)
1b4dcaf7 209%doc AUTHORS ChangeLog FAQ NEWS README* THANKS TODO doc/libidn.html contrib
e2c9e4f6
JB
210%attr(755,root,root) %{_bindir}/idn
211%attr(755,root,root) %{_libdir}/libidn.so.*.*.*
1ff0f822 212%attr(755,root,root) %ghost %{_libdir}/libidn.so.11
e2c9e4f6
JB
213%{_mandir}/man1/idn.1*
214%{_infodir}/libidn.info*
98b8400c 215%{_infodir}/libidn-*.png
e2c9e4f6
JB
216
217%files devel
218%defattr(644,root,root,755)
219%attr(755,root,root) %{_libdir}/libidn.so
220%{_libdir}/libidn.la
1ff0f822
JB
221%{_includedir}/idn-*.h
222%{_includedir}/idna.h
223%{_includedir}/pr29.h
224%{_includedir}/punycode.h
225%{_includedir}/stringprep.h
226%{_includedir}/tld.h
e2c9e4f6 227%{_pkgconfigdir}/libidn.pc
cae643b1 228%{_mandir}/man3/idn_*.3*
1ff0f822
JB
229%{_mandir}/man3/idna_*.3*
230%{_mandir}/man3/pr29_*.3*
231%{_mandir}/man3/punycode_*.3*
232%{_mandir}/man3/stringprep*.3*
233%{_mandir}/man3/tld_*.3*
e2c9e4f6
JB
234
235%files static
236%defattr(644,root,root,755)
237%{_libdir}/libidn.a
ab54d2cd 238
043a7186
JB
239%if %{with dotnet}
240%files -n dotnet-libidn
241%defattr(644,root,root,755)
242# why not in gac? does it work here?
243%{_libdir}/Libidn.dll
244%endif
245
ab54d2cd
JB
246%files -n emacs-libidn-pkg
247%defattr(644,root,root,755)
248%{_emacs_lispdir}/*.el
2815d157
JB
249
250%if %{with java}
251%files -n java-libidn
252%defattr(644,root,root,755)
d72098d7 253%{_javadir}/libidn*.jar
2815d157
JB
254%endif
255
6f6febb4 256%if %{with python}
2815d157
JB
257%files -n python-idn
258%defattr(644,root,root,755)
259%attr(755,root,root) %{py_sitedir}/idn.so
6f6febb4 260%endif
This page took 0.124234 seconds and 4 git commands to generate.