]> git.pld-linux.org Git - packages/libidn.git/blob - libidn.spec
- added DESTDIR patch, fixed build with java
[packages/libidn.git] / libidn.spec
1 # TODO:
2 # - prepare package with web-files and java from contrib
3 #
4 # Conditional build:
5 %bcond_with     java    # build Java implementation
6 #
7 Summary:        Internationalized string processing library
8 Summary(pl):    Biblioteka do przetwarzania umiêdzynarodowionych ³añcuchów
9 Name:           libidn
10 Version:        0.4.9
11 Release:        1
12 License:        LGPL v2.1
13 Group:          Libraries
14 Source0:        http://josefsson.org/libidn/releases/%{name}-%{version}.tar.gz
15 # Source0-md5:  cc87a7bdce60a6e229f0984ca551e273
16 Patch0:         %{name}-info.patch
17 Patch1:         %{name}-python.patch
18 Patch2:         %{name}-DESTDIR.patch
19 URL:            http://www.gnu.org/software/libidn/
20 BuildRequires:  autoconf >= 2.59
21 BuildRequires:  automake >= 1.8
22 BuildRequires:  gettext-devel >= 0.14.1
23 %{?with_java:BuildRequires:     jdk}
24 BuildRequires:  libtool >= 2:1.5
25 BuildRequires:  python-devel
26 BuildRequires:  texinfo >= 4.7
27 Requires(post,postun):  /sbin/ldconfig
28 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30 # is it correct?
31 %define         _emacs_lispdir  %{_datadir}/emacs/site-lisp
32
33 %description
34 GNU Libidn is an implementation of the Stringprep, Punycode and IDNA
35 specifications defined by the IETF Internationalized Domain Names
36 (IDN) working group, used for internationalized domain names.
37
38 %description -l pl
39 GNU Libidn to implementacja specyfikacji Stringprep, Punycode i IDNA
40 zdefiniowanych przez grupê robocz± IETF Internationalized Domain Names
41 (IDN), zajmuj±c± siê umiêdzynarodowionymi nazwami domen.
42
43 %package devel
44 Summary:        Header files for libidn library
45 Summary(pl):    Pliki nag³ówkowe biblioteki libidn
46 Group:          Development/Libraries
47 Requires:       %{name} = %{version}-%{release}
48
49 %description devel
50 Header files for libidn library.
51
52 %description devel -l pl
53 Pliki nag³ówkowe biblioteki libidn.
54
55 %package static
56 Summary:        Static libidn library
57 Summary(pl):    Statyczna biblioteka libidn
58 Group:          Development/Libraries
59 Requires:       %{name}-devel = %{version}-%{release}
60
61 %description static
62 Static libidn library.
63
64 %description static -l pl
65 Statyczna biblioteka libidn.
66
67 %package -n emacs-libidn-pkg
68 Summary:        IDN support files for emacs
69 Summary(pl):    Obs³uga IDN dla emacsa
70 Group:          Applications/Editors/Emacs
71 Requires:       %{name} = %{version}-%{release}
72
73 %description -n emacs-libidn-pkg
74 IDN support files for emacs.
75
76 %description -n emacs-libidn-pkg -l pl
77 Obs³uga IDN dla emacsa.
78
79 %package -n java-libidn
80 Summary:        Java implementation of libidn
81 Summary(pl):    Implementacja libidn w Javie
82 Group:          Libraries
83 Requires:       jre
84
85 %description -n java-libidn
86 Java implementation of libidn (internationalized domain names
87 library).
88
89 %description -n java-libidn -l pl
90 Implementacja libidn (biblioteki umiêdzynarodowionych nazw domen) w
91 Javie.
92
93 %package -n python-idn
94 Summary:        Python interface to libidn
95 Summary(pl):    Pythonowy interfejs do libidn
96 Group:          Libraries/Python
97 Requires:       %{name} = %{version}-%{release}
98 %pyrequires_eq  python-lib
99
100 %description -n python-idn
101 Python interface to libidn (internationalized domain names library).
102
103 %description -n python-idn -l pl
104 Pythonowy interfejs do libidn (biblioteki umiêdzynarodowionych nazw
105 domen).
106
107 %prep
108 %setup -q
109 %patch0 -p1
110 %patch1 -p1
111 %patch2 -p1
112
113 %build
114 %{__gettextize}
115 %{__libtoolize}
116 %{__aclocal} -I m4
117 %{__autoconf}
118 %{__autoheader}
119 %{__automake}
120 %configure \
121         %{?with_java:--enable-java} \
122         --with-lispdir=%{_emacs_lispdir}
123
124 %{__make}
125
126 %{__make} -C contrib/idn-python \
127         INCLUDE="/usr/include/python2.3 %{rpmcflags} -I../../lib -L../../lib/.libs"
128
129 %install
130 rm -rf $RPM_BUILD_ROOT
131
132 %{__make} install \
133         DESTDIR=$RPM_BUILD_ROOT
134
135 install -D contrib/idn-python/idn.so $RPM_BUILD_ROOT%{py_sitedir}/idn.so
136
137 %find_lang %{name}
138
139 %clean
140 rm -rf $RPM_BUILD_ROOT
141
142 %post
143 /sbin/ldconfig
144 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir %{_infodir} >/dev/null 2>&1
145
146 %postun
147 /sbin/ldconfig
148 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir %{_infodir} >/dev/null 2>&1
149
150 %files -f %{name}.lang
151 %defattr(644,root,root,755)
152 %doc AUTHORS ChangeLog FAQ NEWS README* THANKS TODO doc/libidn.html contrib
153 %attr(755,root,root) %{_bindir}/idn
154 %attr(755,root,root) %{_libdir}/libidn.so.*.*.*
155 %{_mandir}/man1/idn.1*
156 %{_infodir}/libidn.info*
157
158 %files devel
159 %defattr(644,root,root,755)
160 %attr(755,root,root) %{_libdir}/libidn.so
161 %{_libdir}/libidn.la
162 %{_includedir}/*.h
163 %{_pkgconfigdir}/libidn.pc
164 %{_mandir}/man3/*
165
166 %files static
167 %defattr(644,root,root,755)
168 %{_libdir}/libidn.a
169
170 %files -n emacs-libidn-pkg
171 %defattr(644,root,root,755)
172 %{_emacs_lispdir}/*.el
173
174 %if %{with java}
175 %files -n java-libidn
176 %defattr(644,root,root,755)
177 %{_datadir}/java/libidn*.jar
178 %endif
179
180 %files -n python-idn
181 %defattr(644,root,root,755)
182 %attr(755,root,root) %{py_sitedir}/idn.so
This page took 0.0940299999999999 seconds and 4 git commands to generate.