]>
Commit | Line | Data |
---|---|---|
489bd56d | 1 | # TODO |
4bc15581 | 2 | # - python3 package |
486cfdf5 ER |
3 | # |
4 | # Conditional build: | |
a4a4e4b0 JB |
5 | %bcond_without cython # build with Cython |
6 | %bcond_without static_libs # static libraries | |
486cfdf5 | 7 | |
7980613e MB |
8 | Summary: Library for manipulating Apple Property Lists |
9 | Summary(pl.UTF-8): Biblioteka do manipulowania Apple Property Lists | |
10 | Name: libplist | |
9517982e ER |
11 | Version: 1.12 |
12 | Release: 1 | |
46e8b3f9 | 13 | License: LGPL v2.1+ |
7980613e | 14 | Group: Libraries |
489bd56d | 15 | # Source0Download: http://www.libimobiledevice.org/ |
a0267948 | 16 | Source0: http://www.libimobiledevice.org/downloads/%{name}-%{version}.tar.bz2 |
9517982e | 17 | # Source0-md5: 8b04b0f09f2398022dcd4fba75012997 |
a4a4e4b0 | 18 | Patch0: %{name}-link.patch |
4987ce66 | 19 | URL: http://www.libimobiledevice.org/ |
a4a4e4b0 JB |
20 | BuildRequires: autoconf >= 2.61 |
21 | BuildRequires: automake | |
af989959 | 22 | BuildRequires: libstdc++-devel |
a4a4e4b0 JB |
23 | BuildRequires: libtool |
24 | BuildRequires: libxml2-devel >= 1:2.7.8 | |
7980613e | 25 | BuildRequires: pkgconfig |
a4a4e4b0 | 26 | BuildRequires: rpmbuild(macros) >= 1.600 |
4bc15581 | 27 | %if %{with cython} |
a4a4e4b0 JB |
28 | BuildRequires: python-Cython >= 0.17.0 |
29 | BuildRequires: python-devel >= 1:2.3 | |
30 | BuildRequires: python-modules >= 1:2.3 | |
af989959 | 31 | BuildRequires: rpm-pythonprov |
4bc15581 | 32 | %endif |
a4a4e4b0 | 33 | Requires: libxml2 >= 1:2.7.8 |
7980613e MB |
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 | |
46e8b3f9 JB |
45 | Summary: Header file for libplist library |
46 | Summary(pl.UTF-8): Plik nagłówkowy biblioteki libplist | |
7980613e MB |
47 | Group: Development/Libraries |
48 | Requires: %{name} = %{version}-%{release} | |
a4a4e4b0 | 49 | Requires: libxml2-devel >= 1:2.7.8 |
7980613e MB |
50 | |
51 | %description devel | |
46e8b3f9 | 52 | Header file for libplist library. |
7980613e MB |
53 | |
54 | %description devel -l pl.UTF-8 | |
46e8b3f9 | 55 | Plik nagłówkowy biblioteki libplist. |
7980613e | 56 | |
a4a4e4b0 JB |
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 | ||
46e8b3f9 JB |
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 | ||
7980613e MB |
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 | |
8d2cbeb9 | 111 | Requires: %{name} = %{version}-%{release} |
7980613e MB |
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 | ||
46e8b3f9 JB |
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 | ||
7980613e MB |
133 | %prep |
134 | %setup -q | |
a4a4e4b0 | 135 | %patch0 -p1 |
7980613e | 136 | |
489bd56d ER |
137 | touch cython/*.py[xh] |
138 | ||
7980613e | 139 | %build |
a4a4e4b0 JB |
140 | %{__libtoolize} |
141 | %{__aclocal} -I m4 | |
142 | %{__autoconf} | |
143 | %{__autoheader} | |
144 | %{__automake} | |
4bc15581 | 145 | %configure \ |
4bc15581 | 146 | --disable-silent-rules \ |
a4a4e4b0 | 147 | %{!?with_static_libs:--disable-static} \ |
4bc15581 | 148 | %{!?with_cython:--without-cython} |
a4a4e4b0 | 149 | |
4bc15581 ER |
150 | # make -j1 due: |
151 | # make[2]: *** No rule to make target '../src/libplist.la', needed by 'libplist++.la'. Stop. | |
152 | %{__make} -j1 | |
7980613e MB |
153 | |
154 | %install | |
155 | rm -rf $RPM_BUILD_ROOT | |
4bc15581 | 156 | %{__make} install \ |
7980613e MB |
157 | DESTDIR=$RPM_BUILD_ROOT |
158 | ||
4bc15581 ER |
159 | # obsoleted by .pc |
160 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la | |
161 | ||
a4a4e4b0 | 162 | %if %{with cython} |
7980613e MB |
163 | %py_comp $RPM_BUILD_ROOT%{py_sitedir} |
164 | %py_ocomp $RPM_BUILD_ROOT%{py_sitedir} | |
165 | %py_postclean | |
166 | ||
0d502360 ER |
167 | install -d $RPM_BUILD_ROOT%{_includedir}/plist/cython |
168 | cp -p cython/plist.pxd $RPM_BUILD_ROOT%{_includedir}/plist/cython/plist.pxd | |
a4a4e4b0 JB |
169 | %{__rm} $RPM_BUILD_ROOT%{py_sitedir}/plist.la \ |
170 | %{?with_static_libs:$RPM_BUILD_ROOT%{py_sitedir}/plist.a} | |
486cfdf5 ER |
171 | %endif |
172 | ||
7980613e MB |
173 | %clean |
174 | rm -rf $RPM_BUILD_ROOT | |
175 | ||
176 | %post -p /sbin/ldconfig | |
177 | %postun -p /sbin/ldconfig | |
178 | ||
46e8b3f9 JB |
179 | %post c++ -p /sbin/ldconfig |
180 | %postun c++ -p /sbin/ldconfig | |
181 | ||
7980613e MB |
182 | %files |
183 | %defattr(644,root,root,755) | |
8d2cbeb9 | 184 | %doc AUTHORS NEWS README |
4bc15581 | 185 | %attr(755,root,root) %{_bindir}/plistutil |
7980613e | 186 | %attr(755,root,root) %{_libdir}/libplist.so.*.*.* |
9517982e | 187 | %attr(755,root,root) %ghost %{_libdir}/libplist.so.3 |
7980613e MB |
188 | |
189 | %files devel | |
190 | %defattr(644,root,root,755) | |
7980613e | 191 | %attr(755,root,root) %{_libdir}/libplist.so |
46e8b3f9 JB |
192 | %dir %{_includedir}/plist |
193 | %{_includedir}/plist/plist.h | |
7980613e MB |
194 | %{_pkgconfigdir}/libplist.pc |
195 | ||
a4a4e4b0 JB |
196 | %if %{with static_libs} |
197 | %files static | |
198 | %defattr(644,root,root,755) | |
a4a4e4b0 JB |
199 | %{_libdir}/libplist.a |
200 | %endif | |
201 | ||
46e8b3f9 JB |
202 | %files c++ |
203 | %defattr(644,root,root,755) | |
204 | %attr(755,root,root) %{_libdir}/libplist++.so.*.*.* | |
9517982e | 205 | %attr(755,root,root) %ghost %{_libdir}/libplist++.so.3 |
46e8b3f9 JB |
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 | ||
4bc15581 | 231 | %if %{with cython} |
7980613e MB |
232 | %files -n python-plist |
233 | %defattr(644,root,root,755) | |
486cfdf5 | 234 | %attr(755,root,root) %{py_sitedir}/plist.so |
46e8b3f9 JB |
235 | |
236 | %files -n python-plist-devel | |
237 | %defattr(644,root,root,755) | |
238 | %{_includedir}/plist/cython | |
486cfdf5 | 239 | %endif |