From cb52ac9847b70bfab3b6ca45b3e81e6c89900190 Mon Sep 17 00:00:00 2001 From: Michael Marineau Date: Tue, 2 Sep 2014 20:39:28 -0700 Subject: build-sys: create parent directory for $(PATHFILES) When building outside the source tree there is nothing to guarantee the target directory exists before writing to it. Most of the time this just happens to work because something else creates the directory but not always. For example: $ mkdir build $ cd build $ ../configure --disable-dependency-tracking $ make libuuid/uuid.pc GEN libuuid/uuid.pc /bin/sh: line 2: libuuid/uuid.pc.tmp: No such file or directory make: *** [libuuid/uuid.pc] Error 1 --- Makefile.am | 1 + 1 file changed, 1 insertion(+) (limited to 'Makefile.am') diff --git a/Makefile.am b/Makefile.am index 79b5aea78..08269e248 100644 --- a/Makefile.am +++ b/Makefile.am @@ -128,6 +128,7 @@ EXTRA_DIST += $(PATHFILES:=.in) $(PATHFILES): Makefile @ rm -f $@ $@.tmp + $(AM_V_at) test -d $(dir $@) || mkdir -p $(dir $@) $(AM_V_GEN) srcdir=''; \ test -f ./$@.in || srcdir=$(srcdir)/; \ $(edit_cmd) $${srcdir}$@.in >$@.tmp -- cgit v1.2.3-55-g7522