]>
Commit | Line | Data |
---|---|---|
9847b4be JB |
1 | # TODO: |
2 | # - natus-based pacrunner (doesn't build with natus 0.2.1) | |
3 | # - ruby binding (not finished as of 0.4.8 - no buildsystem) | |
705e407b JB |
4 | # |
5 | # Conditional build: | |
9847b4be JB |
6 | %bcond_without kde # KDE4 config plugin |
7 | %bcond_without mozjs # MozJS pacrunner plugin | |
8 | %bcond_with natus # Natus pacrunner plugin [doesn't build with natus 0.2.1] | |
9 | %bcond_without webkit # WebKit pacrunner plugin | |
705e407b | 10 | # |
128597ac JB |
11 | %include /usr/lib/rpm/macros.perl |
12 | %include /usr/lib/rpm/macros.mono | |
86d2d1bd MB |
13 | Summary: Library for automatic proxy configuration management |
14 | Summary(pl.UTF-8): Biblioteka do automatycznego zarządzania konfiguracją proxy | |
15 | Name: libproxy | |
fed0b708 | 16 | Version: 0.4.11 |
9847b4be | 17 | Release: 1 |
128597ac | 18 | License: LGPL v2.1+ |
86d2d1bd | 19 | Group: Libraries |
705e407b | 20 | #Source0Download: http://code.google.com/p/libproxy/downloads/list |
86d2d1bd | 21 | Source0: http://libproxy.googlecode.com/files/%{name}-%{version}.tar.gz |
fed0b708 | 22 | # Source0-md5: 3cd1ae2a4abecf44b3f24d6639d2cd84 |
128597ac | 23 | Patch0: %{name}-pac-modules.patch |
9847b4be | 24 | Patch1: %{name}-mozjs.patch |
86d2d1bd | 25 | URL: http://code.google.com/p/libproxy/ |
86d2d1bd | 26 | BuildRequires: NetworkManager-devel |
36f95bc8 | 27 | %{?with_kde:BuildRequires: automoc4} |
128597ac | 28 | BuildRequires: cmake >= 2.6 |
f39b9aec | 29 | BuildRequires: glib2-devel >= 1:2.26 |
9847b4be JB |
30 | %{?with_webkit:BuildRequires: gtk-webkit3-devel >= 1.5.0} |
31 | %{?with_mozjs:BuildRequires: js185-devel} | |
128597ac | 32 | %{?with_kde:BuildRequires: kde4-kdelibs-devel} |
f39b9aec | 33 | BuildRequires: libmodman-devel >= 2 |
128597ac JB |
34 | BuildRequires: libstdc++-devel |
35 | BuildRequires: mono-csharp | |
36 | BuildRequires: perl-devel >= 1:5.8.0 | |
86d2d1bd MB |
37 | BuildRequires: pkgconfig |
38 | BuildRequires: python-devel >= 1:2.5 | |
24445d20 | 39 | BuildRequires: python-modules |
36f95bc8 SS |
40 | %if %{with kde} |
41 | BuildRequires: qt4-build | |
42 | BuildRequires: qt4-qmake | |
43 | %endif | |
128597ac | 44 | BuildRequires: rpm-perlprov >= 4.1-13 |
24445d20 | 45 | BuildRequires: rpm-pythonprov |
128597ac JB |
46 | BuildRequires: rpmbuild(macros) >= 1.268 |
47 | BuildRequires: rpmbuild(monoautodeps) | |
9847b4be | 48 | BuildRequires: sed >= 4.0 |
7333df52 | 49 | BuildRequires: xorg-lib-libX11-devel |
86d2d1bd | 50 | BuildRequires: xorg-lib-libXmu-devel |
86d2d1bd MB |
51 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
52 | ||
53 | %description | |
54 | Library for automatic proxy configuration management. | |
55 | ||
56 | %description -l pl.UTF-8 | |
57 | Biblioteka do automatycznego zarządzania konfiguracją proxy. | |
58 | ||
59 | %package devel | |
60 | Summary: Header files for libproxy library | |
61 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libproxy | |
62 | Group: Development/Libraries | |
63 | Requires: %{name} = %{version}-%{release} | |
128597ac JB |
64 | Requires: libstdc++-devel |
65 | Obsoletes: libproxy-static | |
86d2d1bd MB |
66 | |
67 | %description devel | |
68 | Header files for libproxy library. | |
69 | ||
70 | %description devel -l pl.UTF-8 | |
71 | Pliki nagłówkowe biblioteki libproxy. | |
72 | ||
128597ac JB |
73 | %package -n dotnet-libproxy-sharp |
74 | Summary: Libproxy# - libproxy .NET bindings | |
75 | Summary(pl.UTF-8): Libproxy# - wiązania libproxy dla .NET | |
76 | Group: Libraries | |
77 | Requires: %{name} = %{version}-%{release} | |
78 | ||
79 | %description -n dotnet-libproxy-sharp | |
80 | Libproxy# - libproxy .NET bindings. | |
81 | ||
82 | %description -n dotnet-libproxy-sharp -l pl.UTF-8 | |
83 | Libproxy# - wiązania libproxy dla .NET. | |
84 | ||
85 | %package -n dotnet-libproxy-sharp-devel | |
86 | Summary: libproxy .NET bindings - development files | |
87 | Summary(pl.UTF-8): Wiązania libproxy dla .NET - pliki programistyczne | |
86d2d1bd | 88 | Group: Development/Libraries |
128597ac | 89 | Requires: dotnet-libproxy-sharp = %{version}-%{release} |
86d2d1bd | 90 | |
128597ac JB |
91 | %description -n dotnet-libproxy-sharp-devel |
92 | Development files for libproxy .NET bindings. | |
86d2d1bd | 93 | |
128597ac JB |
94 | %description -n dotnet-libproxy-sharp-devel -l pl.UTF-8 |
95 | Pliki programistyczne wiązań libproxy dla .NET. | |
96 | ||
97 | %package -n perl-Net-Libproxy | |
98 | Summary: libproxy Perl bindings | |
99 | Summary(pl.UTF-8): Wiązania libproxy dla Perla | |
100 | Group: Development/Languages/Perl | |
101 | Requires: %{name} = %{version}-%{release} | |
102 | ||
103 | %description -n perl-Net-Libproxy | |
104 | libproxy Perl bindings. | |
105 | ||
106 | %description -n perl-Net-Libproxy -l pl.UTF-8 | |
107 | Wiązania libproxy dla Perla. | |
86d2d1bd MB |
108 | |
109 | %package -n python-libproxy | |
110 | Summary: libproxy Python bindings | |
111 | Summary(pl.UTF-8): Wiązania libproxy dla Pythona | |
112 | Group: Libraries/Python | |
113 | # uses libproxy shared library | |
114 | Requires: %{name} = %{version}-%{release} | |
115 | ||
116 | %description -n python-libproxy | |
117 | libproxy Python bindings. | |
118 | ||
119 | %description -n python-libproxy -l pl.UTF-8 | |
120 | Wiązania libproxy dla Pythona. | |
121 | ||
128597ac JB |
122 | %package -n vala-libproxy |
123 | Summary: Vala bindings for libproxy API | |
124 | Summary(pl.UTF-8): Wiązania API libproxy dla języka Vala | |
125 | Group: Development/Languages | |
126 | Requires: %{name}-devel = %{version}-%{release} | |
127 | ||
128 | %description -n vala-libproxy | |
129 | Vala bindings for libproxy API. | |
130 | ||
131 | %description -n vala-libproxy -l pl.UTF-8 | |
132 | Wiązania API libproxy dla języka Vala. | |
133 | ||
705e407b JB |
134 | %package networkmanager |
135 | Summary: NetworkManager plugin for libproxy | |
136 | Summary(pl.UTF-8): Wtyczka NetworkManager dla libproxy | |
137 | Group: Libraries | |
138 | Requires: %{name} = %{version}-%{release} | |
139 | ||
140 | %description networkmanager | |
141 | NetworkManager configuration plugin for libproxy. | |
142 | ||
143 | %description networkmanager -l pl.UTF-8 | |
144 | Wtyczka konfiguracji NetworkManager dla libproxy. | |
145 | ||
d264af18 | 146 | %package gnome |
7333df52 JB |
147 | Summary: GNOME plugin for libproxy |
148 | Summary(pl.UTF-8): Wtyczka GNOME dla libproxy | |
d264af18 KK |
149 | Group: Libraries |
150 | Requires: %{name} = %{version}-%{release} | |
f39b9aec | 151 | Requires: glib2 >= 1:2.26 |
d264af18 KK |
152 | |
153 | %description gnome | |
7333df52 | 154 | GNOME (GConf) configuration plugin for libproxy. |
d264af18 | 155 | |
7333df52 JB |
156 | %description gnome -l pl.UTF-8 |
157 | Wtyczka konfiguracji GNOME (GConf) dla libproxy. | |
d264af18 KK |
158 | |
159 | %package kde | |
7333df52 JB |
160 | Summary: KDE plugin for libproxy |
161 | Summary(pl.UTF-8): Wtyczka KDE dla libproxy | |
d264af18 KK |
162 | Group: Libraries |
163 | Requires: %{name} = %{version}-%{release} | |
164 | ||
165 | %description kde | |
7333df52 | 166 | KDE configuration plugin for libproxy. |
d264af18 | 167 | |
7333df52 JB |
168 | %description kde -l pl.UTF-8 |
169 | Wtyczka konfiguracji KDE dla libproxy | |
d264af18 KK |
170 | |
171 | %package mozjs | |
7333df52 JB |
172 | Summary: MozJS plugin for libproxy |
173 | Summary(pl.UTF-8): Wtyczka MozJS dla libproxy | |
d264af18 | 174 | Group: Libraries |
7333df52 | 175 | Requires: %{name} = %{version}-%{release} |
d264af18 KK |
176 | |
177 | %description mozjs | |
7333df52 | 178 | MozJS (XULrunner/JavaScript) configuration plugin for libproxy. |
d264af18 | 179 | |
7333df52 JB |
180 | %description mozjs -l pl.UTF-8 |
181 | Wtyczka konfiguracji MozJS (XULrunner/JavaScript) dla libproxy. | |
d264af18 KK |
182 | |
183 | %package webkit | |
7333df52 JB |
184 | Summary: WebKit plugin for libproxy |
185 | Summary(pl.UTF-8): Wtyczka WebKit dla libproxy | |
d264af18 | 186 | Group: Libraries |
7333df52 | 187 | Requires: %{name} = %{version}-%{release} |
9847b4be | 188 | Requires: gtk-webkit3 >= 1.5.0 |
d264af18 KK |
189 | |
190 | %description webkit | |
7333df52 | 191 | WebKit (JavaScriptCore) configuration plugin for libproxy. |
d264af18 | 192 | |
7333df52 JB |
193 | %description webkit -l pl.UTF-8 |
194 | Wtyczka konfigracji WebKit (JavaScriptCore) dla libproxy. | |
d264af18 | 195 | |
86d2d1bd MB |
196 | %prep |
197 | %setup -q | |
198 | %patch0 -p1 | |
9847b4be JB |
199 | %patch1 -p1 |
200 | ||
201 | %if %{without natus} | |
202 | echo 'set(NATUS_FOUND 0)' > libproxy/cmake/modules/pacrunner_natus.cmk | |
203 | %endif | |
86d2d1bd MB |
204 | |
205 | %build | |
128597ac JB |
206 | install -d build |
207 | cd build | |
208 | %cmake .. \ | |
128597ac JB |
209 | -DLIB_INSTALL_DIR=%{_libdir} \ |
210 | -DLIBEXEC_INSTALL_DIR=%{_libdir}/libproxy \ | |
f39b9aec | 211 | -DFORCE_SYSTEM_LIBMODMAN=ON \ |
128597ac JB |
212 | -DPERL_VENDORINSTALL=ON \ |
213 | -DWITH_DOTNET=ON \ | |
9847b4be | 214 | %{!?with_mozjs:-DWITH_MOZJS=OFF} \ |
128597ac | 215 | -DWITH_VALA=ON \ |
f39b9aec JB |
216 | %{!?with_webkit:-DWITH_WEBKIT=OFF} \ |
217 | %{?with_webkit:-DWITH_WEBKIT3=ON} | |
128597ac | 218 | |
86d2d1bd MB |
219 | %{__make} |
220 | ||
221 | %install | |
222 | rm -rf $RPM_BUILD_ROOT | |
223 | ||
128597ac | 224 | %{__make} -C build install \ |
86d2d1bd MB |
225 | DESTDIR=$RPM_BUILD_ROOT |
226 | ||
227 | %py_comp $RPM_BUILD_ROOT%{py_sitescriptdir} | |
228 | %py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir} | |
229 | %py_postclean | |
230 | ||
231 | %clean | |
232 | rm -rf $RPM_BUILD_ROOT | |
233 | ||
234 | %post -p /sbin/ldconfig | |
235 | %postun -p /sbin/ldconfig | |
236 | ||
237 | %files | |
238 | %defattr(644,root,root,755) | |
128597ac | 239 | %doc AUTHORS ChangeLog NEWS README |
86d2d1bd MB |
240 | %attr(755,root,root) %{_bindir}/proxy |
241 | %attr(755,root,root) %{_libdir}/libproxy.so.*.*.* | |
128597ac | 242 | %attr(755,root,root) %ghost %{_libdir}/libproxy.so.1 |
86d2d1bd MB |
243 | %dir %{_libdir}/%{name} |
244 | %dir %{_libdir}/%{name}/%{version} | |
128597ac | 245 | %dir %{_libdir}/%{name}/%{version}/modules |
86d2d1bd MB |
246 | |
247 | %files devel | |
248 | %defattr(644,root,root,755) | |
249 | %attr(755,root,root) %{_libdir}/libproxy.so | |
705e407b | 250 | %{_includedir}/proxy.h |
86d2d1bd | 251 | %{_pkgconfigdir}/libproxy-1.0.pc |
128597ac JB |
252 | %{_datadir}/cmake/Modules/Findlibproxy.cmake |
253 | ||
254 | %files -n dotnet-libproxy-sharp | |
255 | %defattr(644,root,root,755) | |
256 | %{_prefix}/lib/mono/gac/libproxy-sharp | |
86d2d1bd | 257 | |
128597ac | 258 | %files -n dotnet-libproxy-sharp-devel |
86d2d1bd | 259 | %defattr(644,root,root,755) |
128597ac JB |
260 | %{_prefix}/lib/mono/libproxy-sharp |
261 | %{_pkgconfigdir}/libproxy-sharp-1.0.pc | |
262 | ||
263 | %files -n perl-Net-Libproxy | |
264 | %defattr(644,root,root,755) | |
265 | %{perl_vendorarch}/Net/Libproxy.pm | |
266 | %dir %{perl_vendorarch}/auto/Net/Libproxy | |
267 | %attr(755,root,root) %{perl_vendorarch}/auto/Net/Libproxy/Libproxy.so | |
86d2d1bd MB |
268 | |
269 | %files -n python-libproxy | |
270 | %defattr(644,root,root,755) | |
705e407b JB |
271 | %{py_sitescriptdir}/libproxy.py[co] |
272 | ||
128597ac JB |
273 | %files -n vala-libproxy |
274 | %defattr(644,root,root,755) | |
275 | %{_datadir}/vala/vapi/libproxy-1.0.vapi | |
276 | ||
705e407b JB |
277 | %files networkmanager |
278 | %defattr(644,root,root,755) | |
128597ac | 279 | %attr(755,root,root) %{_libdir}/%{name}/%{version}/modules/network_networkmanager.so |
d264af18 KK |
280 | |
281 | %files gnome | |
24445d20 | 282 | %defattr(644,root,root,755) |
f39b9aec | 283 | %attr(755,root,root) %{_libdir}/%{name}/%{version}/modules/config_gnome3.so |
f7a0d1cc | 284 | %attr(755,root,root) %{_libdir}/%{name}/pxgsettings |
d264af18 | 285 | |
128597ac | 286 | %if %{with kde} |
d264af18 | 287 | %files kde |
24445d20 | 288 | %defattr(644,root,root,755) |
128597ac JB |
289 | %attr(755,root,root) %{_libdir}/%{name}/%{version}/modules/config_kde4.so |
290 | %endif | |
d264af18 | 291 | |
9847b4be | 292 | %if %{with mozjs} |
d264af18 | 293 | %files mozjs |
24445d20 | 294 | %defattr(644,root,root,755) |
128597ac | 295 | %attr(755,root,root) %{_libdir}/%{name}/%{version}/modules/pacrunner_mozjs.so |
aa7b5c69 | 296 | %endif |
d264af18 | 297 | |
705e407b | 298 | %if %{with webkit} |
d264af18 | 299 | %files webkit |
24445d20 | 300 | %defattr(644,root,root,755) |
128597ac | 301 | %attr(755,root,root) %{_libdir}/%{name}/%{version}/modules/pacrunner_webkit.so |
705e407b | 302 | %endif |