This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

tweaks for autoconf 2.50


Autoconf 2.50 came out last week.  This patchset corrects several
places where our configure scripts had ugly hacks that broke.  I do
not introduce any new features; all the scripts still work with the
old autoconf (I'm verifying this by running a bootstrap having
regenerated them all with 2.13).

The tweaks fall into two major categories.  The specs have been
tightened up, such that we have to be a more careful with quoting,
recursive AC_REQUIRE, etc.  Also, the local copy of AC_PROG_CC in
libiberty (propagated to libjava, libstdc++3, and several other
places) had to die.  AC_PROG_CC from 2.13 works just fine when
cross-compiling, we know this because the gcc directory has been using
it all along.

I'm pleased to see that a lot of our local hacks can go away when we
start migrating to 2.50 for real.  I am not so pleased with how much
slower the new autoconf is.  Time to regenerate every configure and
config.h.in in the tree:

	2.13		2.50
real    0m5.796s	1m1.529s
user    0m4.820s	0m47.650s
sys     0m0.980s	0m1.160s

p.s. I also removed gcc/ch/configure which has been a dead file since
before EGCS began.

-- 
zw   Actually, we have scientifically determined that Heisenberg did indeed
     sleep exactly here. However, we have no idea whatsoever just how fast
     asleep he was.
     	-- Dave Aronson

boehm-gc:
	* aclocal.m4 (LIB_AC_PROG_CC, LIB_AC_PROG_CXX): Delete.
	(BOEHM_CONFIGURE): Don't call AC_CANONICAL_HOST or
	AC_CANONICAL_BUILD here. Use plain AC_PROG_CC and AC_PROG_CXX.
	* configure: Regenerate.

gcc:
	* aclocal.m4 (gcc_AC_CHECK_DECLS): Quote arguments of patsubst.
	(gcc_AC_C_LONG_DOUBLE): Use 3-argument AC_DEFINE.
	(gcc_AC_CHECK_PROG_VER): Restore normal quote markers around
	use of AC_FD_CC.
	* configure.in: Remove unnecessary changequotes.
	* configure, config.in: Regenerate.
gcc/ch:
	* configure: Delete file.

libiberty:
	* aclocal.m4 (LIB_AC_PROG_CC): Delete.
	* configure.in: Use plain AC_PROG_CC, then set
	ac_libiberty_warn_cflags from $GCC.
	* configure: Regenerate.

libjava:
	* aclocal.m4 (LIBGCJ_CONFIGURE): Don't call AC_CANONICAL_HOST
	or AC_CANONICAL_BUILD here.
	* configure.host: Rename AM_RUNTESTFLAGS to GCJ_RUNTESTFLAGS.
	* configure.in: Call AC_CONFIG_SUBDIRS conditionally and with
	a literal argument, not a variable.  AC_SUBST GCJ_RUNTESTFLAGS,
	not AM_RUNTESTFLAGS.
	* configure: Regenerate.
	* testsuite/Makefile.am: Rename AM_RUNTESTFLAGS to GCJ_RUNTESTFLAGS.
	* testsuite/Makefile.in: Regenerate (by hand).

libjava/libltdl:
	* aclocal.m4 (AC_LIB_LTDL): AC_REQUIRE AC_LTDL_DLSYM_USCORE
	not AC_LTDL_SYMBOL_USCORE.
	(AC_LTDL_DLSYM_USCORE): Don't call AC_LTDL_DLSYM_USCORE here.
	* configure: Regenerate.

libstdc++-v3:
	* aclocal.m4 (LIB_AC_PROG_CC, LIB_AC_PROG_CXX): Delete.
	(GLIBCPP_CONFIGURE): Don't call AC_CANONICAL_HOST or
	AC_CANONICAL_BUILD here. Use plain AC_PROG_CC and
	AC_PROG_CXX.  Do not dork with AC_PROG_CC_G, AC_PROG_CC_GNU,
	AC_PROG_CXX_G, or AC_PROG_CXX_GNU.
	* configure: Regenerate.

zlib:
	* aclocal.m4 (LIB_AC_PROG_CC): Delete.
	* configure.in: Use plain AC_PROG_CC.
	* configure: Regenerate.


===================================================================
Index: boehm-gc/aclocal.m4
--- boehm-gc/aclocal.m4	2001/05/21 08:35:12	1.14
+++ boehm-gc/aclocal.m4	2001/05/24 05:21:06
@@ -41,91 +41,10 @@ else
 fi
 AC_SUBST(boehm_gc_basedir)
 
-AC_CANONICAL_HOST
-
 AM_INIT_AUTOMAKE(boehm-gc, 6.0a7, no-define)
-
-# FIXME: We temporarily define our own version of AC_PROG_CC.  This is
-# copied from autoconf 2.12, but does not call AC_PROG_CC_WORKS.  We
-# are probably using a cross compiler, which will not be able to fully
-# link an executable.  This should really be fixed in autoconf
-# itself.
-
-AC_DEFUN(LIB_AC_PROG_CC,
-[AC_BEFORE([$0], [AC_PROG_CPP])dnl
-dnl Fool anybody using AC_PROG_CC.
-AC_PROVIDE([AC_PROG_CC])
-AC_CHECK_PROG(CC, gcc, gcc)
-if test -z "$CC"; then
-  AC_CHECK_PROG(CC, cc, cc, , , /usr/ucb/cc)
-  test -z "$CC" && AC_MSG_ERROR([no acceptable cc found in \$PATH])
-fi
-
-AC_PROG_CC_GNU
-
-if test $ac_cv_prog_gcc = yes; then
-  GCC=yes
-dnl Check whether -g works, even if CFLAGS is set, in case the package
-dnl plays around with CFLAGS (such as to build both debugging and
-dnl normal versions of a library), tasteless as that idea is.
-  ac_test_CFLAGS="${CFLAGS+set}"
-  ac_save_CFLAGS="$CFLAGS"
-  CFLAGS=
-  AC_PROG_CC_G
-  if test "$ac_test_CFLAGS" = set; then
-    CFLAGS="$ac_save_CFLAGS"
-  elif test $ac_cv_prog_cc_g = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-O2"
-  fi
-else
-  GCC=
-  test "${CFLAGS+set}" = set || CFLAGS="-g"
-fi
-])
-
-LIB_AC_PROG_CC
-
-# Likewise for AC_PROG_CXX.
-AC_DEFUN(LIB_AC_PROG_CXX,
-[AC_BEFORE([$0], [AC_PROG_CXXCPP])dnl
-dnl Fool anybody using AC_PROG_CXX.
-AC_PROVIDE([AC_PROG_CXX])
-AC_CHECK_PROGS(CXX, $CCC c++ g++ gcc CC cxx cc++, gcc)
-test -z "$CXX" && AC_MSG_ERROR([no acceptable c++ found in \$PATH])
-
-AC_PROG_CXX_GNU
-
-if test $ac_cv_prog_gxx = yes; then
-  GXX=yes
-dnl Check whether -g works, even if CXXFLAGS is set, in case the package
-dnl plays around with CXXFLAGS (such as to build both debugging and
-dnl normal versions of a library), tasteless as that idea is.
-  ac_test_CXXFLAGS="${CXXFLAGS+set}"
-  ac_save_CXXFLAGS="$CXXFLAGS"
-  CXXFLAGS=
-  AC_PROG_CXX_G
-  if test "$ac_test_CXXFLAGS" = set; then
-    CXXFLAGS="$ac_save_CXXFLAGS"
-  elif test $ac_cv_prog_cxx_g = yes; then
-    CXXFLAGS="-g -O2"
-  else
-    CXXFLAGS="-O2"
-  fi
-else
-  GXX=
-  test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
-fi
-])
-
-LIB_AC_PROG_CXX
 
-# AC_CHECK_TOOL does AC_REQUIRE (AC_CANONICAL_BUILD).  If we don't
-# run it explicitly here, it will be run implicitly before
-# NEWLIB_CONFIGURE, which doesn't work because that means that it will
-# be run before AC_CANONICAL_HOST.
-AC_CANONICAL_BUILD
+AC_PROG_CC
+AC_PROG_CXX
 
 AC_CHECK_TOOL(AS, as)
 AC_CHECK_TOOL(AR, ar)
===================================================================
Index: gcc/aclocal.m4
--- gcc/aclocal.m4	2001/05/01 17:45:02	1.47
+++ gcc/aclocal.m4	2001/05/24 05:21:07
@@ -57,8 +57,8 @@ done
 dnl Automatically generate config.h entries via autoheader.
 if test x = y ; then
   patsubst(translit([$1], [a-z], [A-Z]), [\w+],
-    AC_DEFINE([HAVE_DECL_\&], 1,
-      [Define to 1 if we found this declaration otherwise define to 0.]))dnl
+    [AC_DEFINE([HAVE_DECL_\&], 1,
+      [Define to 1 if we found this declaration otherwise define to 0.])])dnl
 fi
 ])
 
@@ -193,7 +193,8 @@ switch (0) case 0: case (sizeof(long dou
 gcc_cv_c_long_double=yes, gcc_cv_c_long_double=no)
 fi])
 if test $gcc_cv_c_long_double = yes; then
-  AC_DEFINE(HAVE_LONG_DOUBLE)
+  AC_DEFINE(HAVE_LONG_DOUBLE, 1, 
+      [Define if your compiler supports the \`long double' type.])
 fi
 ])
 
@@ -1110,7 +1111,9 @@ if test -n "[$]$1"; then
 [changequote(<<,>>)dnl
   ac_prog_version=`<<$>>$1 $3 2>&1 |
                    sed -n 's/^.*patsubst(<<$4>>,/,\/).*$/\1/p'`
+changequote([,])dnl
   echo "configure:__oline__: version of $2 is $ac_prog_version" >&AC_FD_CC
+changequote(<<,>>)dnl
   case $ac_prog_version in
     '')     gcc_cv_prog_$2_modern=no;;
     <<$5>>)
===================================================================
Index: gcc/configure.in
--- gcc/configure.in	2001/05/18 19:14:19	1.524
+++ gcc/configure.in	2001/05/24 05:21:08
@@ -741,7 +741,6 @@ echo "Using \`$srcdir/config/$md_file' a
 # If any of the xm_file variables contain nonexistent files, warn
 # about them and drop them.
 
-changequote(,)dnl
 bx=
 for x in $build_xm_file; do
   if    test -f $srcdir/config/$x
@@ -768,7 +767,6 @@ for x in $xm_file; do
   fi
 done
 xm_file="$tx"
-changequote([,])dnl
 
 count=a
 for f in $tm_file; do
===================================================================
Index: libiberty/aclocal.m4
--- libiberty/aclocal.m4	2001/03/06 09:52:35	1.4
+++ libiberty/aclocal.m4	2001/05/24 05:21:10
@@ -84,48 +84,6 @@ then AC_DEFINE(NEED_DECLARATION_ERRNO, 1
 fi
 ])
 
-# FIXME: We temporarily define our own version of AC_PROG_CC.  This is
-# copied from autoconf 2.12, but does not call AC_PROG_CC_WORKS.  We
-# are probably using a cross compiler, which will not be able to fully
-# link an executable.  This should really be fixed in autoconf
-# itself.
-
-AC_DEFUN(LIB_AC_PROG_CC,
-[AC_BEFORE([$0], [AC_PROG_CPP])dnl
-AC_PROVIDE([AC_PROG_CC])
-AC_CHECK_PROG(CC, gcc, gcc)
-if test -z "$CC"; then
-  AC_CHECK_PROG(CC, cc, cc, , , /usr/ucb/cc)
-  test -z "$CC" && AC_MSG_ERROR([no acceptable cc found in \$PATH])
-fi
-
-AC_PROG_CC_GNU
-
-if test $ac_cv_prog_gcc = yes; then
-  GCC=yes
-  ac_libiberty_warn_cflags='-W -Wall -Wtraditional -pedantic'
-dnl Check whether -g works, even if CFLAGS is set, in case the package
-dnl plays around with CFLAGS (such as to build both debugging and
-dnl normal versions of a library), tasteless as that idea is.
-  ac_test_CFLAGS="${CFLAGS+set}"
-  ac_save_CFLAGS="$CFLAGS"
-  CFLAGS=
-  AC_PROG_CC_G
-  if test "$ac_test_CFLAGS" = set; then
-    CFLAGS="$ac_save_CFLAGS"
-  elif test $ac_cv_prog_cc_g = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-O2"
-  fi
-else
-  GCC=
-  ac_libiberty_warn_cflags=
-  test "${CFLAGS+set}" = set || CFLAGS="-g"
-fi
-AC_SUBST(ac_libiberty_warn_cflags)
-])
-
 # Work around a bug in autoheader.  This can go away when we switch to
 # autoconf >2.50.  The use of define instead of AC_DEFUN is
 # deliberate.
===================================================================
Index: libiberty/configure.in
--- libiberty/configure.in	2001/03/06 09:52:35	1.32
+++ libiberty/configure.in	2001/05/24 05:21:10
@@ -36,8 +36,14 @@ dnl to call AC_CHECK_PROG.
 AC_CHECK_TOOL(AR, ar)
 AC_CHECK_TOOL(RANLIB, ranlib, :)
 
-LIB_AC_PROG_CC
+AC_PROG_CC
 
+ac_libiberty_warn_cflags=
+if test x$GCC = xyes; then
+  ac_libiberty_warn_cflags='-W -Wall -Wtraditional -pedantic'
+fi
+AC_SUBST(ac_libiberty_warn_cflags)
+
 AC_ISC_POSIX
 AC_C_CONST
 AC_C_INLINE
@@ -273,7 +279,6 @@ if test -z "${setobjs}"; then
 
   # We haven't set the list of objects yet.  Use the standard autoconf
   # tests.  This will only work if the compiler works.
-  AC_PROG_CC_WORKS
   AC_REPLACE_FUNCS($funcs)
   libiberty_AC_FUNC_C_ALLOCA
   AC_FUNC_VFORK
===================================================================
Index: libjava/aclocal.m4
--- libjava/aclocal.m4	2000/09/14 08:01:12	1.14
+++ libjava/aclocal.m4	2001/05/24 05:21:10
@@ -35,8 +35,6 @@ else
 fi
 AC_SUBST(libgcj_basedir)
 
-AC_CANONICAL_HOST
-
 dnl This shouldn't be needed, as long as top-level dependencies are
 dnl defined correctly and shared-library paths are set up so that
 dnl execution tests succeed.  FIXME.
@@ -50,12 +48,6 @@ dnl version is pulled out to make it a b
 version=0.0.7
 dnl Still use "libjava" here to placate dejagnu.
 AM_INIT_AUTOMAKE(libjava, $version)
-
-# AC_CHECK_TOOL does AC_REQUIRE (AC_CANONICAL_BUILD).  If we dont
-# run it explicitly here, it will be run implicitly before
-# LIBGCJ_CONFIGURE, which doesn't work because that means that it will
-# be run before AC_CANONICAL_HOST.
-AC_CANONICAL_BUILD
 
 AC_CHECK_TOOL(AS, as)
 AC_CHECK_TOOL(AR, ar)
===================================================================
Index: libjava/configure.host
--- libjava/configure.host	2001/05/21 16:59:41	1.19
+++ libjava/configure.host	2001/05/24 05:21:10
@@ -37,7 +37,8 @@ case "${target_optspace}:${host}" in
     ;;
 esac
 
-AM_RUNTESTFLAGS= 
+# This can't be called RUNTESTFLAGS, or automake pukes.  Aaaaaargh.
+GCJ_RUNTESTFLAGS= 
 
 # Set any host dependent compiler flags.
 # THIS TABLE IS SORTED.  KEEP IT THAT WAY.
@@ -51,7 +52,7 @@ case "${host}" in
   mips-tx39-*|mipstx39-unknown-*)
 	libgcj_flags="${libgcj_flags} -G 0"
 	LDFLAGS="$LDFLAGS -Tjmr3904dram.ld"
-	AM_RUNTESTFLAGS="--target_board=jmr3904-sim"	
+	GCJ_RUNTESTFLAGS="--target_board=jmr3904-sim"	
 	# Use "Ecos" processes since they are a no-op.
 	PROCESS=Ecos
  	enable_java_net_default=no
===================================================================
Index: libjava/configure.in
--- libjava/configure.in	2001/05/23 17:13:26	1.85
+++ libjava/configure.in	2001/05/24 05:21:11
@@ -31,7 +31,9 @@ AC_SUBST(INCLTDL)
 AC_SUBST(LIBLTDL)
 AC_SUBST(DIRLTDL)
 AM_PROG_LIBTOOL
-AC_CONFIG_SUBDIRS($DIRLTDL)
+if test -z "${with_cross_host}"; then
+  AC_CONFIG_SUBDIRS(libltdl)
+fi
 
 if test -z "$with_target_subdir" || test "$with_target_subdir" = "."; then
    COMPPATH=.
@@ -646,8 +648,7 @@ gcjvers="`$GCJ -v 2>&1 | sed -n 's/^.*ve
 changequote([,])
 AC_DEFINE_UNQUOTED(GCJVERSION, "$gcjvers")
 AC_SUBST(GCJVERSION)
-
-AC_SUBST(AM_RUNTESTFLAGS)
+AC_SUBST(GCJ_RUNTESTFLAGS)
 
 dnl Work around a g++ bug.  Reported to gcc-bugs@gcc.gnu.org on Jan 22, 2000.
 AC_MSG_CHECKING([for g++ -ffloat-store bug])
===================================================================
Index: libjava/libltdl/aclocal.m4
--- libjava/libltdl/aclocal.m4	2000/09/10 08:04:40	1.2
+++ libjava/libltdl/aclocal.m4	2001/05/24 05:21:11
@@ -848,7 +848,7 @@ AC_REQUIRE([AC_LTDL_SYSSEARCHPATH])dnl
 AC_REQUIRE([AC_LTDL_OBJDIR])dnl
 AC_REQUIRE([AC_LTDL_DLPREOPEN])dnl
 AC_REQUIRE([AC_LTDL_DLLIB])dnl
-AC_REQUIRE([AC_LTDL_SYMBOL_USCORE])dnl
+AC_REQUIRE([AC_LTDL_DLSYM_USCORE])dnl
 ])
 
 AC_DEFUN(AC_LTDL_ENABLE_INSTALL,
@@ -1192,7 +1192,6 @@ fi
 rm -rf conftest*
 ])
 AC_MSG_RESULT($ac_cv_sys_symbol_underscore)
-AC_LTDL_DLSYM_USCORE
 ])
 
 AC_DEFUN(AC_LTDL_DLSYM_USCORE,
Index: libjava/testsuite/Makefile.am
--- libjava/testsuite/Makefile.am	2001/04/04 23:38:53	1.2
+++ libjava/testsuite/Makefile.am	2001/05/24 05:21:11
@@ -11,5 +11,5 @@ RUNTEST = `if [ -f $(top_srcdir)/../deja
 	       echo $(top_srcdir)/../dejagnu/runtest ; \
 	    else echo runtest; fi`
 
-RUNTESTFLAGS = @AM_RUNTESTFLAGS@
+RUNTESTFLAGS = @GCJ_RUNTESTFLAGS@
 
===================================================================
Index: libjava/testsuite/Makefile.in
--- libjava/testsuite/Makefile.in	2001/05/22 06:47:48	1.28
+++ libjava/testsuite/Makefile.in	2001/05/24 05:21:11
@@ -129,7 +129,7 @@ EXPECT = `if [ -f $(top_builddir)/../exp
 RUNTEST = `if [ -f $(top_srcdir)/../dejagnu/runtest ] ; then 	       echo $(top_srcdir)/../dejagnu/runtest ; 	    else echo runtest; fi`
 
 
-RUNTESTFLAGS = @AM_RUNTESTFLAGS@
+RUNTESTFLAGS = @GCJ_RUNTESTFLAGS@
 mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
 CONFIG_HEADER = ../include/config.h
 CONFIG_CLEAN_FILES = 
===================================================================
Index: libstdc++-v3/aclocal.m4
--- libstdc++-v3/aclocal.m4	2001/05/19 20:27:34	1.150
+++ libstdc++-v3/aclocal.m4	2001/05/24 05:21:11
@@ -31,101 +31,8 @@ AC_DEFUN(GLIBCPP_CONFIGURE, [
 
   AM_INIT_AUTOMAKE(libstdc++, 2.92)
 
-  # Never versions of autoconf add an underscore to these functions.
-  # Prevent future problems ...
-  ifdef([AC_PROG_CC_G],[],[define([AC_PROG_CC_G],defn([_AC_PROG_CC_G]))])
-  ifdef([AC_PROG_CC_GNU],[],[define([AC_PROG_CC_GNU],defn([_AC_PROG_CC_GNU]))])
-  ifdef([AC_PROG_CXX_G],[],[define([AC_PROG_CXX_G],defn([_AC_PROG_CXX_G]))])
-  ifdef([AC_PROG_CXX_GNU],[],[define([AC_PROG_CXX_GNU],defn([_AC_PROG_CXX_GNU]))])
-
-#  AC_PROG_CC
-
-# FIXME: We temporarily define our own version of AC_PROG_CC.  This is
-# copied from autoconf 2.12, but does not call AC_PROG_CC_WORKS.  We
-# are probably using a cross compiler, which will not be able to fully
-# link an executable.  This should really be fixed in autoconf
-# itself.
-
-AC_DEFUN(LIB_AC_PROG_CC,
-[AC_BEFORE([$0], [AC_PROG_CPP])dnl
-dnl Fool anybody using AC_PROG_CC.
-AC_PROVIDE([AC_PROG_CC])
-AC_CHECK_PROG(CC, gcc, gcc)
-if test -z "$CC"; then
-  AC_CHECK_PROG(CC, cc, cc, , , /usr/ucb/cc)
-  test -z "$CC" && AC_MSG_ERROR([no acceptable cc found in \$PATH])
-fi
-
-AC_PROG_CC_GNU
-
-if test $ac_cv_prog_gcc = yes; then
-  GCC=yes
-dnl Check whether -g works, even if CFLAGS is set, in case the package
-dnl plays around with CFLAGS (such as to build both debugging and
-dnl normal versions of a library), tasteless as that idea is.
-  ac_test_CFLAGS="${CFLAGS+set}"
-  ac_save_CFLAGS="$CFLAGS"
-  CFLAGS=
-  AC_PROG_CC_G
-  if test "$ac_test_CFLAGS" = set; then
-    CFLAGS="$ac_save_CFLAGS"
-  elif test $ac_cv_prog_cc_g = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-O2"
-  fi
-else
-  GCC=
-  test "${CFLAGS+set}" = set || CFLAGS="-g"
-fi
-])
-
-LIB_AC_PROG_CC
-
-# Can't just call these here as g++ requires libstc++ to be built....
-#  AC_PROG_CXX
-
-# Likewise for AC_PROG_CXX.
-AC_DEFUN(LIB_AC_PROG_CXX,
-[AC_BEFORE([$0], [AC_PROG_CXXCPP])dnl
-dnl Fool anybody using AC_PROG_CXX.
-AC_PROVIDE([AC_PROG_CXX])
-# Use glibcpp_CXX so that we do not cause CXX to be cached with the
-# flags that come in CXX while configuring libstdc++.  They're different
-# from those used for all other target libraries.  If CXX is set in
-# the environment, respect that here.
-glibcpp_CXX=$CXX
-AC_CHECK_PROGS(glibcpp_CXX, $CCC c++ g++ gcc CC cxx cc++, gcc)
-AC_SUBST(glibcpp_CXX)
-CXX=$glibcpp_CXX
-test -z "$glibcpp_CXX" && AC_MSG_ERROR([no acceptable c++ found in \$PATH])
-
-AC_PROG_CXX_GNU
-
-if test $ac_cv_prog_gxx = yes; then
-  GXX=yes
-dnl Check whether -g works, even if CXXFLAGS is set, in case the package
-dnl plays around with CXXFLAGS (such as to build both debugging and
-dnl normal versions of a library), tasteless as that idea is.
-  ac_test_CXXFLAGS="${CXXFLAGS+set}"
-  ac_save_CXXFLAGS="$CXXFLAGS"
-  CXXFLAGS=
-  AC_PROG_CXX_G
-  if test "$ac_test_CXXFLAGS" = set; then
-    CXXFLAGS="$ac_save_CXXFLAGS"
-  elif test $ac_cv_prog_cxx_g = yes; then
-    CXXFLAGS="-g -O2"
-  else
-    CXXFLAGS="-O2"
-  fi
-else
-  GXX=
-  test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
-fi
-])
-
-LIB_AC_PROG_CXX
-
+  AC_PROG_CC
+  AC_PROG_CXX
   AC_CHECK_TOOL(AS, as)
   AC_CHECK_TOOL(AR, ar)
   AC_CHECK_TOOL(RANLIB, ranlib, ranlib-not-found-in-path-error)
===================================================================
Index: zlib/aclocal.m4
--- zlib/aclocal.m4	2001/05/13 22:31:24	1.4
+++ zlib/aclocal.m4	2001/05/24 05:21:12
@@ -10,46 +10,6 @@ dnl but WITHOUT ANY WARRANTY, to the ext
 dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
 dnl PARTICULAR PURPOSE.
 
-# FIXME: We temporarily define our own version of AC_PROG_CC.  This is
-# copied from autoconf 2.12, but does not call AC_PROG_CC_WORKS.  We
-# are probably using a cross compiler, which will not be able to fully
-# link an executable.  This should really be fixed in autoconf
-# itself.
-
-AC_DEFUN(LIB_AC_PROG_CC,
-[AC_BEFORE([$0], [AC_PROG_CPP])dnl
-dnl Fool anybody using AC_PROG_CC.
-AC_PROVIDE([AC_PROG_CC])
-AC_CHECK_PROG(CC, gcc, gcc)
-if test -z "$CC"; then
-  AC_CHECK_PROG(CC, cc, cc, , , /usr/ucb/cc)
-  test -z "$CC" && AC_MSG_ERROR([no acceptable cc found in \$PATH])
-fi
-
-AC_PROG_CC_GNU
-
-if test $ac_cv_prog_gcc = yes; then
-  GCC=yes
-dnl Check whether -g works, even if CFLAGS is set, in case the package
-dnl plays around with CFLAGS (such as to build both debugging and
-dnl normal versions of a library), tasteless as that idea is.
-  ac_test_CFLAGS="${CFLAGS+set}"
-  ac_save_CFLAGS="$CFLAGS"
-  CFLAGS=
-  AC_PROG_CC_G
-  if test "$ac_test_CFLAGS" = set; then
-    CFLAGS="$ac_save_CFLAGS"
-  elif test $ac_cv_prog_cc_g = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-O2"
-  fi
-else
-  GCC=
-  test "${CFLAGS+set}" = set || CFLAGS="-g"
-fi
-])
-
 sinclude(../libtool.m4)
 dnl The lines below arrange for aclocal not to bring libtool.m4
 dnl AM_PROG_LIBTOOL into aclocal.m4, while still arranging for automake
===================================================================
Index: zlib/configure.in
--- zlib/configure.in	2001/05/13 22:31:24	1.10
+++ zlib/configure.in	2001/05/24 05:21:12
@@ -47,7 +47,7 @@ AC_ARG_ENABLE(multilib,
 AC_ARG_WITH(system-zlib,
 [  --with-system-zlib      use installed libz])
 
-LIB_AC_PROG_CC
+AC_PROG_CC
 # We need AC_EXEEXT to keep automake happy in cygnus mode.  However,
 # at least currently, we never actually build a program, so we never
 # need to use $(EXEEXT).  Moreover, the test for EXEEXT normally


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]