diff options
-rw-r--r-- | gcc/ChangeLog | 11 | ||||
-rw-r--r-- | gcc/Makefile.in | 5 | ||||
-rwxr-xr-x | gcc/configure | 67 | ||||
-rw-r--r-- | gcc/configure.in | 9 | ||||
-rwxr-xr-x | gcc/fixinc/mkfixinc.sh | 2 |
5 files changed, 58 insertions, 36 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 25ecc061659..02775219dec 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,14 @@ +2003-04-11 Alexandre Oliva <aoliva@redhat.com> + + * Makefile.in (fixinc.sh): Pass BUILD_LIBERTY as LIBERTY to + mkfixinc.sh. + * fixinc/mkfixinc.sh (defs): Add LIBERTY. + * configure.in (STMP_FIXINC, STMP_FIXPROTO): Don't disable on + build != host sysrooted builds. + * configure.in (SYSTEM_HEADER_DIR): Make sure it contains + TARGET_SYSTEM_ROOT even on sysrooted natives. + * configure: Rebuilt. + 2003-04-10 Zack Weinberg <zack@codesourcery.com> * c-decl.c (struct binding_level): Add shadowed_tags and diff --git a/gcc/Makefile.in b/gcc/Makefile.in index 6e02f20c9e8..6b9e64fe4f3 100644 --- a/gcc/Makefile.in +++ b/gcc/Makefile.in @@ -2490,8 +2490,9 @@ fixinc.sh: $(FIXINCSRCDIR)/mkfixinc.sh $(FIXINCSRCDIR)/fixincl.c \ $(FIXINCSRCDIR)/server.h $(FIXINCSRCDIR)/inclhack.def specs.ready (MAKE="$(MAKE)"; srcdir=`cd $(srcdir)/fixinc && ${PWD}` ; \ CC="$(BUILD_CC)"; CFLAGS="$(BUILD_CFLAGS)"; LDFLAGS="$(BUILD_LDFLAGS)"; \ - WARN_CFLAGS="$(WARN_CFLAGS)"; \ - export MAKE srcdir CC CFLAGS LDFLAGS WARN_CFLAGS; cd ./fixinc && \ + WARN_CFLAGS="$(WARN_CFLAGS)"; LIBERTY=`pwd`/"$(BUILD_LIBIBERTY)"; \ + export MAKE srcdir CC CFLAGS LDFLAGS WARN_CFLAGS LIBERTY; \ + cd ./fixinc && \ $(SHELL) $${srcdir}/mkfixinc.sh $(build_canonical) $(target)) .PHONY: install-gcc-tooldir diff --git a/gcc/configure b/gcc/configure index 95f259acebb..e42c97df27c 100755 --- a/gcc/configure +++ b/gcc/configure @@ -2434,7 +2434,7 @@ fi # Find some useful tools -for ac_prog in mawk gawk nawk awk +for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 @@ -7319,6 +7319,9 @@ then | powerpc*-*-*,powerpc64*-*-*) CROSS="$CROSS -DNATIVE_CROSS" ;; esac +elif test "x$TARGET_SYSTEM_ROOT" != x; then + # This is just $(TARGET_SYSTEM_ROOT)$(NATIVE_SYSTEM_HEADER_DIR) + SYSTEM_HEADER_DIR='$(CROSS_SYSTEM_HEADER_DIR)' fi # If this is a cross-compiler that does not @@ -7356,8 +7359,10 @@ then BUILD_CC='$(CC_FOR_BUILD)' BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD) $(XCFLAGS)' - STMP_FIXINC= - STMP_FIXPROTO= + if test "x$TARGET_SYSTEM_ROOT" = x; then + STMP_FIXINC= + STMP_FIXPROTO= + fi fi # Expand extra_headers to include complete path. @@ -7407,7 +7412,7 @@ fi # build->target assembler and hope that it will have the same features # as the host->target assembler we'll be using. echo $ac_n "checking what assembler to use""... $ac_c" 1>&6 -echo "configure:7411: checking what assembler to use" >&5 +echo "configure:7416: checking what assembler to use" >&5 in_tree_gas=no gcc_cv_as= gcc_cv_gas_major_version= @@ -7516,7 +7521,7 @@ esac # build->target linker and hope that it will have the same features # as the host->target linker we'll be using. echo $ac_n "checking what linker to use""... $ac_c" 1>&6 -echo "configure:7520: checking what linker to use" >&5 +echo "configure:7525: checking what linker to use" >&5 in_tree_ld=no gcc_cv_ld= gcc_cv_gld_major_version= @@ -7615,7 +7620,7 @@ esac # Figure out what nm we will be using. echo $ac_n "checking what nm to use""... $ac_c" 1>&6 -echo "configure:7619: checking what nm to use" >&5 +echo "configure:7624: checking what nm to use" >&5 if test -x nm$host_exeext; then gcc_cv_nm=./nm$host_exeext elif test "x$program_prefix" != xNONE; then @@ -7627,7 +7632,7 @@ echo "$ac_t""$gcc_cv_nm" 1>&6 # Figure out what objdump we will be using. echo $ac_n "checking what objdump to use""... $ac_c" 1>&6 -echo "configure:7631: checking what objdump to use" >&5 +echo "configure:7636: checking what objdump to use" >&5 if test -x objdump$host_exeext; then gcc_cv_objdump=./objdump$host_exeext elif test "x$program_prefix" != xNONE; then @@ -7639,7 +7644,7 @@ echo "$ac_t""$gcc_cv_objdump" 1>&6 # Figure out what assembler alignment features are present. echo $ac_n "checking assembler alignment features""... $ac_c" 1>&6 -echo "configure:7643: checking assembler alignment features" >&5 +echo "configure:7648: checking assembler alignment features" >&5 gcc_cv_as_alignment_features=none if test $in_tree_gas = yes; then # Gas version 2.6 and later support for .balign and .p2align. @@ -7700,7 +7705,7 @@ fi echo "$ac_t""$gcc_cv_as_alignment_features" 1>&6 echo $ac_n "checking assembler subsection support""... $ac_c" 1>&6 -echo "configure:7704: checking assembler subsection support" >&5 +echo "configure:7709: checking assembler subsection support" >&5 gcc_cv_as_subsections=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -7749,7 +7754,7 @@ fi echo "$ac_t""$gcc_cv_as_subsections" 1>&6 echo $ac_n "checking assembler weak support""... $ac_c" 1>&6 -echo "configure:7753: checking assembler weak support" >&5 +echo "configure:7758: checking assembler weak support" >&5 gcc_cv_as_weak=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -7779,7 +7784,7 @@ fi echo "$ac_t""$gcc_cv_as_weak" 1>&6 echo $ac_n "checking assembler hidden support""... $ac_c" 1>&6 -echo "configure:7783: checking assembler hidden support" >&5 +echo "configure:7788: checking assembler hidden support" >&5 gcc_cv_as_hidden=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -7860,7 +7865,7 @@ esac echo $ac_n "checking assembler leb128 support""... $ac_c" 1>&6 -echo "configure:7864: checking assembler leb128 support" >&5 +echo "configure:7869: checking assembler leb128 support" >&5 gcc_cv_as_leb128=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -7914,7 +7919,7 @@ fi echo "$ac_t""$gcc_cv_as_leb128" 1>&6 echo $ac_n "checking assembler eh_frame optimization""... $ac_c" 1>&6 -echo "configure:7918: checking assembler eh_frame optimization" >&5 +echo "configure:7923: checking assembler eh_frame optimization" >&5 gcc_cv_as_eh_frame=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -8004,7 +8009,7 @@ fi echo "$ac_t""$gcc_cv_as_eh_frame" 1>&6 echo $ac_n "checking assembler section merging support""... $ac_c" 1>&6 -echo "configure:8008: checking assembler section merging support" >&5 +echo "configure:8013: checking assembler section merging support" >&5 gcc_cv_as_shf_merge=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -8036,7 +8041,7 @@ fi echo "$ac_t""$gcc_cv_as_shf_merge" 1>&6 echo $ac_n "checking assembler thread-local storage support""... $ac_c" 1>&6 -echo "configure:8040: checking assembler thread-local storage support" >&5 +echo "configure:8045: checking assembler thread-local storage support" >&5 gcc_cv_as_tls=no conftest_s= tls_first_major= @@ -8183,7 +8188,7 @@ case "$target" in # All TARGET_ABI_OSF targets. alpha*-*-osf* | alpha*-*-linux* | alpha*-*-*bsd*) echo $ac_n "checking assembler supports explicit relocations""... $ac_c" 1>&6 -echo "configure:8187: checking assembler supports explicit relocations" >&5 +echo "configure:8192: checking assembler supports explicit relocations" >&5 if eval "test \"`echo '$''{'gcc_cv_as_explicit_relocs'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8236,7 +8241,7 @@ EOF ;; sparc*-*-*) echo $ac_n "checking assembler .register pseudo-op support""... $ac_c" 1>&6 -echo "configure:8240: checking assembler .register pseudo-op support" >&5 +echo "configure:8245: checking assembler .register pseudo-op support" >&5 if eval "test \"`echo '$''{'gcc_cv_as_register_pseudo_op'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8264,7 +8269,7 @@ EOF fi echo $ac_n "checking assembler supports -relax""... $ac_c" 1>&6 -echo "configure:8268: checking assembler supports -relax" >&5 +echo "configure:8273: checking assembler supports -relax" >&5 if eval "test \"`echo '$''{'gcc_cv_as_relax_opt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8292,7 +8297,7 @@ EOF fi echo $ac_n "checking assembler and linker support unaligned pc related relocs""... $ac_c" 1>&6 -echo "configure:8296: checking assembler and linker support unaligned pc related relocs" >&5 +echo "configure:8301: checking assembler and linker support unaligned pc related relocs" >&5 if eval "test \"`echo '$''{'gcc_cv_as_sparc_ua_pcrel'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8319,7 +8324,7 @@ EOF fi echo $ac_n "checking assembler and linker support unaligned pc related relocs against hidden symbols""... $ac_c" 1>&6 -echo "configure:8323: checking assembler and linker support unaligned pc related relocs against hidden symbols" >&5 +echo "configure:8328: checking assembler and linker support unaligned pc related relocs against hidden symbols" >&5 if eval "test \"`echo '$''{'gcc_cv_as_sparc_ua_pcrel_hidden'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8359,7 +8364,7 @@ EOF fi echo $ac_n "checking for assembler offsetable %lo() support""... $ac_c" 1>&6 -echo "configure:8363: checking for assembler offsetable %lo() support" >&5 +echo "configure:8368: checking for assembler offsetable %lo() support" >&5 if eval "test \"`echo '$''{'gcc_cv_as_offsetable_lo10'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8398,7 +8403,7 @@ EOF i[34567]86-*-* | x86_64-*-*) echo $ac_n "checking assembler instructions""... $ac_c" 1>&6 -echo "configure:8402: checking assembler instructions" >&5 +echo "configure:8407: checking assembler instructions" >&5 gcc_cv_as_instructions= if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -8432,7 +8437,7 @@ EOF echo "$ac_t""$gcc_cv_as_instructions" 1>&6 echo $ac_n "checking assembler GOTOFF in data directives""... $ac_c" 1>&6 -echo "configure:8436: checking assembler GOTOFF in data directives" >&5 +echo "configure:8441: checking assembler GOTOFF in data directives" >&5 gcc_cv_as_gotoff_in_data=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -8466,7 +8471,7 @@ EOF ia64*-*-*) echo $ac_n "checking assembler supports ltoffx and ldxmov""... $ac_c" 1>&6 -echo "configure:8470: checking assembler supports ltoffx and ldxmov" >&5 +echo "configure:8475: checking assembler supports ltoffx and ldxmov" >&5 if eval "test \"`echo '$''{'gcc_cv_as_ltoffx_ldxmov_relocs'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -8511,7 +8516,7 @@ EOF esac echo $ac_n "checking assembler dwarf2 debug_line support""... $ac_c" 1>&6 -echo "configure:8515: checking assembler dwarf2 debug_line support" >&5 +echo "configure:8520: checking assembler dwarf2 debug_line support" >&5 gcc_cv_as_dwarf2_debug_line=no # ??? Not all targets support dwarf2 debug_line, even within a version # of gas. Moreover, we need to emit a valid instruction to trigger any @@ -8573,7 +8578,7 @@ fi echo "$ac_t""$gcc_cv_as_dwarf2_debug_line" 1>&6 echo $ac_n "checking assembler --gdwarf2 support""... $ac_c" 1>&6 -echo "configure:8577: checking assembler --gdwarf2 support" >&5 +echo "configure:8582: checking assembler --gdwarf2 support" >&5 gcc_cv_as_gdwarf2_flag=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -8607,7 +8612,7 @@ fi echo "$ac_t""$gcc_cv_as_gdwarf2_flag" 1>&6 echo $ac_n "checking assembler --gstabs support""... $ac_c" 1>&6 -echo "configure:8611: checking assembler --gstabs support" >&5 +echo "configure:8616: checking assembler --gstabs support" >&5 gcc_cv_as_gstabs_flag=no if test $in_tree_gas = yes ; then if test $gcc_cv_gas_major_version -eq 2 \ @@ -8640,7 +8645,7 @@ fi echo "$ac_t""$gcc_cv_as_gstabs_flag" 1>&6 echo $ac_n "checking linker read-only and read-write section mixing""... $ac_c" 1>&6 -echo "configure:8644: checking linker read-only and read-write section mixing" >&5 +echo "configure:8649: checking linker read-only and read-write section mixing" >&5 gcc_cv_ld_ro_rw_mix=unknown if test $in_tree_ld = yes ; then if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 10 -o "$gcc_cv_gld_major_version" -gt 2 && grep 'EMUL = elf' ../ld/Makefile > /dev/null; then @@ -8678,7 +8683,7 @@ fi echo "$ac_t""$gcc_cv_ld_ro_rw_mix" 1>&6 echo $ac_n "checking linker PT_GNU_EH_FRAME support""... $ac_c" 1>&6 -echo "configure:8682: checking linker PT_GNU_EH_FRAME support" >&5 +echo "configure:8687: checking linker PT_GNU_EH_FRAME support" >&5 gcc_cv_ld_eh_frame_hdr=no if test $in_tree_ld = yes ; then if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 12 -o "$gcc_cv_gld_major_version" -gt 2 && grep 'EMUL = elf' ../ld/Makefile > /dev/null; then @@ -8702,7 +8707,7 @@ echo "$ac_t""$gcc_cv_ld_eh_frame_hdr" 1>&6 case "$target" in mips*-*-*) echo $ac_n "checking whether libgloss uses STARTUP directives consistently""... $ac_c" 1>&6 -echo "configure:8706: checking whether libgloss uses STARTUP directives consistently" >&5 +echo "configure:8711: checking whether libgloss uses STARTUP directives consistently" >&5 gcc_cv_mips_libgloss_startup=no gcc_cv_libgloss_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/libgloss if test "x$exec_prefix" = xNONE; then @@ -8907,7 +8912,7 @@ fi echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 -echo "configure:8911: checking whether to enable maintainer-specific portions of Makefiles" >&5 +echo "configure:8916: checking whether to enable maintainer-specific portions of Makefiles" >&5 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. if test "${enable_maintainer_mode+set}" = set; then enableval="$enable_maintainer_mode" diff --git a/gcc/configure.in b/gcc/configure.in index b48bd22bf77..ebbe37f658f 100644 --- a/gcc/configure.in +++ b/gcc/configure.in @@ -1368,6 +1368,9 @@ then | powerpc*-*-*,powerpc64*-*-*) CROSS="$CROSS -DNATIVE_CROSS" ;; esac +elif test "x$TARGET_SYSTEM_ROOT" != x; then + # This is just $(TARGET_SYSTEM_ROOT)$(NATIVE_SYSTEM_HEADER_DIR) + SYSTEM_HEADER_DIR='$(CROSS_SYSTEM_HEADER_DIR)' fi # If this is a cross-compiler that does not @@ -1405,8 +1408,10 @@ then BUILD_CC='$(CC_FOR_BUILD)' BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD) $(XCFLAGS)' - STMP_FIXINC= - STMP_FIXPROTO= + if test "x$TARGET_SYSTEM_ROOT" = x; then + STMP_FIXINC= + STMP_FIXPROTO= + fi fi # Expand extra_headers to include complete path. diff --git a/gcc/fixinc/mkfixinc.sh b/gcc/fixinc/mkfixinc.sh index 8bd00d5cd62..042ed820af1 100755 --- a/gcc/fixinc/mkfixinc.sh +++ b/gcc/fixinc/mkfixinc.sh @@ -119,7 +119,7 @@ fi # OK. We gotta make the thing. # make and install either the binary or the default script -defs="SHELL=\"$SHELL\" CC=\"$CC\" CFLAGS=\"$CFLAGS\" LDFLAGS=\"$LDFLAGS\"" +defs="SHELL=\"$SHELL\" CC=\"$CC\" CFLAGS=\"$CFLAGS\" LDFLAGS=\"$LDFLAGS\" LIBERTY=\"$LIBERTY\"" cmd="$MAKE ${defs} install-bin" echo $cmd eval $cmd |