Changeset 28837


Ignore:
Timestamp:
2011-11-07T23:58:45+01:00 (6 years ago)
Author:
nico
Message:

package/dnsmasq: use new service wrapper

Location:
trunk/package/dnsmasq
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/package/dnsmasq/Makefile

    r28333 r28837  
    1010PKG_NAME:=dnsmasq 
    1111PKG_VERSION:=2.58 
    12 PKG_RELEASE:=1 
     12PKG_RELEASE:=2 
    1313 
    1414PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz 
  • trunk/package/dnsmasq/files/dnsmasq.init

    r28493 r28837  
    33 
    44START=60 
     5 
     6SERVICE_USE_PID=1 
     7 
    58DNS_SERVERS="" 
    69DOMAIN="" 
     
    398401        config_foreach dhcp_cname_add cname 
    399402 
    400         /usr/sbin/dnsmasq $args && { 
     403        service_start /usr/sbin/dnsmasq $args && { 
    401404                rm -f /tmp/resolv.conf 
    402405                [ -n "$DOMAIN" ] && echo "search $DOMAIN" >> /tmp/resolv.conf 
     
    409412 
    410413stop() { 
    411         [ -f /tmp/resolv.conf ] && { 
    412                 rm -f /tmp/resolv.conf 
    413                 ln -s /tmp/resolv.conf.auto /tmp/resolv.conf 
     414        service_stop /usr/sbin/dnsmasq && { 
     415                [ -f /tmp/resolv.conf ] && { 
     416                        rm -f /tmp/resolv.conf 
     417                        ln -s /tmp/resolv.conf.auto /tmp/resolv.conf 
     418                } 
    414419        } 
    415         service_kill dnsmasq /var/run/dnsmasq.pid 
    416         return 0 
    417 } 
     420} 
Note: See TracChangeset for help on using the changeset viewer.