From 38b8611885ed99dc04480dbc831bae89b6c15b37 Mon Sep 17 00:00:00 2001 From: Pieter Lexis Date: Tue, 10 Jan 2017 15:20:44 +0100 Subject: [PATCH] Fix dnsdist out-of-tree builds Closes #4866 --- pdns/dnsdistdist/.gitignore | 1 + pdns/dnsdistdist/Makefile.am | 9 +++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/pdns/dnsdistdist/.gitignore b/pdns/dnsdistdist/.gitignore index 7f6929738..0cc6785d1 100644 --- a/pdns/dnsdistdist/.gitignore +++ b/pdns/dnsdistdist/.gitignore @@ -23,6 +23,7 @@ /ext/yahttp/yahttp/Makefile /ext/yahttp/yahttp/Makefile.in /htmlfiles.h +/htmlfiles.h.tmp /install-sh /libtool /ltmain.sh diff --git a/pdns/dnsdistdist/Makefile.am b/pdns/dnsdistdist/Makefile.am index 5948b1b8d..c4a01202c 100644 --- a/pdns/dnsdistdist/Makefile.am +++ b/pdns/dnsdistdist/Makefile.am @@ -4,15 +4,16 @@ ACLOCAL_AMFLAGS = -I m4 SUBDIRS=ext/yahttp -CLEANFILES = dnsmessage.pb.cc dnsmessage.pb.h +CLEANFILES = dnsmessage.pb.cc dnsmessage.pb.h htmlfiles.h.tmp htmlfiles.h dnslabeltext.cc: dnslabeltext.rl $(AM_V_GEN)$(RAGEL) $< -o dnslabeltext.cc BUILT_SOURCES=htmlfiles.h -htmlfiles.h: html/* - ./incfiles > $@ +htmlfiles.h: $(srcdir)/html/* + $(AM_V_GEN)$(srcdir)/incfiles $(srcdir) > $@.tmp + @mv $@.tmp $@ SRC_JS_FILES := $(wildcard src_js/*.js) MIN_JS_FILES := $(patsubst src_js/%.js,html/js/%.min.js,$(SRC_JS_FILES)) @@ -134,7 +135,7 @@ endif if HAVE_PROTOBUF if HAVE_PROTOC dnsmessage.pb.cc: dnsmessage.proto - $(AM_V_GEN)$(PROTOC) --cpp_out=./ $< + $(AM_V_GEN)$(PROTOC) -I$(srcdir) --cpp_out=./ $< BUILT_SOURCES += dnsmessage.pb.cc -- 2.40.0