]> code.delx.au - gnu-emacs/blobdiff - autogen.sh
Do not require that .git be a directory
[gnu-emacs] / autogen.sh
index 2ed58e15aea47ae861b1cfb76b0ad9e221586848..2e10a77cb3731e5b072e8eebc5ff577edee3c4a9 100755 (executable)
@@ -104,9 +104,10 @@ check_version ()
 }
 
 do_autoconf=false
+test $# -eq 0 && do_autoconf=true
 do_git=false
 
-for arg in ${*-autoconf}; do
+for arg; do
     case $arg in
       --help)
        exec echo "$0: usage: $0 [all|autoconf|git]";;
@@ -280,6 +281,11 @@ git_config transfer.fsckObjects true
 
 git_config diff.elisp.xfuncname \
           '^\(def[^[:space:]]+[[:space:]]+([^()[:space:]]+)'
+git_config 'diff.m4.xfuncname' '^((m4_)?define|A._DEFUN(_ONCE)?)\([^),]*'
+git_config 'diff.make.xfuncname' \
+          '^([$.[:alnum:]_].*:|[[:alnum:]_]+[[:space:]]*([*:+]?[:?]?|!?)=|define .*)'
+git_config 'diff.shell.xfuncname' \
+          '^([[:space:]]*[[:alpha:]_][[:alnum:]_]*[[:space:]]*\(\)|[[:alpha:]_][[:alnum:]_]*=)'
 git_config diff.texinfo.xfuncname \
           '^@node[[:space:]]+([^,[:space:]][^,]+)'
 
@@ -324,7 +330,7 @@ fi
 
 if test ! -f configure; then
     echo "You can now run '$0 autoconf'."
-elif test -d .git && test $git_was_ok = false && test $do_git = false; then
+elif test -e .git && test $git_was_ok = false && test $do_git = false; then
     echo "You can now run '$0 git'."
 elif test ! -f config.status ||
        test -n "`find src/stamp-h.in -newer config.status`"; then