forked from pool/strongswan
Accepting request 238850 from network:vpn
1 OBS-URL: https://build.opensuse.org/request/show/238850 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/strongswan?expand=0&rev=55
This commit is contained in:
commit
971dcd097b
@ -1,3 +1,12 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Jun 20 17:38:07 UTC 2014 - crrodriguez@opensuse.org
|
||||||
|
|
||||||
|
- Fix build in factory
|
||||||
|
* Do not include var/run directories in package
|
||||||
|
* Move runtime data to /run and provide tmpfiles.d snippet
|
||||||
|
* Add proper systemd macros to rpm scriptlets.
|
||||||
|
* Do not buildRequire library package libnl1, it is not used.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Apr 14 23:36:07 UTC 2014 - mt@suse.de
|
Mon Apr 14 23:36:07 UTC 2014 - mt@suse.de
|
||||||
|
|
||||||
|
@ -90,10 +90,11 @@ BuildRequires: libgcrypt-devel
|
|||||||
BuildRequires: NetworkManager-devel
|
BuildRequires: NetworkManager-devel
|
||||||
%endif
|
%endif
|
||||||
%if %{with systemd}
|
%if %{with systemd}
|
||||||
BuildRequires: systemd-devel
|
BuildRequires: pkgconfig(systemd)
|
||||||
%endif
|
%endif
|
||||||
BuildRequires: iptables
|
BuildRequires: iptables
|
||||||
BuildRequires: libnl >= 1.1
|
%{!?_rundir: %global _rundir /run}
|
||||||
|
%{!?_tmpfilesdir: %global _tmpfilesdir /usr/lib/tmpfiles.d}
|
||||||
|
|
||||||
%description
|
%description
|
||||||
StrongSwan is an OpenSource IPsec-based VPN Solution for Linux
|
StrongSwan is an OpenSource IPsec-based VPN Solution for Linux
|
||||||
@ -256,7 +257,8 @@ export RPM_OPT_FLAGS CFLAGS
|
|||||||
--enable-integrity-test \
|
--enable-integrity-test \
|
||||||
--with-capabilities=libcap \
|
--with-capabilities=libcap \
|
||||||
--with-plugindir=%{strongswan_plugins} \
|
--with-plugindir=%{strongswan_plugins} \
|
||||||
--with-resolv-conf=%{_localstatedir}/run/strongswan/resolv.conf \
|
--with-resolv-conf=%{_rundir}/%{name}/resolv.conf \
|
||||||
|
--with-piddir=%{_rundir}/%{name} \
|
||||||
--enable-pkcs11 \
|
--enable-pkcs11 \
|
||||||
--enable-openssl \
|
--enable-openssl \
|
||||||
--enable-agent \
|
--enable-agent \
|
||||||
@ -331,7 +333,8 @@ export RPM_OPT_FLAGS CFLAGS
|
|||||||
%endif
|
%endif
|
||||||
--enable-ldap \
|
--enable-ldap \
|
||||||
--enable-soup \
|
--enable-soup \
|
||||||
--enable-curl
|
--enable-curl \
|
||||||
|
--disable-static
|
||||||
make %{?_smp_mflags:%_smp_mflags}
|
make %{?_smp_mflags:%_smp_mflags}
|
||||||
|
|
||||||
%install
|
%install
|
||||||
@ -358,8 +361,7 @@ EOT
|
|||||||
#
|
#
|
||||||
rm -f $RPM_BUILD_ROOT%{strongswan_libdir}/lib{charon,hydra,strongswan,pttls}.so
|
rm -f $RPM_BUILD_ROOT%{strongswan_libdir}/lib{charon,hydra,strongswan,pttls}.so
|
||||||
rm -f $RPM_BUILD_ROOT%{strongswan_libdir}/lib{radius,simaka,tls,tnccs,imcv}.so
|
rm -f $RPM_BUILD_ROOT%{strongswan_libdir}/lib{radius,simaka,tls,tnccs,imcv}.so
|
||||||
find $RPM_BUILD_ROOT%{strongswan_libdir} \
|
find $RPM_BUILD_ROOT%{strongswan_libdir} -type f -name "*.la" -delete
|
||||||
-name "*.a" -o -name "*.la" | xargs -r rm -f
|
|
||||||
#
|
#
|
||||||
install -d -m755 ${RPM_BUILD_ROOT}%{strongswan_docdir}/
|
install -d -m755 ${RPM_BUILD_ROOT}%{strongswan_docdir}/
|
||||||
install -c -m644 TODO NEWS README COPYING LICENSE \
|
install -c -m644 TODO NEWS README COPYING LICENSE \
|
||||||
@ -367,20 +369,23 @@ install -c -m644 TODO NEWS README COPYING LICENSE \
|
|||||||
${RPM_BUILD_ROOT}%{strongswan_docdir}/
|
${RPM_BUILD_ROOT}%{strongswan_docdir}/
|
||||||
install -c -m644 ${RPM_SOURCE_DIR}/README.SUSE \
|
install -c -m644 ${RPM_SOURCE_DIR}/README.SUSE \
|
||||||
${RPM_BUILD_ROOT}%{strongswan_docdir}/
|
${RPM_BUILD_ROOT}%{strongswan_docdir}/
|
||||||
install -d -m755 $RPM_BUILD_ROOT%{_localstatedir}/run/strongswan
|
|
||||||
|
|
||||||
%post libs0
|
%{__install} -d -m 0755 %{buildroot}%{_tmpfilesdir}
|
||||||
%{run_ldconfig}
|
echo 'd %{_rundir}/%{name} 0770 root root' > %{buildroot}%{_tmpfilesdir}/%{name}.conf
|
||||||
test -d %{_localstatedir}/run/strongswan || \
|
|
||||||
%{__mkdir_p} %{_localstatedir}/run/strongswan
|
|
||||||
|
|
||||||
%postun libs0
|
%post libs0 -p /sbin/ldconfig
|
||||||
%{run_ldconfig}
|
|
||||||
|
%postun libs0 -p /sbin/ldconfig
|
||||||
|
|
||||||
|
%pre ipsec
|
||||||
|
%service_add_pre %{name}.service
|
||||||
|
|
||||||
%post ipsec
|
%post ipsec
|
||||||
%if ! %{with systemd}
|
%if ! %{with systemd}
|
||||||
%{fillup_and_insserv ipsec}
|
%{fillup_and_insserv ipsec}
|
||||||
%endif
|
%endif
|
||||||
|
%{?tmpfiles_create: %tmpfiles_create %{_tmpfilesdir}/%{name}.conf }
|
||||||
|
%service_add_post %{name}.service
|
||||||
|
|
||||||
%preun ipsec
|
%preun ipsec
|
||||||
%if ! %{with systemd}
|
%if ! %{with systemd}
|
||||||
@ -394,12 +399,15 @@ if test -s %{_sysconfdir}/ipsec.conf.rpmsave ; then
|
|||||||
cp -p --backup=numbered %{_sysconfdir}/ipsec.conf.rpmsave \
|
cp -p --backup=numbered %{_sysconfdir}/ipsec.conf.rpmsave \
|
||||||
%{_sysconfdir}/ipsec.conf.rpmsave.old
|
%{_sysconfdir}/ipsec.conf.rpmsave.old
|
||||||
fi
|
fi
|
||||||
|
%service_del_preun %{name}.service
|
||||||
|
|
||||||
%postun ipsec
|
%postun ipsec
|
||||||
%if ! %{with systemd}
|
%if ! %{with systemd}
|
||||||
%{insserv_cleanup}
|
%{insserv_cleanup}
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
%service_del_postun %{name}.service
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%dir %{strongswan_docdir}
|
%dir %{strongswan_docdir}
|
||||||
@ -448,6 +456,7 @@ fi
|
|||||||
%dir %{strongswan_plugins}
|
%dir %{strongswan_plugins}
|
||||||
%{strongswan_plugins}/libstrongswan-stroke.so
|
%{strongswan_plugins}/libstrongswan-stroke.so
|
||||||
%{strongswan_plugins}/libstrongswan-updown.so
|
%{strongswan_plugins}/libstrongswan-updown.so
|
||||||
|
%{_tmpfilesdir}/%{name}.conf
|
||||||
|
|
||||||
%files doc
|
%files doc
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
@ -662,7 +671,6 @@ fi
|
|||||||
%{strongswan_plugins}/libstrongswan-xauth-generic.so
|
%{strongswan_plugins}/libstrongswan-xauth-generic.so
|
||||||
%{strongswan_plugins}/libstrongswan-xauth-pam.so
|
%{strongswan_plugins}/libstrongswan-xauth-pam.so
|
||||||
%{strongswan_plugins}/libstrongswan-xcbc.so
|
%{strongswan_plugins}/libstrongswan-xcbc.so
|
||||||
%dir %ghost %{_localstatedir}/run/strongswan
|
|
||||||
%dir %{strongswan_datadir}
|
%dir %{strongswan_datadir}
|
||||||
%dir %{strongswan_templates}
|
%dir %{strongswan_templates}
|
||||||
%dir %{strongswan_templates}/config
|
%dir %{strongswan_templates}/config
|
||||||
|
Loading…
Reference in New Issue
Block a user