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