Skip to content

Commit

Permalink
Move libgcc_tm_file to toplevel libgcc
Browse files Browse the repository at this point in the history
	gcc:
	* configure.ac (libgcc_tm_file_list, libgcc_tm_include_list):
	Remove.
	* configure: Regenerate.
	* Makefile.in (libgcc_tm_file_list, libgcc_tm_include_list): Remove.
	(TM_H): Remove libgcc_tm.h, $(libgcc_tm_file_list).
	(libgcc_tm.h, cs-libgcc_tm.h): Remove.
	(clean): Remove libgcc_tm.h
	* mkconfig.sh: Don't include libgcc_tm.h in tm.h.
	* config.gcc (libgcc_tm_file): Remove.
	(arm*-*-linux*): Remove libgcc_tm_file for arm*-*-linux-*eabi.
	(arm*-*-uclinux*): Remove libgcc_tm_file for arm*-*-uclinux*eabi.
	(arm*-*-eabi*, arm*-*-symbianelf*): Remove libgcc_tm_file.
	(avr-*-rtems*): Likewise.
	(avr-*-*): Likewise.
	(frv-*-elf): Likewise.
	(frv-*-*linux*): Likewise.
	(h8300-*-rtems*): Likewise.
	(h8300-*-elf*): Likewise.
	(i[34567]86-*-darwin*): Likewise.
	(x86_64-*-darwin*): Likewise.
	(rx-*-elf*): Likewise.
	(tic6x-*-elf): Likewise.
	(tic6x-*-uclinux): Likewise.
	(i[34567]86-*-linux*, x86_64-*-linux*): Likewise.

	libgcc:
	* configure.ac (tm_file_): New variable.
	Determine from tm_file.
	(tm_file, tm_defines): Substitute.
	* configure: Regenerate.
	* mkheader.sh: New file.
	* Makefile.in (clean): Remove libgcc_tm.h.
	($(objects)): Depend on libgcc_tm.h.
	(libgcc_tm_defines, libgcc_tm_file): New variables.
	(libgcc_tm.h, libgcc_tm.stamp): New targets.
	($(libgcc-objects), $(libgcc-s-objects), $(libgcc-eh-objects))
	($(libgcov-objects), $(libunwind-objects), $(libunwind-s-objects))
	($(extra-parts)): Depend on libgcc_tm.h.
	* config.host (tm_defines, tm_file): New variable.
	(arm*-*-linux*): Set tm_file for arm*-*-linux-*eabi.
	(arm*-*-uclinux*): Set tm_file for arm*-*-uclinux*eabi.
	(arm*-*-eabi*, arm*-*-symbianelf*): Set tm_file.
	(avr-*-rtems*): Likewise.
	(avr-*-*): Likewise.
	(frv-*-elf): Likewise.
	(frv-*-*linux*): Likewise.
	(h8300-*-rtems*): Likewise.
	(h8300-*-elf*): Likewise.
	(i[34567]86-*-darwin*): Likewise.
	(x86_64-*-darwin*): Likewise.
	(rx-*-elf): Likewise.
	(tic6x-*-uclinux): Likewise.
	(tic6x-*-elf): Likewise.
	(i[34567]86-*-linux*, x86_64-*-linux*): Likewise.
	* config/alpha/gthr-posix.c: Include libgcc_tm.h.
	* config/i386/cygming-crtbegin.c: Likewise.
	* config/i386/cygming-crtend.c: Likewise.
	* config/ia64/fde-vms.c: Likewise.
	* config/ia64/unwind-ia64.c: Likewise.
	* config/libbid/bid_gcc_intrinsics.h: Likewise.
	* config/rs6000/darwin-fallback.c: Likewise.
	* config/stormy16/lib2funcs.c: Likewise.
	* config/xtensa/unwind-dw2-xtensa.c: Likewise.
	* crtstuff.c: Likewise.
	* dfp-bit.h: Likewise.
	* emutls.c: Likewise.
	* fixed-bit.c: Likewise.
	* fp-bit.c: Likewise.
	* generic-morestack-thread.c: Likewise.
	* generic-morestack.c: Likewise.
	* libgcc2.c: Likewise.
	* libgcov.c: Likewise.
	* unwind-dw2-fde-dip.c: Likewise.
	* unwind-dw2-fde.c: Likewise.
	* unwind-dw2.c: Likewise.
	* unwind-sjlj.c: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@180775 138bc75d-0d04-0410-961f-82ee72b054a4
  • Loading branch information
ro committed Nov 2, 2011
1 parent 4dc4ff4 commit 022a279
Show file tree
Hide file tree
Showing 34 changed files with 223 additions and 75 deletions.
28 changes: 28 additions & 0 deletions gcc/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,31 @@
2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Paolo Bonzini <bonzini@gnu.org>

* configure.ac (libgcc_tm_file_list, libgcc_tm_include_list):
Remove.
* configure: Regenerate.
* Makefile.in (libgcc_tm_file_list, libgcc_tm_include_list): Remove.
(TM_H): Remove libgcc_tm.h, $(libgcc_tm_file_list).
(libgcc_tm.h, cs-libgcc_tm.h): Remove.
(clean): Remove libgcc_tm.h
* mkconfig.sh: Don't include libgcc_tm.h in tm.h.
* config.gcc (libgcc_tm_file): Remove.
(arm*-*-linux*): Remove libgcc_tm_file for arm*-*-linux-*eabi.
(arm*-*-uclinux*): Remove libgcc_tm_file for arm*-*-uclinux*eabi.
(arm*-*-eabi*, arm*-*-symbianelf*): Remove libgcc_tm_file.
(avr-*-rtems*): Likewise.
(avr-*-*): Likewise.
(frv-*-elf): Likewise.
(frv-*-*linux*): Likewise.
(h8300-*-rtems*): Likewise.
(h8300-*-elf*): Likewise.
(i[34567]86-*-darwin*): Likewise.
(x86_64-*-darwin*): Likewise.
(rx-*-elf*): Likewise.
(tic6x-*-elf): Likewise.
(tic6x-*-uclinux): Likewise.
(i[34567]86-*-linux*, x86_64-*-linux*): Likewise.

2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>

* Makefile.in (LIBGCC2_DEBUG_CFLAGS LIBGCC2_CFLAGS)
Expand Down
13 changes: 2 additions & 11 deletions gcc/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -490,8 +490,6 @@ md_file=$(srcdir)/config/@md_file@
tm_file_list=@tm_file_list@
tm_include_list=@tm_include_list@
tm_defines=@tm_defines@
libgcc_tm_file_list=@libgcc_tm_file_list@
libgcc_tm_include_list=@libgcc_tm_include_list@
tm_p_file_list=@tm_p_file_list@
tm_p_include_list=@tm_p_include_list@
build_xm_file_list=@build_xm_file_list@
Expand Down Expand Up @@ -790,8 +788,7 @@ CONFIG_H = config.h $(host_xm_file_list)
TCONFIG_H = tconfig.h $(xm_file_list)
TM_P_H = tm_p.h $(tm_p_file_list)
GTM_H = tm.h $(tm_file_list) insn-constants.h
TM_H = $(GTM_H) libgcc_tm.h $(libgcc_tm_file_list) insn-flags.h \
$(OPTIONS_H)
TM_H = $(GTM_H) insn-flags.h $(OPTIONS_H)

# Variables for version information.
BASEVER := $(srcdir)/BASE-VER # 4.x.y
Expand Down Expand Up @@ -1599,7 +1596,6 @@ config.h: cs-config.h ; @true
bconfig.h: cs-bconfig.h ; @true
tconfig.h: cs-tconfig.h ; @true
tm.h: cs-tm.h ; @true
libgcc_tm.h: cs-libgcc_tm.h ; @true
tm_p.h: cs-tm_p.h ; @true

cs-config.h: Makefile
Expand All @@ -1622,11 +1618,6 @@ cs-tm.h: Makefile
HEADERS="$(tm_include_list)" DEFINES="$(tm_defines)" \
$(SHELL) $(srcdir)/mkconfig.sh tm.h

cs-libgcc_tm.h: Makefile
TARGET_CPU_DEFAULT="" \
HEADERS="$(libgcc_tm_include_list)" DEFINES="" \
$(SHELL) $(srcdir)/mkconfig.sh libgcc_tm.h

cs-tm_p.h: Makefile
TARGET_CPU_DEFAULT="" \
HEADERS="$(tm_p_include_list)" DEFINES="" \
Expand Down Expand Up @@ -4425,7 +4416,7 @@ clean: mostlyclean lang.clean
-rm -f libgcc.a libgcc_eh.a libgcov.a
-rm -f libgcc_s*
-rm -f libunwind*
-rm -f config.h tconfig.h bconfig.h tm_p.h tm.h libgcc_tm.h
-rm -f config.h tconfig.h bconfig.h tm_p.h tm.h
-rm -f options.c options.h optionlist
-rm -f cs-*
-rm -f doc/*.dvi
Expand Down
23 changes: 0 additions & 23 deletions gcc/config.gcc
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,6 @@
# build-directory files by prefixing them with "./".
# All other files should relative to $srcdir/config.
#
# libgcc_tm_file A list of target macro files used only for code
# built for the target, not the host. These files
# are relative to $srcdir/../libgcc/config and
# must not have the same names as files in
# $srcdir/config.
#
# tm_p_file Location of file with declarations for functions
# in $out_file.
#
Expand Down Expand Up @@ -223,7 +217,6 @@ target_has_targetcm=no
target_has_targetm_common=yes
tm_defines=
xm_defines=
libgcc_tm_file=
# Set this to force installation and use of collect2.
use_collect2=
# Set this to override the default target model.
Expand Down Expand Up @@ -831,7 +824,6 @@ arm*-*-linux*) # ARM GNU/Linux with ELF
case ${target} in
arm*-*-linux-*eabi)
tm_file="$tm_file arm/bpabi.h arm/linux-eabi.h"
libgcc_tm_file="$libgcc_tm_file arm/bpabi-lib.h"
tmake_file="$tmake_file arm/t-arm-elf arm/t-linux-eabi"
# Define multilib configuration for arm-linux-androideabi.
case ${target} in
Expand Down Expand Up @@ -859,7 +851,6 @@ arm*-*-uclinux*) # ARM ucLinux
case ${target} in
arm*-*-uclinux*eabi)
tm_file="$tm_file arm/bpabi.h arm/uclinux-eabi.h"
libgcc_tm_file="$libgcc_tm_file arm/bpabi-lib.h"
# The BPABI long long divmod functions return a 128-bit value in
# registers r0-r3. Correctly modeling that requires the use of
# TImode.
Expand All @@ -880,7 +871,6 @@ arm*-*-eabi* | arm*-*-symbianelf* )
need_64bit_hwint=yes
default_use_cxa_atexit=yes
tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/bpabi.h"
libgcc_tm_file="$libgcc_tm_file arm/bpabi-lib.h"
tmake_file="arm/t-arm arm/t-arm-elf"
case ${target} in
arm*-*-eabi*)
Expand All @@ -889,7 +879,6 @@ arm*-*-eabi* | arm*-*-symbianelf* )
;;
arm*-*-symbianelf*)
tm_file="${tm_file} arm/symbian.h"
libgcc_tm_file="$libgcc_tm_file arm/symbian-lib.h"
# We do not include t-bpabi for Symbian OS because the system
# provides its own implementation of the BPABI functions.
tmake_file="${tmake_file} arm/t-symbian"
Expand All @@ -913,14 +902,12 @@ arm*-wince-pe*)
;;
avr-*-rtems*)
tm_file="elfos.h avr/elf.h avr/avr.h dbxelf.h avr/rtems.h rtems.h newlib-stdint.h"
libgcc_tm_file="$libgcc_tm_file avr/avr-lib.h"
tmake_file="avr/t-avr t-rtems avr/t-rtems"
extra_gcc_objs="driver-avr.o avr-devices.o"
extra_objs="avr-devices.o avr-log.o"
;;
avr-*-*)
tm_file="elfos.h avr/elf.h avr/avr.h dbxelf.h newlib-stdint.h"
libgcc_tm_file="$libgcc_tm_file avr/avr-lib.h"
use_gcc_stdint=wrap
extra_gcc_objs="driver-avr.o avr-devices.o"
extra_objs="avr-devices.o avr-log.o"
Expand Down Expand Up @@ -983,13 +970,11 @@ fr30-*-elf)
;;
frv-*-elf)
tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
libgcc_tm_file="${libgcc_tm_file} frv/frv-abi.h"
tmake_file=frv/t-frv
;;
frv-*-*linux*)
tm_file="dbxelf.h elfos.h ${tm_file} \
gnu-user.h linux.h glibc-stdint.h frv/linux.h"
libgcc_tm_file="${libgcc_tm_file} frv/frv-abi.h"
tmake_file="${tmake_file} frv/t-frv frv/t-linux"
;;
moxie-*-elf)
Expand All @@ -1011,12 +996,10 @@ moxie-*-rtems*)
h8300-*-rtems*)
tmake_file="h8300/t-h8300 t-rtems h8300/t-rtems"
tm_file="h8300/h8300.h dbxelf.h elfos.h h8300/elf.h h8300/rtems.h rtems.h newlib-stdint.h"
libgcc_tm_file="$libgcc_tm_file h8300/h8300-lib.h"
;;
h8300-*-elf*)
tmake_file="h8300/t-h8300"
tm_file="h8300/h8300.h dbxelf.h elfos.h newlib-stdint.h h8300/elf.h"
libgcc_tm_file="$libgcc_tm_file h8300/h8300-lib.h"
;;
hppa*64*-*-linux*)
target_cpu_default="MASK_PA_11|MASK_PA_20"
Expand Down Expand Up @@ -1161,13 +1144,11 @@ i[34567]86-*-darwin*)
# Baseline choice for a machine that allows m64 support.
with_cpu=${with_cpu:-core2}
tmake_file="${tmake_file} t-slibgcc"
libgcc_tm_file="$libgcc_tm_file i386/darwin-lib.h"
;;
x86_64-*-darwin*)
with_cpu=${with_cpu:-core2}
tmake_file="${tmake_file} ${cpu_type}/t-darwin64 t-slibgcc"
tm_file="${tm_file} ${cpu_type}/darwin64.h"
libgcc_tm_file="$libgcc_tm_file i386/darwin-lib.h"
;;
i[34567]86-*-elf*)
tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h"
Expand Down Expand Up @@ -2119,7 +2100,6 @@ rs6000-ibm-aix[6789].* | powerpc-ibm-aix[6789].*)
;;
rx-*-elf*)
tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
libgcc_tm_file="${libgcc_tm_file} rx/rx-abi.h rx/rx-lib.h"
tmake_file="${tmake_file} rx/t-rx"
;;
s390-*-linux*)
Expand Down Expand Up @@ -2448,15 +2428,13 @@ spu-*-elf*)
tic6x-*-elf)
tm_file="elfos.h ${tm_file} c6x/elf-common.h c6x/elf.h"
tm_file="${tm_file} dbxelf.h tm-dwarf2.h newlib-stdint.h"
libgcc_tm_file="${libgcc_tm_file} c6x/c6x-abi.h"
tmake_file="c6x/t-c6x c6x/t-c6x-elf"
use_collect2=no
;;
tic6x-*-uclinux)
tm_file="elfos.h ${tm_file} gnu-user.h linux.h c6x/elf-common.h c6x/uclinux-elf.h"
tm_file="${tm_file} dbxelf.h tm-dwarf2.h glibc-stdint.h"
tm_file="${tm_file} ./sysroot-suffix.h"
libgcc_tm_file="${libgcc_tm_file} c6x/c6x-abi.h"
tmake_file="t-sysroot-suffix t-slibgcc"
tmake_file="${tmake_file} c6x/t-c6x c6x/t-c6x-elf c6x/t-c6x-uclinux"
use_collect2=no
Expand Down Expand Up @@ -2544,7 +2522,6 @@ esac
case ${target} in
i[34567]86-*-linux* | x86_64-*-linux*)
tmake_file="${tmake_file} i386/t-pmm_malloc i386/t-i386"
libgcc_tm_file="${libgcc_tm_file} i386/value-unwind.h"
;;
i[34567]86-*-* | x86_64-*-*)
tmake_file="${tmake_file} i386/t-gmm_malloc i386/t-i386"
Expand Down
15 changes: 2 additions & 13 deletions gcc/configure
Original file line number Diff line number Diff line change
Expand Up @@ -618,8 +618,6 @@ xm_include_list
xm_file_list
tm_p_include_list
tm_p_file_list
libgcc_tm_include_list
libgcc_tm_file_list
tm_defines
tm_include_list
tm_file_list
Expand Down Expand Up @@ -11789,13 +11787,6 @@ for f in $tm_file; do
esac
done

libgcc_tm_file_list=
libgcc_tm_include_list=
for f in $libgcc_tm_file; do
libgcc_tm_file_list="${libgcc_tm_file_list} \$(srcdir)/../libgcc/config/$f"
libgcc_tm_include_list="${libgcc_tm_include_list} ../libgcc/config/$f"
done

tm_p_file_list=
tm_p_include_list=
for f in $tm_p_file; do
Expand Down Expand Up @@ -18068,7 +18059,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
#line 18071 "configure"
#line 18062 "configure"
#include "confdefs.h"

#if HAVE_DLFCN_H
Expand Down Expand Up @@ -18174,7 +18165,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
#line 18177 "configure"
#line 18168 "configure"
#include "confdefs.h"

#if HAVE_DLFCN_H
Expand Down Expand Up @@ -27014,8 +27005,6 @@ fi








Expand Down
9 changes: 0 additions & 9 deletions gcc/configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -1715,13 +1715,6 @@ for f in $tm_file; do
esac
done

libgcc_tm_file_list=
libgcc_tm_include_list=
for f in $libgcc_tm_file; do
libgcc_tm_file_list="${libgcc_tm_file_list} \$(srcdir)/../libgcc/config/$f"
libgcc_tm_include_list="${libgcc_tm_include_list} ../libgcc/config/$f"
done

tm_p_file_list=
tm_p_include_list=
for f in $tm_p_file; do
Expand Down Expand Up @@ -4972,8 +4965,6 @@ AC_SUBST(thread_file)
AC_SUBST(tm_file_list)
AC_SUBST(tm_include_list)
AC_SUBST(tm_defines)
AC_SUBST(libgcc_tm_file_list)
AC_SUBST(libgcc_tm_include_list)
AC_SUBST(tm_p_file_list)
AC_SUBST(tm_p_include_list)
AC_SUBST(xm_file_list)
Expand Down
8 changes: 2 additions & 6 deletions gcc/mkconfig.sh
Original file line number Diff line number Diff line change
Expand Up @@ -89,19 +89,15 @@ if [ -n "$HEADERS" ]; then
fi

# If this is tm.h, now include insn-flags.h only if IN_GCC is defined
# but neither GENERATOR_FILE nor USED_FOR_TARGET is defined. Also
# include libgcc_tm.h if USED_FOR_TARGET is defined. (Much of this is
# temporary.)
# but neither GENERATOR_FILE nor USED_FOR_TARGET is defined. (Much of this
# is temporary.)

case $output in
tm.h )
cat >> ${output}T <<EOF
#if defined IN_GCC && !defined GENERATOR_FILE && !defined USED_FOR_TARGET
# include "insn-flags.h"
#endif
#ifdef USED_FOR_TARGET
# include "libgcc_tm.h"
#endif
EOF
;;
esac
Expand Down
53 changes: 53 additions & 0 deletions libgcc/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,56 @@
2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>

* configure.ac (tm_file_): New variable.
Determine from tm_file.
(tm_file, tm_defines): Substitute.
* configure: Regenerate.
* mkheader.sh: New file.
* Makefile.in (clean): Remove libgcc_tm.h.
($(objects)): Depend on libgcc_tm.h.
(libgcc_tm_defines, libgcc_tm_file): New variables.
(libgcc_tm.h, libgcc_tm.stamp): New targets.
($(libgcc-objects), $(libgcc-s-objects), $(libgcc-eh-objects))
($(libgcov-objects), $(libunwind-objects), $(libunwind-s-objects))
($(extra-parts)): Depend on libgcc_tm.h.
* config.host (tm_defines, tm_file): New variable.
(arm*-*-linux*): Set tm_file for arm*-*-linux-*eabi.
(arm*-*-uclinux*): Set tm_file for arm*-*-uclinux*eabi.
(arm*-*-eabi*, arm*-*-symbianelf*): Set tm_file.
(avr-*-rtems*): Likewise.
(avr-*-*): Likewise.
(frv-*-elf): Likewise.
(frv-*-*linux*): Likewise.
(h8300-*-rtems*): Likewise.
(h8300-*-elf*): Likewise.
(i[34567]86-*-darwin*): Likewise.
(x86_64-*-darwin*): Likewise.
(rx-*-elf): Likewise.
(tic6x-*-uclinux): Likewise.
(tic6x-*-elf): Likewise.
(i[34567]86-*-linux*, x86_64-*-linux*): Likewise.
* config/alpha/gthr-posix.c: Include libgcc_tm.h.
* config/i386/cygming-crtbegin.c: Likewise.
* config/i386/cygming-crtend.c: Likewise.
* config/ia64/fde-vms.c: Likewise.
* config/ia64/unwind-ia64.c: Likewise.
* config/libbid/bid_gcc_intrinsics.h: Likewise.
* config/rs6000/darwin-fallback.c: Likewise.
* config/stormy16/lib2funcs.c: Likewise.
* config/xtensa/unwind-dw2-xtensa.c: Likewise.
* crtstuff.c: Likewise.
* dfp-bit.h: Likewise.
* emutls.c: Likewise.
* fixed-bit.c: Likewise.
* fp-bit.c: Likewise.
* generic-morestack-thread.c: Likewise.
* generic-morestack.c: Likewise.
* libgcc2.c: Likewise.
* libgcov.c: Likewise.
* unwind-dw2-fde-dip.c: Likewise.
* unwind-dw2-fde.c: Likewise.
* unwind-dw2.c: Likewise.
* unwind-sjlj.c: Likewise.

2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>

* configure.ac: Include ../config/picflag.m4.
Expand Down
Loading

0 comments on commit 022a279

Please sign in to comment.