From: Mark Wooding Date: Wed, 5 Jun 2013 19:54:17 +0000 (+0100) Subject: bin/mdw-build: Fetch `distdir' more robustly. X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/profile/commitdiff_plain/dd8d9a6cdcb8c9f4682dc99216db715c406e60a8 bin/mdw-build: Fetch `distdir' more robustly. Some build scripts will try to build something before they can properly answer the `print-distdir' question. Avoid being confused by the resulting spam by writing the distribution directory name to a weird file descriptor. --- diff --git a/bin/mdw-build b/bin/mdw-build index bd1b457..69a6642 100755 --- a/bin/mdw-build +++ b/bin/mdw-build @@ -285,9 +285,10 @@ esac cat >find-distdir.mk <<'EOF' include Makefile print-distdir: - @echo $(distdir) + @echo >&3 $(distdir) EOF -assign distdir $(make -f find-distdir.mk print-distdir) +assign distdir \ + $({ make -f find-distdir.mk print-distdir >/dev/null 2>&1; } 3>&1) ## Get a tarball distribution. case "$distcheck" in