]> git.pld-linux.org Git - packages/libplist.git/blob - libplist.spec
up to 1.12, new SONAME
[packages/libplist.git] / libplist.spec
1 # TODO
2 # - python3 package
3 #
4 # Conditional build:
5 %bcond_without  cython          # build with Cython
6 %bcond_without  static_libs     # static libraries
7
8 Summary:        Library for manipulating Apple Property Lists
9 Summary(pl.UTF-8):      Biblioteka do manipulowania Apple Property Lists
10 Name:           libplist
11 Version:        1.12
12 Release:        1
13 License:        LGPL v2.1+
14 Group:          Libraries
15 # Source0Download: http://www.libimobiledevice.org/
16 Source0:        http://www.libimobiledevice.org/downloads/%{name}-%{version}.tar.bz2
17 # Source0-md5:  8b04b0f09f2398022dcd4fba75012997
18 Patch0:         %{name}-link.patch
19 URL:            http://www.libimobiledevice.org/
20 BuildRequires:  autoconf >= 2.61
21 BuildRequires:  automake
22 BuildRequires:  libstdc++-devel
23 BuildRequires:  libtool
24 BuildRequires:  libxml2-devel >= 1:2.7.8
25 BuildRequires:  pkgconfig
26 BuildRequires:  rpmbuild(macros) >= 1.600
27 %if %{with cython}
28 BuildRequires:  python-Cython >= 0.17.0
29 BuildRequires:  python-devel >= 1:2.3
30 BuildRequires:  python-modules >= 1:2.3
31 BuildRequires:  rpm-pythonprov
32 %endif
33 Requires:       libxml2 >= 1:2.7.8
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 %description
37 Library for manipulating Apple Property Lists in binary and XML
38 format.
39
40 %description -l pl.UTF-8
41 Biblioteka do manipulowania Apple Property Lists w formacie binarnym i
42 XML.
43
44 %package devel
45 Summary:        Header file for libplist library
46 Summary(pl.UTF-8):      Plik nagłówkowy biblioteki libplist
47 Group:          Development/Libraries
48 Requires:       %{name} = %{version}-%{release}
49 Requires:       libxml2-devel >= 1:2.7.8
50
51 %description devel
52 Header file for libplist library.
53
54 %description devel -l pl.UTF-8
55 Plik nagłówkowy biblioteki libplist.
56
57 %package static
58 Summary:        Static libplist library
59 Summary(pl.UTF-8):      Statyczna biblioteka libplist
60 Group:          Development/Libraries
61 Requires:       %{name}-devel = %{version}-%{release}
62
63 %description static
64 Static libplist library.
65
66 %description static -l pl.UTF-8
67 Statyczna biblioteka libplist.
68
69 %package c++
70 Summary:        C++ binding for libplist library
71 Summary(pl.UTF-8):      Wiązanie C++ do biblioteki libplist
72 Group:          Libraries
73 Requires:       %{name} = %{version}-%{release}
74
75 %description c++
76 C++ binding for libplist library.
77
78 %description c++ -l pl.UTF-8
79 Wiązanie C++ do biblioteki libplist.
80
81 %package c++-devel
82 Summary:        Header files for libplist++ library
83 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki libplist++
84 Group:          Development/Libraries
85 Requires:       %{name}-c++ = %{version}-%{release}
86 Requires:       %{name}-devel = %{version}-%{release}
87 Requires:       libstdc++-devel
88
89 %description c++-devel
90 Header files for libplist++ library.
91
92 %description c++-devel -l pl.UTF-8
93 Pliki nagłówkowe biblioteki libplist++.
94
95 %package c++-static
96 Summary:        Static libplist++ library
97 Summary(pl.UTF-8):      Statyczna biblioteka libplist++
98 Group:          Development/Libraries
99 Requires:       %{name}-c++-devel = %{version}-%{release}
100
101 %description c++-static
102 Static libplist++ library.
103
104 %description c++-static -l pl.UTF-8
105 Statyczna biblioteka libplist++.
106
107 %package -n python-plist
108 Summary:        libplist Python bindings
109 Summary(pl.UTF-8):      Wiązania libplist dla Pythona
110 Group:          Development/Languages/Python
111 Requires:       %{name} = %{version}-%{release}
112
113 %description -n python-plist
114 libplist Python bindings.
115
116 %description -n python-plist -l pl.UTF-8
117 Wiązania libplist dla Pythona.
118
119 %package -n python-plist-devel
120 Summary:        Cython header file for Python libplist binding
121 Summary(pl.UTF-8):      Plik nagłówkowy Cythona dla wiązania Pythona do biblioteki libplist
122 Group:          Development/Libraries
123 Requires:       %{name}-devel = %{version}-%{release}
124 Requires:       python-Cython >= 0.17.0
125 Requires:       python-plist = %{version}-%{release}
126
127 %description -n python-plist-devel
128 Cython header file for Python libplist binding.
129
130 %description -n python-plist-devel -l pl.UTF-8
131 Plik nagłówkowy Cythona dla wiązania Pythona do biblioteki libplist.
132
133 %prep
134 %setup -q
135 %patch0 -p1
136
137 touch cython/*.py[xh]
138
139 %build
140 %{__libtoolize}
141 %{__aclocal} -I m4
142 %{__autoconf}
143 %{__autoheader}
144 %{__automake}
145 %configure \
146         --disable-silent-rules \
147         %{!?with_static_libs:--disable-static} \
148         %{!?with_cython:--without-cython}
149
150 # make -j1 due:
151 # make[2]: *** No rule to make target '../src/libplist.la', needed by 'libplist++.la'.  Stop.
152 %{__make} -j1
153
154 %install
155 rm -rf $RPM_BUILD_ROOT
156 %{__make} install \
157         DESTDIR=$RPM_BUILD_ROOT
158
159 # obsoleted by .pc
160 %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la
161
162 %if %{with cython}
163 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
164 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
165 %py_postclean
166
167 install -d $RPM_BUILD_ROOT%{_includedir}/plist/cython
168 cp -p cython/plist.pxd $RPM_BUILD_ROOT%{_includedir}/plist/cython/plist.pxd
169 %{__rm} $RPM_BUILD_ROOT%{py_sitedir}/plist.la \
170         %{?with_static_libs:$RPM_BUILD_ROOT%{py_sitedir}/plist.a}
171 %endif
172
173 %clean
174 rm -rf $RPM_BUILD_ROOT
175
176 %post   -p /sbin/ldconfig
177 %postun -p /sbin/ldconfig
178
179 %post   c++ -p /sbin/ldconfig
180 %postun c++ -p /sbin/ldconfig
181
182 %files
183 %defattr(644,root,root,755)
184 %doc AUTHORS NEWS README
185 %attr(755,root,root) %{_bindir}/plistutil
186 %attr(755,root,root) %{_libdir}/libplist.so.*.*.*
187 %attr(755,root,root) %ghost %{_libdir}/libplist.so.3
188
189 %files devel
190 %defattr(644,root,root,755)
191 %attr(755,root,root) %{_libdir}/libplist.so
192 %dir %{_includedir}/plist
193 %{_includedir}/plist/plist.h
194 %{_pkgconfigdir}/libplist.pc
195
196 %if %{with static_libs}
197 %files static
198 %defattr(644,root,root,755)
199 %{_libdir}/libplist.a
200 %endif
201
202 %files c++
203 %defattr(644,root,root,755)
204 %attr(755,root,root) %{_libdir}/libplist++.so.*.*.*
205 %attr(755,root,root) %ghost %{_libdir}/libplist++.so.3
206
207 %files c++-devel
208 %defattr(644,root,root,755)
209 %attr(755,root,root) %{_libdir}/libplist++.so
210 %{_includedir}/plist/Array.h
211 %{_includedir}/plist/Boolean.h
212 %{_includedir}/plist/Data.h
213 %{_includedir}/plist/Date.h
214 %{_includedir}/plist/Dictionary.h
215 %{_includedir}/plist/Integer.h
216 %{_includedir}/plist/Key.h
217 %{_includedir}/plist/Node.h
218 %{_includedir}/plist/Real.h
219 %{_includedir}/plist/String.h
220 %{_includedir}/plist/Structure.h
221 %{_includedir}/plist/Uid.h
222 %{_includedir}/plist/plist++.h
223 %{_pkgconfigdir}/libplist++.pc
224
225 %if %{with static_libs}
226 %files c++-static
227 %defattr(644,root,root,755)
228 %{_libdir}/libplist++.a
229 %endif
230
231 %if %{with cython}
232 %files -n python-plist
233 %defattr(644,root,root,755)
234 %attr(755,root,root) %{py_sitedir}/plist.so
235
236 %files -n python-plist-devel
237 %defattr(644,root,root,755)
238 %{_includedir}/plist/cython
239 %endif
This page took 0.147374 seconds and 3 git commands to generate.