iris5gas.h (DWARF2_DEBUGGING_INFO): Define.

* config/mips/iris5gas.h (DWARF2_DEBUGGING_INFO): Define.
	(PREFERRED_DEBUGGING_TYPE): Use DWARF2_DEBUG.
	(LINK_SPEC): Define.
	(STARTFILE_SPEC): Define.
	(ENDFILE_SPEC): Define.

	* config/mips/iris6-o32.h (LINK_SPEC): Move ...
	* config/mips/iris6-o32-as.h (LINK_SPEC): ... here.

	* config/mips/iris6-o32-gas.h: New file.
	* config.gcc (mips-sgi-irix6*o32): Use it.

	* config/mips/t-iris5-gas: New file.
	* config.gcc (mips-sgi-irix6*o32, mips-sgi-irix5*): Use it.

From-SVN: r55596
This commit is contained in:
Rainer Orth 2002-07-19 21:58:12 +00:00 committed by Rainer Orth
parent 75aef48add
commit 59267987db
7 changed files with 91 additions and 18 deletions

View File

@ -1,3 +1,20 @@
2002-07-19 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
* config/mips/iris5gas.h (DWARF2_DEBUGGING_INFO): Define.
(PREFERRED_DEBUGGING_TYPE): Use DWARF2_DEBUG.
(LINK_SPEC): Define.
(STARTFILE_SPEC): Define.
(ENDFILE_SPEC): Define.
* config/mips/iris6-o32.h (LINK_SPEC): Move ...
* config/mips/iris6-o32-as.h (LINK_SPEC): ... here.
* config/mips/iris6-o32-gas.h: New file.
* config.gcc (mips-sgi-irix6*o32): Use it.
* config/mips/t-iris5-gas: New file.
* config.gcc (mips-sgi-irix6*o32, mips-sgi-irix5*): Use it.
2002-07-19 Neil Booth <neil@daikokuya.co.uk>
* cppexp.c (ALWAYS_EVAL): Remove.

View File

@ -1748,11 +1748,12 @@ mcore-*-pe*)
mips-sgi-irix6*o32) # SGI System V.4., IRIX 6, O32 ABI
if test x$gas = xyes
then
tm_file="mips/iris5.h mips/iris5gas.h"
tm_file="mips/iris5.h mips/iris5gas.h mips/iris6-o32-gas.h"
if test x$stabs = xyes
then
tm_file="${tm_file} dbx.h"
fi
tmake_file=mips/t-iris5-gas
else
tm_file="mips/iris5.h mips/iris6-o32-as.h"
tmake_file=mips/t-iris5-as
@ -1826,6 +1827,7 @@ mips-sgi-irix5*) # SGI System V.4., IRIX 5
then
tm_file="${tm_file} dbx.h"
fi
tmake_file=mips/t-iris5-gas
else
tm_file=mips/iris5.h
tmake_file=mips/t-iris5-as

View File

@ -2,14 +2,44 @@
/* Enable debugging. */
#define DBX_DEBUGGING_INFO
#define DWARF2_DEBUGGING_INFO
#define SDB_DEBUGGING_INFO
#define MIPS_DEBUGGING_INFO
#define PREFERRED_DEBUGGING_TYPE SDB_DEBUG
#define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
/* GNU as does handle DWARF2 directives. */
#undef DWARF2_UNWIND_INFO
#define DWARF2_UNWIND_INFO 1
/* Override iris5.h version to invoke [cd]tors and register eh frame
information. */
#undef LINK_SPEC
#define LINK_SPEC "\
%{G*} %{EB} %{EL} %{mips1} %{mips2} %{mips3} \
%{bestGnum} %{shared} %{non_shared} \
%{call_shared} %{no_archive} %{exact_version} \
%{static: -non_shared} \
%{!static: \
%{!shared:%{!non_shared:%{!call_shared: -call_shared -no_unresolved}}}} \
%{rpath} -init __do_global_ctors -fini __do_global_dtors \
%{shared:-hidden_symbol __do_global_ctors,__do_global_ctors_1,__do_global_dtors} \
-_SYSTYPE_SVR4"
/* Override iris5.h versions to include crtbegin.o and crtend.o. */
#undef STARTFILE_SPEC
#define STARTFILE_SPEC "\
%{!static: \
%{!shared:%{pg:gcrt1.o%s}%{!pg:%{p:mcrt1.o%s libprof1.a%s}%{!p:crt1.o%s}}}} \
%{static: \
%{pg:gcrt1.o%s} \
%{!pg:%{p:/usr/lib/nonshared/mcrt1.o%s libprof1.a%s} \
%{!p:/usr/lib/nonshared/crt1.o%s}}} \
crtbegin.o%s"
#undef ENDFILE_SPEC
#define ENDFILE_SPEC "crtend.o%s %{!shared:crtn.o%s}"
/* Irix 5 does not have some strange restrictions that Irix 3 had. */
#undef SET_FILE_NUMBER
#define SET_FILE_NUMBER() ++num_source_filenames

View File

@ -11,3 +11,19 @@
#define SUBTARGET_ASM_OPTIMIZING_SPEC "\
%{noasmopt:-O0} \
%{!noasmopt:%{O|O1|O2|O3:-O2}}"
/* Enforce use of O32 linker, irrespective of SGI_ABI environment variable
and machine type (e.g., R8000 systems default to -64). Copied from
iris5.h, only adding -32. The default options -call_shared -no_unresolved
are only passed if not invoked with -r. */
#undef LINK_SPEC
#define LINK_SPEC "\
%{G*} %{EB} %{EL} %{mips1} %{mips2} %{mips3} \
%{bestGnum} %{shared} %{non_shared} \
%{call_shared} %{no_archive} %{exact_version} \
%{static: -non_shared} \
%{!static: \
%{!shared:%{!non_shared:%{!call_shared:%{!r: -call_shared -no_unresolved}}}}} \
%{rpath} \
-_SYSTYPE_SVR4 \
-32"

View File

@ -0,0 +1,19 @@
/* Definitions of target machine for GNU compiler, for MIPS running IRIX 6
(O32 ABI) using the GNU assembler. */
/* Enforce use of O32 linker, irrespective of SGI_ABI environment variable
and machine type (e.g., R8000 systems default to -64). Copied from
iris5gas.h, only adding -32. The default options -call_shared
-no_unresolved are only passed if not invoked with -r. */
#undef LINK_SPEC
#define LINK_SPEC "\
%{G*} %{EB} %{EL} %{mips1} %{mips2} %{mips3} \
%{bestGnum} %{shared} %{non_shared} \
%{call_shared} %{no_archive} %{exact_version} \
%{static: -non_shared} \
%{!static: \
%{!shared:%{!non_shared:%{!call_shared:%{!r: -call_shared -no_unresolved}}}}} \
%{rpath} -init __do_global_ctors -fini __do_global_dtors \
%{shared:-hidden_symbol __do_global_ctors,__do_global_ctors_1,__do_global_dtors} \
-_SYSTYPE_SVR4 \
-32"

View File

@ -66,19 +66,3 @@
to -mips1 if no ISA is specified. */
#undef SUBTARGET_ASM_SPEC
#define SUBTARGET_ASM_SPEC "-32 %{!mips*:-mips2}"
/* Enforce use of O32 linker, irrespective of SGI_ABI environment variable
and machine type (e.g., R8000 systems default to -64). Copied from
iris5.h, only adding -32. The default options -call_shared -no_unresolved
are only passed if not invoked with -r. */
#undef LINK_SPEC
#define LINK_SPEC "\
%{G*} %{EB} %{EL} %{mips1} %{mips2} %{mips3} \
%{bestGnum} %{shared} %{non_shared} \
%{call_shared} %{no_archive} %{exact_version} \
%{static: -non_shared} \
%{!static: \
%{!shared:%{!non_shared:%{!call_shared:%{!r: -call_shared -no_unresolved}}}}} \
%{rpath} \
-_SYSTYPE_SVR4 \
-32"

View File

@ -0,0 +1,5 @@
# For svr4 we build crtbegin.o and crtend.o which serve to add begin and
# end labels to the .ctors and .dtors section when we link using gcc.
EXTRA_MULTILIB_PARTS=crtbegin.o crtend.o
CRTSTUFF_T_CFLAGS=-g1