Ticket #15551: patch-config.h.3.diff

File patch-config.h.3.diff, 1.5 KB (added by davidgilman1+macports@…, 16 years ago)

3rd revision of proposed config.h patch

  • ./src/config.h

    old new  
    3232#define HOSTSFILE "/etc/hosts"
    3333#define ETHERSFILE "/etc/ethers"
    3434#ifdef __uClinux__
    35 #  define RESOLVFILE "/etc/config/resolv.conf"
     35#  define RESOLVFILE "__PREFIX__/etc/config/resolv.conf"
    3636#else
    37 #  define RESOLVFILE "/etc/resolv.conf"
     37#  define RESOLVFILE "__PREFIX__/etc/resolv.conf"
     38#endif
     39#ifdef __APPLE__
     40#  define RUNFILE "__PREFIX__/var/run/dnsmasq.pid"
     41#else
     42#  define RUNFILE "__PREFIX__/var/run/dnsmasq.pid"
    3843#endif
    39 #define RUNFILE "/var/run/dnsmasq.pid"
    4044#if defined(__FreeBSD__) || defined (__OpenBSD__) || defined(__DragonFly__)
    41 #   define LEASEFILE "/var/db/dnsmasq.leases"
     45#   define LEASEFILE "__PREFIX__/var/db/dnsmasq.leases"
     46#elif __APPLE__
     47#   define LEASEFILE "__PREFIX__/var/db/dnsmasq.leases"
    4248#elif defined(__sun__)
    43 #   define LEASEFILE "/var/cache/dnsmasq.leases"
     49#   define LEASEFILE "__PREFIX__/var/cache/dnsmasq.leases"
    4450#else
    45 #   define LEASEFILE "/var/lib/misc/dnsmasq.leases"
     51#   define LEASEFILE "__PREFIX__/var/lib/misc/dnsmasq.leases"
    4652#endif
    4753#if defined(__FreeBSD__)
    48 #   define CONFFILE "/usr/local/etc/dnsmasq.conf"
     54#   define CONFFILE "__PREFIX__/usr/local/etc/dnsmasq.conf"
     55#elif __APPLE__
     56#   define CONFFILE "__PREFIX__/etc/dnsmasq.conf"
    4957#else
    50 #   define CONFFILE "/etc/dnsmasq.conf"
     58#   define CONFFILE "__PREFIX__/etc/dnsmasq.conf"
    5159#endif
    5260#define DEFLEASE 3600 /* default lease time, 1 hour */
    5361#define CHUSER "nobody"