Date: Monday, February 11, 2013 @ 01:24:43 Author: heftig Revision: 84124
Arch-specific command fixes FS#33801 Added: openresolv/trunk/fs33801.patch Modified: openresolv/trunk/PKGBUILD ---------------+ PKGBUILD | 18 ++++++++---- fs33801.patch | 82 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 94 insertions(+), 6 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2013-02-11 00:01:58 UTC (rev 84123) +++ PKGBUILD 2013-02-11 00:24:43 UTC (rev 84124) @@ -4,20 +4,26 @@ pkgname=openresolv pkgver=3.5.4 -pkgrel=1 +pkgrel=2 pkgdesc="resolv.conf management framework (resolvconf)" arch=(any) url="http://roy.marples.name/projects/openresolv" license=('custom:BSD') backup=(etc/resolvconf.conf) provides=(resolvconf) -source=("http://roy.marples.name/downloads/openresolv/${pkgname}-${pkgver}.tar.bz2") -md5sums=('617a52fbe6f253f231d9f78f1ea74281') +source=("http://roy.marples.name/downloads/openresolv/${pkgname}-${pkgver}.tar.bz2" + fs33801.patch) +md5sums=('617a52fbe6f253f231d9f78f1ea74281' + '440790d3403b2ae2c4bb1d657c7e36a4') +build() { + cd $pkgname-$pkgver + patch -Np1 -i ../fs33801.patch + ./configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib/resolvconf +} + package() { - cd "$srcdir/$pkgname-$pkgver" - - ./configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib/resolvconf + cd $pkgname-$pkgver make DESTDIR="$pkgdir" install mkdir -p "$pkgdir/usr/share/licenses/$pkgname" Added: fs33801.patch =================================================================== --- fs33801.patch (rev 0) +++ fs33801.patch 2013-02-11 00:24:43 UTC (rev 84124) @@ -0,0 +1,82 @@ +diff --git i/dnsmasq.in w/dnsmasq.in +index 96b5593..384d9df 100644 +--- i/dnsmasq.in ++++ w/dnsmasq.in +@@ -33,10 +33,9 @@ + NL=" + " + +-: ${dnsmasq_pid:=/var/run/dnsmasq.pid} +-[ -s "$dnsmasq_pid" ] || dnsmasq_pid=/var/run/dnsmasq/dnsmasq.pid + : ${dnsmasq_service:=dnsmasq} + : ${dnsmasq_restart:=@RESTARTCMD ${dnsmasq_service}@} ++: ${dnsmasq_reload:=/usr/bin/systemctl reload ${dnsmasq_service}} + newconf="# Generated by resolvconf$NL" + newresolv="$newconf" + +@@ -182,7 +181,7 @@ if $changed; then + eval $dnsmasq_restart + fi + if $dbus; then +- $changed || kill -HUP $(cat "$dnsmasq_pid") ++ $changed || eval $dnsmasq_reload + # Send even if empty so old servers are cleared + if $dbus_ex; then + method=SetDomainServers +diff --git i/resolvconf.conf.5.in w/resolvconf.conf.5.in +index 81fe154..9b4f1bd 100644 +--- i/resolvconf.conf.5.in ++++ w/resolvconf.conf.5.in +@@ -215,8 +215,8 @@ variables, documented below. + Location of the dnsmasq service. + .It Sy dnsmasq_restart + Command to restart the dnsmasq service. +-.It Sy dnsmasq_pid +-Location of the dnsmasq pidfile. ++.It Sy dnsmasq_reload ++Command to reload the dnsmasq service. + .It Sy libc_service + Location of the libc service. + .It Sy libc_restart +@@ -229,10 +229,8 @@ Command to restart the named service. + Command to restart the pdnsd service. + .It Sy unbound_service + Location of the unbound service. +-.It Sy unbound_restart +-Command to restart the unbound service. +-.It Sy unbound_pid +-Location of the unbound pidfile. ++.It Sy unbound_reload ++Command to reload the unbound service. + .Sh SEE ALSO + .Xr resolv.conf 5 + and +diff --git i/unbound.in w/unbound.in +index 4ee0da7..5e4a326 100644 +--- i/unbound.in ++++ w/unbound.in +@@ -33,9 +33,8 @@ + NL=" + " + +-: ${unbound_pid:=/var/run/unbound.pid} + : ${unbound_service:=unbound} +-: ${unbound_restart:=@RESTARTCMD ${unbound_service}@} ++: ${unbound_reload:=/usr/bin/systemctl reload-or-try-restart ${unbound_service}} + newconf="# Generated by resolvconf$NL" + + for d in $DOMAINS; do +@@ -67,12 +66,5 @@ if [ ! -f "$unbound_conf" ] || \ + [ "$(cat "$unbound_conf")" != "$(printf %s "$newconf")" ] + then + printf %s "$newconf" >"$unbound_conf" +- # If we can't sent a HUP then force a restart +- if [ -s "$unbound_pid" ]; then +- if ! kill -HUP $(cat "$unbound_pid") 2>/dev/null; then +- eval $unbound_restart +- fi +- else +- eval $unbound_restart +- fi ++ eval $unbound_reload + fi