diff options
author | Roy Marples <uberlord@gentoo.org> | 2007-05-23 17:20:54 +0000 |
---|---|---|
committer | Roy Marples <uberlord@gentoo.org> | 2007-05-23 17:20:54 +0000 |
commit | 54bb365f7f931ad8226123b67d445af8c1909611 (patch) | |
tree | 63ffdef86db332ded3467eb38c57075a391cee61 /net-dns | |
parent | Add ~x86-fbsd keyword. Bug #176906. (diff) | |
download | gentoo-2-54bb365f7f931ad8226123b67d445af8c1909611.tar.gz gentoo-2-54bb365f7f931ad8226123b67d445af8c1909611.tar.bz2 gentoo-2-54bb365f7f931ad8226123b67d445af8c1909611.zip |
Fix the resolvconf script to work properly on FreeBSD.
(Portage version: 2.1.2.7)
Diffstat (limited to 'net-dns')
-rw-r--r-- | net-dns/dnsmasq/ChangeLog | 5 | ||||
-rw-r--r-- | net-dns/dnsmasq/files/resolvconf.dnsmasq | 12 |
2 files changed, 10 insertions, 7 deletions
diff --git a/net-dns/dnsmasq/ChangeLog b/net-dns/dnsmasq/ChangeLog index 48f05037725e..6efa119b0feb 100644 --- a/net-dns/dnsmasq/ChangeLog +++ b/net-dns/dnsmasq/ChangeLog @@ -1,6 +1,9 @@ # ChangeLog for net-dns/dnsmasq # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-dns/dnsmasq/ChangeLog,v 1.124 2007/05/09 22:06:50 gustavoz Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-dns/dnsmasq/ChangeLog,v 1.125 2007/05/23 17:20:54 uberlord Exp $ + + 23 May 2007; Roy Marples <uberlord@gentoo.org> files/resolvconf.dnsmasq: + Fix the resolvconf script to work properly on FreeBSD. 09 May 2007; Gustavo Zacarias <gustavoz@gentoo.org> dnsmasq-2.39.ebuild: Stablebump bad, blame chutzpah diff --git a/net-dns/dnsmasq/files/resolvconf.dnsmasq b/net-dns/dnsmasq/files/resolvconf.dnsmasq index 62fc73f4118f..ed9e01019847 100644 --- a/net-dns/dnsmasq/files/resolvconf.dnsmasq +++ b/net-dns/dnsmasq/files/resolvconf.dnsmasq @@ -33,7 +33,7 @@ DNSMASQRESOLV="/etc/dnsmasq-resolv.conf" DNSMASQCONF="/etc/dnsmasq-resolvconf.conf" NEWCONF="# Generated by resolvconf" -NEWRESOLV="${NEWCONF}\nsearch" +NEWRESOLV="${NEWCONF}\n" # Using DBUS means that we never have to restart the daemon # This is important as it means we should not drop DNS queries @@ -48,7 +48,7 @@ grep -q "^Compile time options.*[[:space:]]DBus[[:space:]]" \ if [ -x /etc/init.d/dbus -a -x /etc/init.d/dnsmasq ] ; then if /etc/init.d/dbus --quiet status && /etc/init.d/dnsmasq --quiet status ; then DBUS=yes - NEWCONF="${NEWCONF}\n# Domain specific servers will be sent over dbus\n\nenable-dbus" + NEWCONF="${NEWCONF}\n# Domain specific servers will be sent over dbus\n\nenable-dbus\n" fi fi fi @@ -75,16 +75,16 @@ for N in ${NEWSEARCH} ; do esac case "\n${NEWRESOLV}\n" in *"\nnameserver ${N#*,}\n"*) ;; - *) NEWRESOLV="${NEWRESOLV}\nnameserver ${N#*,}" ;; + *) NEWRESOLV="${NEWRESOLV}nameserver ${N#*,}\n" ;; esac done for N in ${NEWNS} ; do case "\n${NEWRESOLV}\n" in *"\nnameserver ${N}\n") ;; - *) NEWRESOLV="${NEWRESOLV}\nnameserver ${N}" ;; + *) NEWRESOLV="${NEWRESOLV}nameserver ${N}\n" ;; esac done -NEWRESOLV="$(echo "${NEWRESOLV}" | sed -e "s/^search/${NEWSL:+search${NEWSL}}/g")" +[ -n "${NEWSL}" ] && NEWRESOLV="${NEWRESOLV}search${NEWSL}\n" DBUSDEST= for DN in $(uniqify ${NEWDOMAIN}) ; do @@ -101,7 +101,7 @@ for DN in $(uniqify ${NEWDOMAIN}) ; do fi DBUSDEST="${DBUSDEST} uint32:$(printf "%d" ${NUM}) string:${DN%,*}" else - NEWCONF="${NEWCONF}\nserver=/${DN%,*}/${DN#*,}" + NEWCONF="${NEWCONF}server=/${DN%,*}/${DN#*,}\n" fi done |