Bug 672980 - M4 macro name should be quoted in AC_DEFUN. r=ted
authorABE Hiroki <h.rayflood>
Tue, 09 Aug 2011 14:27:00 -0400
changeset 74166 f95d2c738d5254cfd16fae4b8115478b2138b0af
parent 74165 89bbee4ec270fadde04578b2b8765a588535e0fc
child 74167 85e0a8801a46dd248b655e81ba8407e4d4ed80c8
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewersted
bugs672980
milestone8.0a1
Bug 672980 - M4 macro name should be quoted in AC_DEFUN. r=ted fixes for js/src f+=Callek
build/autoconf/lto.m4
build/autoconf/mozheader.m4
build/autoconf/moznbytetype.m4
build/autoconf/mozprog.m4
build/autoconf/nss.m4
js/src/build/autoconf/lto.m4
js/src/build/autoconf/moznbytetype.m4
js/src/build/autoconf/mozprog.m4
--- a/build/autoconf/lto.m4
+++ b/build/autoconf/lto.m4
@@ -1,11 +1,11 @@
 dnl check if the build is using lto. This is really primitive and only detects llvm based
 dnl compilers right now.
-AC_DEFUN(MOZ_DOING_LTO,
+AC_DEFUN([MOZ_DOING_LTO],
 [
   cat > conftest.c <<EOF
                   int foo = 1;
 EOF
   $1=no
   if ${CC-cc} ${CFLAGS} -S conftest.c -o conftest.s >/dev/null 2>&1; then
     if grep '^target triple =' conftest.s; then
       $1=yes
--- a/build/autoconf/mozheader.m4
+++ b/build/autoconf/mozheader.m4
@@ -32,17 +32,17 @@ dnl use your version of this file under 
 dnl decision by deleting the provisions above and replace them with the notice
 dnl and other provisions required by the GPL or the LGPL. If you do not delete
 dnl the provisions above, a recipient may use your version of this file under
 dnl the terms of any one of the MPL, the GPL or the LGPL.
 dnl
 dnl ***** END LICENSE BLOCK *****
 
 dnl MOZ_CHECK_HEADER(HEADER-FILE, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
-AC_DEFUN(MOZ_CHECK_HEADER,
+AC_DEFUN([MOZ_CHECK_HEADER],
 [ dnl Do the transliteration at runtime so arg 1 can be a shell variable.
   ac_safe=`echo "$1" | sed 'y%./+-%__p_%'`
   AC_MSG_CHECKING([for $1])
   AC_CACHE_VAL(ac_cv_header_$ac_safe,
  [ AC_TRY_COMPILE([#include <$1>], ,
                   eval "ac_cv_header_$ac_safe=yes",
                   eval "ac_cv_header_$ac_safe=no") ])
   if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
@@ -50,16 +50,16 @@ AC_DEFUN(MOZ_CHECK_HEADER,
     ifelse([$2], , :, [$2])
   else
     AC_MSG_RESULT(no)
     ifelse([$3], , , [$3])
   fi
 ])
 
 dnl MOZ_CHECK_HEADERS(HEADER-FILE... [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
-AC_DEFUN(MOZ_CHECK_HEADERS,
+AC_DEFUN([MOZ_CHECK_HEADERS],
 [ for ac_hdr in $1
   do
     MOZ_CHECK_HEADER($ac_hdr,
                      [ ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
                        AC_DEFINE_UNQUOTED($ac_tr_hdr) $2], $3)
   done
 ])
--- a/build/autoconf/moznbytetype.m4
+++ b/build/autoconf/moznbytetype.m4
@@ -44,17 +44,17 @@ dnl whose written form contains spaces s
 dnl enclosed by shell quotes.
 dnl
 dnl The cache variable moz_cv_n_byte_type_VARIABLE gets set to the
 dnl type, if found.
 dnl 
 dnl for example:
 dnl MOZ_N_BYTE_TYPE([JS_INT32_T], [4], [int long 'long long' short])
 dnl
-AC_DEFUN(MOZ_N_BYTE_TYPE,
+AC_DEFUN([MOZ_N_BYTE_TYPE],
 [
 dnl The simplest approach would simply be to run a program that says
 dnl   printf ("%d\n", sizeof ($type));
 dnl But that won't work when cross-compiling; this will.
 AC_CACHE_CHECK([for a $2-byte type], moz_cv_n_byte_type_$1, [
   moz_cv_n_byte_type_$1=
   for type in $3; do
     AC_TRY_COMPILE([],
@@ -78,17 +78,17 @@ dnl Check to see which of POSSIBLE-SIZES
 dnl define VARIABLE SIZE. If no size matches, exit the configure script with
 dnl an error message.
 dnl
 dnl The cache variable moz_cv_size_of_VARIABLE gets set to the size, if
 dnl found.
 dnl
 dnl for example:
 dnl MOZ_SIZE_OF_TYPE([JS_BYTES_PER_WORD], [void*], [4 8])
-AC_DEFUN(MOZ_SIZE_OF_TYPE,
+AC_DEFUN([MOZ_SIZE_OF_TYPE],
 [
 AC_CACHE_CHECK([for the size of $2], moz_cv_size_of_$1, [
   moz_cv_size_of_$1=
   for size in $3; do
     AC_TRY_COMPILE([],
                    [
                      int a[sizeof ($2) == $size ? 1 : -1];
                      return 0;
@@ -108,17 +108,17 @@ dnl Check to see which of POSSIBLE-ALIGN
 dnl If we find one, define VARIABLE ALIGNMENT. If no alignment matches, exit
 dnl the configure script with an error message.
 dnl
 dnl The cache variable moz_cv_align_of_VARIABLE gets set to the size, if
 dnl found.
 dnl
 dnl for example:
 dnl MOZ_ALIGN_OF_TYPE(JS_ALIGN_OF_POINTER, void*, 2 4 8 16)
-AC_DEFUN(MOZ_ALIGN_OF_TYPE,
+AC_DEFUN([MOZ_ALIGN_OF_TYPE],
 [
 AC_CACHE_CHECK([for the alignment of $2], moz_cv_align_of_$1, [
   moz_cv_align_of_$1=
   for align in $3; do
     AC_TRY_COMPILE([
                      #include <stddef.h>
                      struct aligner { char c; $2 a; };
                    ],
--- a/build/autoconf/mozprog.m4
+++ b/build/autoconf/mozprog.m4
@@ -31,40 +31,40 @@ dnl under the terms of either the GPL or
 dnl use your version of this file under the terms of the MPL, indicate your
 dnl decision by deleting the provisions above and replace them with the notice
 dnl and other provisions required by the GPL or the LGPL. If you do not delete
 dnl the provisions above, a recipient may use your version of this file under
 dnl the terms of any one of the MPL, the GPL or the LGPL.
 dnl
 dnl ***** END LICENSE BLOCK *****
 
-AC_DEFUN(MOZ_PROG_CHECKMSYS,
+AC_DEFUN([MOZ_PROG_CHECKMSYS],
 [AC_REQUIRE([AC_INIT_BINSH])dnl
 if test `uname -s | grep -c MINGW 2>/dev/null` != "0"; then
   msyshost=1
 fi
 ])
 
-AC_DEFUN(MOZ_PATH_PROG,
+AC_DEFUN([MOZ_PATH_PROG],
 [ AC_PATH_PROG($1,$2,$3,$4)
   if test "$msyshost"; then
     case "[$]$1" in
     /*)
       tmp_DIRNAME=`dirname "[$]$1"`
       tmp_BASENAME=`basename "[$]$1"`
       tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W`
       $1="$tmp_PWD/$tmp_BASENAME"
       if test -e "[$]$1.exe"; then
         $1="[$]$1.exe"
       fi
     esac
   fi
 ])
 
-AC_DEFUN(MOZ_PATH_PROGS,
+AC_DEFUN([MOZ_PATH_PROGS],
 [  AC_PATH_PROGS($1,$2,$3,$4)
   if test "$msyshost"; then
     case "[$]$1" in
     /*)
       tmp_DIRNAME=`dirname "[$]$1"`
       tmp_BASENAME=`basename "[$]$1"`
       tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W`
       $1="$tmp_PWD/$tmp_BASENAME"
--- a/build/autoconf/nss.m4
+++ b/build/autoconf/nss.m4
@@ -1,16 +1,16 @@
 # -*- tab-width: 4; -*-
 # Configure paths for NSS
 # Public domain - Chris Seawood <cls@seawood.org> 2001-04-05
 # Based upon gtk.m4 (also PD) by Owen Taylor
 
 dnl AM_PATH_NSS([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
 dnl Test for NSS, and define NSS_CFLAGS and NSS_LIBS
-AC_DEFUN(AM_PATH_NSS,
+AC_DEFUN([AM_PATH_NSS],
 [dnl
 
 AC_ARG_WITH(nss-prefix,
 	[  --with-nss-prefix=PFX   Prefix where NSS is installed],
 	nss_config_prefix="$withval",
 	nss_config_prefix="")
 
 AC_ARG_WITH(nss-exec-prefix,
--- a/js/src/build/autoconf/lto.m4
+++ b/js/src/build/autoconf/lto.m4
@@ -1,11 +1,11 @@
 dnl check if the build is using lto. This is really primitive and only detects llvm based
 dnl compilers right now.
-AC_DEFUN(MOZ_DOING_LTO,
+AC_DEFUN([MOZ_DOING_LTO],
 [
   cat > conftest.c <<EOF
                   int foo = 1;
 EOF
   $1=no
   if ${CC-cc} ${CFLAGS} -S conftest.c -o conftest.s >/dev/null 2>&1; then
     if grep '^target triple =' conftest.s; then
       $1=yes
--- a/js/src/build/autoconf/moznbytetype.m4
+++ b/js/src/build/autoconf/moznbytetype.m4
@@ -44,17 +44,17 @@ dnl whose written form contains spaces s
 dnl enclosed by shell quotes.
 dnl
 dnl The cache variable moz_cv_n_byte_type_VARIABLE gets set to the
 dnl type, if found.
 dnl 
 dnl for example:
 dnl MOZ_N_BYTE_TYPE([JS_INT32_T], [4], [int long 'long long' short])
 dnl
-AC_DEFUN(MOZ_N_BYTE_TYPE,
+AC_DEFUN([MOZ_N_BYTE_TYPE],
 [
 dnl The simplest approach would simply be to run a program that says
 dnl   printf ("%d\n", sizeof ($type));
 dnl But that won't work when cross-compiling; this will.
 AC_CACHE_CHECK([for a $2-byte type], moz_cv_n_byte_type_$1, [
   moz_cv_n_byte_type_$1=
   for type in $3; do
     AC_TRY_COMPILE([],
@@ -78,17 +78,17 @@ dnl Check to see which of POSSIBLE-SIZES
 dnl define VARIABLE SIZE. If no size matches, exit the configure script with
 dnl an error message.
 dnl
 dnl The cache variable moz_cv_size_of_VARIABLE gets set to the size, if
 dnl found.
 dnl
 dnl for example:
 dnl MOZ_SIZE_OF_TYPE([JS_BYTES_PER_WORD], [void*], [4 8])
-AC_DEFUN(MOZ_SIZE_OF_TYPE,
+AC_DEFUN([MOZ_SIZE_OF_TYPE],
 [
 AC_CACHE_CHECK([for the size of $2], moz_cv_size_of_$1, [
   moz_cv_size_of_$1=
   for size in $3; do
     AC_TRY_COMPILE([],
                    [
                      int a[sizeof ($2) == $size ? 1 : -1];
                      return 0;
@@ -108,17 +108,17 @@ dnl Check to see which of POSSIBLE-ALIGN
 dnl If we find one, define VARIABLE ALIGNMENT. If no alignment matches, exit
 dnl the configure script with an error message.
 dnl
 dnl The cache variable moz_cv_align_of_VARIABLE gets set to the size, if
 dnl found.
 dnl
 dnl for example:
 dnl MOZ_ALIGN_OF_TYPE(JS_ALIGN_OF_POINTER, void*, 2 4 8 16)
-AC_DEFUN(MOZ_ALIGN_OF_TYPE,
+AC_DEFUN([MOZ_ALIGN_OF_TYPE],
 [
 AC_CACHE_CHECK([for the alignment of $2], moz_cv_align_of_$1, [
   moz_cv_align_of_$1=
   for align in $3; do
     AC_TRY_COMPILE([
                      #include <stddef.h>
                      struct aligner { char c; $2 a; };
                    ],
--- a/js/src/build/autoconf/mozprog.m4
+++ b/js/src/build/autoconf/mozprog.m4
@@ -31,40 +31,40 @@ dnl under the terms of either the GPL or
 dnl use your version of this file under the terms of the MPL, indicate your
 dnl decision by deleting the provisions above and replace them with the notice
 dnl and other provisions required by the GPL or the LGPL. If you do not delete
 dnl the provisions above, a recipient may use your version of this file under
 dnl the terms of any one of the MPL, the GPL or the LGPL.
 dnl
 dnl ***** END LICENSE BLOCK *****
 
-AC_DEFUN(MOZ_PROG_CHECKMSYS,
+AC_DEFUN([MOZ_PROG_CHECKMSYS],
 [AC_REQUIRE([AC_INIT_BINSH])dnl
 if test `uname -s | grep -c MINGW 2>/dev/null` != "0"; then
   msyshost=1
 fi
 ])
 
-AC_DEFUN(MOZ_PATH_PROG,
+AC_DEFUN([MOZ_PATH_PROG],
 [ AC_PATH_PROG($1,$2,$3,$4)
   if test "$msyshost"; then
     case "[$]$1" in
     /*)
       tmp_DIRNAME=`dirname "[$]$1"`
       tmp_BASENAME=`basename "[$]$1"`
       tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W`
       $1="$tmp_PWD/$tmp_BASENAME"
       if test -e "[$]$1.exe"; then
         $1="[$]$1.exe"
       fi
     esac
   fi
 ])
 
-AC_DEFUN(MOZ_PATH_PROGS,
+AC_DEFUN([MOZ_PATH_PROGS],
 [  AC_PATH_PROGS($1,$2,$3,$4)
   if test "$msyshost"; then
     case "[$]$1" in
     /*)
       tmp_DIRNAME=`dirname "[$]$1"`
       tmp_BASENAME=`basename "[$]$1"`
       tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W`
       $1="$tmp_PWD/$tmp_BASENAME"