diff options
author | DJ Delorie <dj@redhat.com> | 2006-05-01 16:57:20 -0400 |
---|---|---|
committer | DJ Delorie <dj@gcc.gnu.org> | 2006-05-01 16:57:20 -0400 |
commit | 2d5bc016adb900a9fcbaade5f78eeaf4e0ae494d (patch) | |
tree | d7dec8e90275b123a2a3f7d5deb08469c901c1f2 /gcc | |
parent | 2ce798794df8e1edc87b59e36417e2691a25d579 (diff) | |
download | gcc-2d5bc016adb900a9fcbaade5f78eeaf4e0ae494d.zip gcc-2d5bc016adb900a9fcbaade5f78eeaf4e0ae494d.tar.gz gcc-2d5bc016adb900a9fcbaade5f78eeaf4e0ae494d.tar.bz2 |
vec.c: Include bconfig.h when appropriate.
* vec.c: Include bconfig.h when appropriate.
* Makefile.in (build/vec.o): Adjust dependencies.
* mkconfig.sh: Make sure config.h isn't used for build machine
compiles.
From-SVN: r113432
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/Makefile.in | 2 | ||||
-rw-r--r-- | gcc/mkconfig.sh | 10 | ||||
-rw-r--r-- | gcc/vec.c | 9 |
4 files changed, 25 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index c91f262..bec4dc9 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2006-05-01 DJ Delorie <dj@redhat.com> + + * vec.c: Include bconfig.h when appropriate. + * Makefile.in (build/vec.o): Adjust dependencies. + * mkconfig.sh: Make sure config.h isn't used for build machine + compiles. + 2006-05-01 Zdenek Dvorak <dvorakz@suse.cz> * tree-into-ssa.c (phis_to_rewrite, blocks_with_phis_to_rewrite): New diff --git a/gcc/Makefile.in b/gcc/Makefile.in index 1833128..4239808 100644 --- a/gcc/Makefile.in +++ b/gcc/Makefile.in @@ -2927,7 +2927,7 @@ build/read-rtl.o: read-rtl.c $(BCONFIG_H) $(SYSTEM_H) coretypes.h \ $(GTM_H) $(RTL_BASE_H) $(OBSTACK_H) $(HASHTAB_H) gensupport.h build/rtl.o: rtl.c $(BCONFIG_H) coretypes.h $(GTM_H) $(SYSTEM_H) \ $(RTL_H) $(REAL_H) $(GGC_H) errors.h -build/vec.o : vec.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) coretypes.h vec.h \ +build/vec.o : vec.c $(BCONFIG_H) $(SYSTEM_H) $(TREE_H) coretypes.h vec.h \ $(GGC_H) toplev.h build/gencondmd.o : build/gencondmd.c $(BCONFIG_H) $(SYSTEM_H) \ coretypes.h $(GTM_H) insn-constants.h $(RTL_H) $(TM_P_H) \ diff --git a/gcc/mkconfig.sh b/gcc/mkconfig.sh index 78c9a99..9ffd200 100644 --- a/gcc/mkconfig.sh +++ b/gcc/mkconfig.sh @@ -1,6 +1,6 @@ #! /bin/sh -# Copyright (C) 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc. # This file is part of GCC. # GCC is free software; you can redistribute it and/or modify @@ -41,6 +41,14 @@ header_guard=GCC_`echo ${output} | sed -e ${hg_sed_expr}` echo "#ifndef ${header_guard}" >> ${output}T echo "#define ${header_guard}" >> ${output}T +# A special test to ensure that build-time files don't blindly use +# config.h. +if test x"$output" == x"config.h"; then + echo "#ifdef GENERATOR_FILE" >> ${output}T + echo "#error config.h is for the host, not build, machine." >> ${output}T + echo "#endif" >> ${output}T +fi + # Define TARGET_CPU_DEFAULT if the system wants one. # This substitutes for lots of *.h files. if [ "$TARGET_CPU_DEFAULT" != "" ]; then @@ -1,5 +1,5 @@ /* Vector API for GNU compiler. - Copyright (C) 2004, 2005 Free Software Foundation, Inc. + Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. Contributed by Nathan Sidwell <nathan@codesourcery.com> This file is part of GCC. @@ -19,7 +19,14 @@ along with GCC; see the file COPYING. If not, write to the Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/* This file is compiled twice: once for the generator programs + once for the compiler. */ +#ifdef GENERATOR_FILE +#include "bconfig.h" +#else #include "config.h" +#endif + #include "system.h" #include "ggc.h" #include "vec.h" |