summaryrefslogtreecommitdiff
path: root/gcc/aclocal.m4
diff options
context:
space:
mode:
authorkcook <kcook@138bc75d-0d04-0410-961f-82ee72b054a4>2004-09-22 11:21:21 +0000
committerkcook <kcook@138bc75d-0d04-0410-961f-82ee72b054a4>2004-09-22 11:21:21 +0000
commit524a54cf87441bb4ba6676aff72494c0c1ceb7eb (patch)
tree84a0524e4466f8b47ca5606f7664d553cfa89887 /gcc/aclocal.m4
parentee08696532a0e1dd57a5d309d969643a2744a89b (diff)
downloadgcc-524a54cf87441bb4ba6676aff72494c0c1ceb7eb.tar.gz
gcc/
2004-09-22 Kelley Cook <kcook@gcc.gnu.org> * aclocal.m4: Import AM_PROG_CC_C_O and AM_AUX_DIR_EXPAND. * configure.ac: Call AM_PROG_CC_C_O instead of AC_PROG_CC_C_O. Create build and doc directories along with the language directories. Don't create doc directory separately. * configure: Regenerate. * Makefile.in: Create all object and executables files built with the build compiler in a build/ directory. (genobjnames): Add missing build objects. (STAGESTUFF): Don't stage the gen* programs. (ggc-none.o): Define dependencies for the target compiler. (build-print-rtl.o): Rename to build/print-rtl.o. (build-errors.o): Rename to build/errors.o. (build-varray.o): Rename to build/varray.o. (maintainerclean): Delete the contents of the build directory. ($(genobjs): %.o): Explicitly use -o. (build/insn-conditions.o): Delete specfic rule to use generic rule. (build/gengtype-lex.o): Likewise. (build/gengtype-yacc.o): Likewise. (build/gcov-iov.o): Likewise. gcc/java 2004-09-22 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Revert the gcc-none.o change. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@87854 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/aclocal.m4')
-rw-r--r--gcc/aclocal.m4102
1 files changed, 102 insertions, 0 deletions
diff --git a/gcc/aclocal.m4 b/gcc/aclocal.m4
index ba49bf42dd3..ec6bcc266b0 100644
--- a/gcc/aclocal.m4
+++ b/gcc/aclocal.m4
@@ -676,3 +676,105 @@ AC_DEFUN([AM_LC_MESSAGES],
[Define if your <locale.h> file defines LC_MESSAGES.])
fi
])
+
+# AM_PROG_CC_C_O
+# --------------
+# Like AC_PROG_CC_C_O, but changed for automake.
+
+# Copyright (C) 1999, 2000, 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+AC_DEFUN([AM_PROG_CC_C_O],
+[AC_REQUIRE([AC_PROG_CC_C_O])dnl
+AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
+# FIXME: we rely on the cache variable name because
+# there is no other way.
+set dummy $CC
+ac_cc=`echo $[2] | sed ['s/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/']`
+if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" != yes"; then
+ # Losing compiler, so override with the script.
+ # FIXME: It is wrong to rewrite CC.
+ # But if we don't then we get into trouble of one sort or another.
+ # A longer-term fix would be to have automake use am__CC in this case,
+ # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
+ CC="$am_aux_dir/compile $CC"
+fi
+])
+
+# AM_AUX_DIR_EXPAND
+
+# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
+# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
+# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
+#
+# Of course, Automake must honor this variable whenever it calls a
+# tool from the auxiliary directory. The problem is that $srcdir (and
+# therefore $ac_aux_dir as well) can be either absolute or relative,
+# depending on how configure is run. This is pretty annoying, since
+# it makes $ac_aux_dir quite unusable in subdirectories: in the top
+# source directory, any form will work fine, but in subdirectories a
+# relative path needs to be adjusted first.
+#
+# $ac_aux_dir/missing
+# fails when called from a subdirectory if $ac_aux_dir is relative
+# $top_srcdir/$ac_aux_dir/missing
+# fails if $ac_aux_dir is absolute,
+# fails when called from a subdirectory in a VPATH build with
+# a relative $ac_aux_dir
+#
+# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
+# are both prefixed by $srcdir. In an in-source build this is usually
+# harmless because $srcdir is `.', but things will broke when you
+# start a VPATH build or use an absolute $srcdir.
+#
+# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
+# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
+# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
+# and then we would define $MISSING as
+# MISSING="\${SHELL} $am_aux_dir/missing"
+# This will work as long as MISSING is not called from configure, because
+# unfortunately $(top_srcdir) has no meaning in configure.
+# However there are other variables, like CC, which are often used in
+# configure, and could therefore not use this "fixed" $ac_aux_dir.
+#
+# Another solution, used here, is to always expand $ac_aux_dir to an
+# absolute PATH. The drawback is that using absolute paths prevent a
+# configured tree to be moved without reconfiguration.
+
+AC_DEFUN([AM_AUX_DIR_EXPAND],
+[dnl Rely on autoconf to set up CDPATH properly.
+AC_PREREQ([2.50])dnl
+# expand $ac_aux_dir to an absolute path
+am_aux_dir=`cd $ac_aux_dir && pwd`
+])