Hello community, here is the log from the commit of package tor for openSUSE:Factory checked in at 2013-06-05 13:20:46 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/tor (Old) and /work/SRC/openSUSE:Factory/.tor.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "tor" Changes: -------- --- /work/SRC/openSUSE:Factory/tor/tor.changes 2012-11-28 17:04:59.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.tor.new/tor.changes 2013-06-05 13:20:47.000000000 +0200 @@ -1,0 +2,6 @@ +Fri May 24 22:51:24 UTC 2013 - [email protected] + +- add systemd support +- verify source tarball signature + +------------------------------------------------------------------- New: ---- tor-0.2.3.25.tar.gz.asc tor.keyring tor.service tor.tmpfiles ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ tor.spec ++++++ --- /var/tmp/diff_new_pack.Dh1Goj/_old 2013-06-05 13:20:48.000000000 +0200 +++ /var/tmp/diff_new_pack.Dh1Goj/_new 2013-06-05 13:20:48.000000000 +0200 @@ -1,7 +1,7 @@ # # spec file for package tor # -# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -26,12 +26,18 @@ License: BSD-3-Clause Group: Productivity/Networking/Security Url: https://www.torproject.org/ -Source: https://www.torproject.org/dist/%{name}-%{version}.tar.gz +Source0: https://www.torproject.org/dist/%{name}-%{version}.tar.gz +Source1: https://www.torproject.org/dist/%{name}-%{version}.tar.gz.asc +# https://www.torproject.org/docs/signing-keys.html.en +Source2: tor.keyring +Source3: tor.service +Source4: tor.tmpfiles # PATCH-FIX-UPSTREAM tor-0.2.2.37-logrotate.patch -- add su to logrotate config to fix W: suse-logrotate-user-writable-log-dir Patch0: tor-0.2.2.37-logrotate.patch Requires: logrotate BuildRequires: openssl-devel - +BuildRequires: pwdutils +# %if %with_bufferevents BuildRequires: libevent-devel >= 2.0.13 %else @@ -42,6 +48,16 @@ %endif %endif +%if 0%{?suse_version} >= 1230 +BuildRequires: gpg-offline +%endif + +%if 0%{?suse_version} > 1140 +BuildRequires: pkgconfig(systemd) +%{?systemd_requires} +%define has_systemd 1 +%endif + %define toruser %{name} %define torgroup %{name} %define home_dir /var/lib/empty @@ -70,6 +86,7 @@ for high-stakes anonymity. %prep +%{?gpg_verify: %gpg_verify %{S:1}} %setup -q %patch0 @@ -97,6 +114,12 @@ %{buildroot}/var/log/%{name} \ %{buildroot}/%{_sbindir} +%if 0%{?has_systemd} +install -m 644 -D %{S:3} $RPM_BUILD_ROOT/%{_unitdir}/%{name}.service +%{__install} -d -m 0755 %{buildroot}/usr/lib/tmpfiles.d/ +%{__install} -m 0644 %{S:4} %{buildroot}/usr/lib/tmpfiles.d/%{name}.conf +%endif + # control script %__install -p -m 755 contrib/torctl %{buildroot}/%{_bindir} @@ -115,18 +138,31 @@ %__rm -rf "%{buildroot}" %pre -/usr/sbin/groupadd -r %{torgroup} &>/dev/null || : -/usr/sbin/useradd -g %{torgroup} -s /bin/false -r -c "User to run %{name}" -d %{home_dir} %{toruser} &>/dev/null || : +getent group %{torgroup} >/dev/null || groupadd -r %{torgroup} +getent passwd %{toruser} >/dev/null || useradd -r -g %{torgroup} -d %{home_dir} -s /sbin/false -c "User to ru %{name}" %{toruser} +%if 0%{?has_systemd} +%service_add_pre tor.service +%endif %post %fillup_and_insserv tor +%if 0%{?has_systemd} +%service_add_post tor.service +systemd-tmpfiles --create /usr/lib/tmpfiles.d/tor.conf +%endif %preun %stop_on_removal tor +%if 0%{?has_systemd} +%service_del_preun tor.service +%endif %postun -%insserv_cleanup %restart_on_update tor +%insserv_cleanup +%if 0%{?has_systemd} +%service_del_postun tor.service +%endif %files %defattr(-,root,root) @@ -147,5 +183,9 @@ %attr(0700,%{toruser},%{torgroup}) %dir %{_localstatedir}/lib/%{name} %ghost %attr(0750,%{toruser},%{torgroup}) %dir %{_localstatedir}/run/%{name} %attr(0750,%{toruser},%{torgroup}) %dir %{_localstatedir}/log/%{name} +%if 0%{?has_systemd} +%{_unitdir}/%{name}.service +/usr/lib/tmpfiles.d/%{name}.conf +%endif %changelog ++++++ tor.keyring ++++++ ++++ 3019 lines (skipped) ++++++ tor.service ++++++ [Unit] Description = Anonymizing overlay network for TCP After = syslog.target network.target nss-lookup.target [Service] Type=forking ExecStart=/usr/bin/torctl start ExecReload=/usr/bin/torctl reload ExecStop=/usr/bin/torctl stop TimeoutSec=30 Restart=on-failure LimitNOFILE=32768 [Install] WantedBy=multi-user.target ++++++ tor.tmpfiles ++++++ D /var/run/tor 0755 tor tor - -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
