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