darwin.h (LINK_COMMAND_SPEC): Don't do dwarf stuff on pre-darwin9 system, unless the user asks for it directly.

* config/darwin.h (LINK_COMMAND_SPEC): Don't do dwarf stuff on
	pre-darwin9 system, unless the user asks for it directly.
	(PREFERRED_DEBUGGING_TYPE): Likewise.
	* config/i386/darwin.h (PREFERRED_DEBUGGING_TYPE): Likewise.
	* config.gcc: Add suppport for darwin9.h.
	* config/darwin9.h: Add.
	* doc/install.texi (Specific): Clarify darwin documentation.

From-SVN: r118917
This commit is contained in:
Mike Stump 2006-11-17 06:48:01 +00:00 committed by Mike Stump
parent 36b15ad0dc
commit 80c85ca287
6 changed files with 50 additions and 9 deletions

View File

@ -1,3 +1,13 @@
2006-11-16 Mike Stump <mrs@apple.com>
* config/darwin.h (LINK_COMMAND_SPEC): Don't do dwarf stuff on
pre-darwin9 system, unless the user asks for it directly.
(PREFERRED_DEBUGGING_TYPE): Likewise.
* config/i386/darwin.h (PREFERRED_DEBUGGING_TYPE): Likewise.
* config.gcc: Add suppport for darwin9.h.
* config/darwin9.h: Add.
* doc/install.texi (Specific): Clarify darwin documentation.
2006-11-16 Richard Earnshaw <rearnsha@arm.com>
* arm.h (CONSTANT_ALIGNMENT): Don't over-align strings when

View File

@ -366,7 +366,13 @@ esac
# Common parts for widely ported systems.
case ${target} in
*-*-darwin*)
tm_file="${tm_file} darwin.h ${cpu_type}/darwin.h"
tm_file="${tm_file} darwin.h"
case ${target} in
*-*-darwin9*)
tm_file="${tm_file} darwin9.h"
;;
esac
tm_file="${tm_file} ${cpu_type}/darwin.h"
tm_p_file="${tm_p_file} darwin-protos.h"
tmake_file="t-darwin ${cpu_type}/t-darwin t-slibgcc-darwin"
target_gtfiles="\$(srcdir)/config/darwin.c"

View File

@ -241,7 +241,7 @@ extern GTY(()) int darwin_ms_struct;
%{!A:%{!nostdlib:%{!nostartfiles:%E}}} %{T*} %{F*} }}}}}}}\n\
%{!fdump=*:%{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:\
%{.c|.cc|.C|.cpp|.c++|.CPP|.m|.mm: \
%{g*:%{!gstabs*:%{!gnone: dsymutil %{o*:%*}%{!o:a.out}}}}}}}}}}}}"
%{gdwarf-2:%{!gstabs*:%{!gnone: dsymutil %{o*:%*}%{!o:a.out}}}}}}}}}}}}"
#ifdef TARGET_SYSTEM_ROOT
#define LINK_SYSROOT_SPEC \
@ -395,9 +395,8 @@ extern GTY(()) int darwin_ms_struct;
#define DBX_DEBUGGING_INFO 1
/* Prefer DWARF2. */
#define DWARF2_DEBUGGING_INFO
#define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
#define DEBUG_FRAME_SECTION "__DWARF,__debug_frame,regular,debug"
#define DEBUG_INFO_SECTION "__DWARF,__debug_info,regular,debug"

20
gcc/config/darwin9.h Normal file
View File

@ -0,0 +1,20 @@
/* Prefer DWARF2. */
#undef PREFERRED_DEBUGGING_TYPE
#define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
#define DARWIN_PREFER_DWARF
#undef LINK_COMMAND_SPEC
#define LINK_COMMAND_SPEC "\
%{!fdump=*:%{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:\
%{!Zdynamiclib:%(linker)}%{Zdynamiclib:/usr/bin/libtool} \
%l %X %{d} %{s} %{t} %{Z} \
%{!Zdynamiclib:%{A} %{e*} %{m} %{N} %{n} %{r} %{u*} %{x} %{z}} \
%{o*}%{!o:-o a.out} \
%{!A:%{!nostdlib:%{!nostartfiles:%S}}} \
%{L*} %{fopenmp:%:include(libgomp.spec)%(link_gomp)} \
%(link_libgcc) %o %{fprofile-arcs|fprofile-generate|coverage:-lgcov} \
%{!nostdlib:%{!nodefaultlibs:%(link_ssp) %G %L}} \
%{!A:%{!nostdlib:%{!nostartfiles:%E}}} %{T*} %{F*} }}}}}}}\n\
%{!fdump=*:%{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:\
%{.c|.cc|.C|.cpp|.c++|.CPP|.m|.mm: \
%{g*:%{!gstabs*:%{!gnone: dsymutil %{o*:%*}%{!o:a.out}}}}}}}}}}}}"

View File

@ -187,6 +187,13 @@ extern void darwin_x86_file_end (void);
SUBTARGET_C_COMMON_OVERRIDE_OPTIONS; \
} while (0)
/* Darwin on x86_64 uses dwarf-2 by default. Pre-darwin9 32-bit
compiles defaut to stabs+. darwin9+ defaults to dwarf-2. */
#ifndef DARWIN_PREFER_DWARF
#undef PREFERRED_DEBUGGING_TYPE
#define PREFERRED_DEBUGGING_TYPE (TARGET_64BIT ? DWARF2_DEBUG : DBX_DEBUG)
#endif
/* Darwin uses the standard DWARF register numbers but the default
register numbers for STABS. Fortunately for 64-bit code the
default and the standard are the same. */

View File

@ -3611,11 +3611,10 @@ binaries are available at
@uref{http://developer.apple.com/darwin/projects/compiler/} (free
registration required).
This version of GCC requires at least cctools-590.7.
The version of GCC shipped by Apple typically includes a number of
extensions not available in a standard GCC release. These extensions
are generally for backwards compatibility and best avoided.
This version of GCC requires at least cctools-590.36. The
cctools-590.36 package referenced from
@uref{http://gcc.gnu.org/ml/gcc/2006-03/msg00507.html} will not work
on systems older than 10.3.9 (aka darwin7.9.0).
@html
<hr />