From 79dc977cd1e43a271015416589e1a304be78ac69 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sat, 14 Oct 2006 23:40:42 +0000 Subject: Sync from Automake. * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m, which incorrectly sets the mode of an existing destination directory. In some cases the unpatched install-sh could do the equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD system. We hope this is rare in practice, but it's clearly worth fixing. Problem reported by Alex Unleashed in . Also, don't bother to check for -m bugs unless we're using -m; suggested by Stepan Kasal. 2006-10-14 Ralf Wildenhues Sync from Automake. * build-aux/depcomp (gcc3): Put dependency extraction flags before the `-c' flag, so they appear at the same position as in %FASTDEP% mode in depend2.am. Fixes build failure for FreeBSD's c89, which ignores unknown options only after the first non-option. Bug report against M4 by Nelson H. F. Beebe. --- build-aux/depcomp | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'build-aux/depcomp') diff --git a/build-aux/depcomp b/build-aux/depcomp index ffe5461bde..7d409372d7 100755 --- a/build-aux/depcomp +++ b/build-aux/depcomp @@ -92,7 +92,20 @@ gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. - "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" +## Unfortunately, FreeBSD c89 acceptance of flags depends upon +## the command line argument order; so add the flags where they +## appear in depend2.am. Note that the slowdown incurred here +## affects only configure: in makefiles, %FASTDEP% shortcuts this. + for arg + do + case $arg in + -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; + *) set fnord "$@" "$arg" ;; + esac + shift # fnord + shift # $arg + done + "$@" stat=$? if test $stat -eq 0; then : else -- cgit v1.2.1