aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorMike Stump <mrs@apple.com>2006-11-17 06:48:01 +0000
committerMike Stump <mrs@gcc.gnu.org>2006-11-17 06:48:01 +0000
commit80c85ca2871defbcb6e6c03e27b15d7b6432c535 (patch)
treed90cad857cdc7befcd4cafdeb04e5648285d0b52 /gcc
parent36b15ad0dc8c471bbe053131e48ab3ec49aa7009 (diff)
downloadgcc-80c85ca2871defbcb6e6c03e27b15d7b6432c535.zip
gcc-80c85ca2871defbcb6e6c03e27b15d7b6432c535.tar.gz
gcc-80c85ca2871defbcb6e6c03e27b15d7b6432c535.tar.bz2
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
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog10
-rw-r--r--gcc/config.gcc8
-rw-r--r--gcc/config/darwin.h5
-rw-r--r--gcc/config/darwin9.h20
-rw-r--r--gcc/config/i386/darwin.h7
-rw-r--r--gcc/doc/install.texi9
6 files changed, 50 insertions, 9 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 3f94517..8a74dde 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -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
diff --git a/gcc/config.gcc b/gcc/config.gcc
index 6fd1a31..bdf280c 100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -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"
diff --git a/gcc/config/darwin.h b/gcc/config/darwin.h
index a518a2c..c0f9c86 100644
--- a/gcc/config/darwin.h
+++ b/gcc/config/darwin.h
@@ -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"
diff --git a/gcc/config/darwin9.h b/gcc/config/darwin9.h
new file mode 100644
index 0000000..ef9890a
--- /dev/null
+++ b/gcc/config/darwin9.h
@@ -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}}}}}}}}}}}}"
diff --git a/gcc/config/i386/darwin.h b/gcc/config/i386/darwin.h
index 5f61a7c..cf47943 100644
--- a/gcc/config/i386/darwin.h
+++ b/gcc/config/i386/darwin.h
@@ -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. */
diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
index d7ff340..b135a52 100644
--- a/gcc/doc/install.texi
+++ b/gcc/doc/install.texi
@@ -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 />