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