From: Christian Hofstaedtler Date: Wed, 5 Jun 2013 02:16:00 +0000 (+0200) Subject: Allow overriding of SYSCONFDIR, LOCALSTATEDIR from recursor Makefile X-Git-Tag: rec-3.6.0-rc1~558^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=bbe4233e1d99b59f7036c1ddbcae1bf77133a124;p=thirdparty%2Fpdns.git Allow overriding of SYSCONFDIR, LOCALSTATEDIR from recursor Makefile Fixes #734. --- diff --git a/pdns/Makefile-recursor b/pdns/Makefile-recursor index 8ee769d2a3..1a04dc6b5a 100644 --- a/pdns/Makefile-recursor +++ b/pdns/Makefile-recursor @@ -1,7 +1,8 @@ # user editable stuff: SBINDIR=/usr/sbin/ BINDIR=/usr/bin/ -CONFIGDIR="/etc/powerdns/" +SYSCONFDIR=/etc/powerdns/ +LOCALSTATEDIR=/var/run/ OPTFLAGS?=-O3 CXXFLAGS:= $(CXXFLAGS) -Iext/rapidjson/include -Wall $(OPTFLAGS) $(PROFILEFLAGS) $(ARCHFLAGS) -pthread CFLAGS:=$(CFLAGS) -Wall $(OPTFLAGS) $(PROFILEFLAGS) $(ARCHFLAGS) -pthread @@ -53,6 +54,9 @@ endif LDFLAGS += $(PROFILEFLAGS) $(STATICFLAGS) +CXXFLAGS += -DSYSCONFDIR='"$(SYSCONFDIR)"' -DLOCALSTATEDIR='"$(LOCALSTATEDIR)"' +CFLAGS += -DSYSCONFDIR='"$(SYSCONFDIR)"' -DLOCALSTATEDIR='"$(LOCALSTATEDIR)"' + # Version build_date=$(shell LC_TIME=C date '+%Y%m%d%H%M%S') build_host=$(shell id -u -n)@$(shell hostname -f) diff --git a/pdns/config-recursor.h b/pdns/config-recursor.h index 491b46c653..0e713a35b6 100644 --- a/pdns/config-recursor.h +++ b/pdns/config-recursor.h @@ -1,3 +1 @@ -#define SYSCONFDIR "/etc/powerdns/" -#define LOCALSTATEDIR "/var/run/" #define RECURSOR