aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack Howarth <howarth.at.gcc@gmail.com>2015-05-05 18:06:49 +0000
committerMike Stump <mikestump@comcast.net>2015-05-05 18:06:49 +0000
commite43e40d1ded200fc09acb46d1e222962f3f3155a (patch)
treec428e359f9f6c37b3985552e66baf3d1b38bcfa3
parent3bbe88bdaa92291c921dce0c6340f7d65ae06ee3 (diff)
2015-05-05 Jack Howarth <howarth.at.gcc@gmail.com>
* config.gcc: Use darwin9.h, darwin10.h and darwin12.h on darwin12 and later. * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Add file to pass -rdynamic on darwin12 and later. * config/darwin.opt (rdynamic): Add. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@222822 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog8
-rw-r--r--gcc/config.gcc5
-rw-r--r--gcc/config/darwin.opt3
-rw-r--r--gcc/config/darwin12.h27
4 files changed, 42 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 07944aae2ff..cb15b529a2c 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,11 @@
+2015-05-05 Jack Howarth <howarth.at.gcc@gmail.com>
+
+ * config.gcc: Use darwin9.h, darwin10.h and darwin12.h
+ on darwin12 and later.
+ * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Add
+ file to pass -rdynamic on darwin12 and later.
+ * config/darwin.opt (rdynamic): Add.
+
2015-05-05 Uros Bizjak <ubizjak@gmail.com>
* doc/extend.texi (C Extensions): Update menu for moved Variable
diff --git a/gcc/config.gcc b/gcc/config.gcc
index f21421b1670..243e899a9ea 100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -605,9 +605,12 @@ case ${target} in
*-*-darwin9*)
tm_file="${tm_file} darwin9.h"
;;
- *-*-darwin[12][0-9]*)
+ *-*-darwin[1][01]*)
tm_file="${tm_file} darwin9.h darwin10.h"
;;
+ *-*-darwin[1][2-9]* | *-*-darwin[2][0-9]*)
+ tm_file="${tm_file} darwin9.h darwin10.h darwin12.h"
+ ;;
esac
tm_file="${tm_file} ${cpu_type}/darwin.h"
tm_p_file="${tm_p_file} darwin-protos.h"
diff --git a/gcc/config/darwin.opt b/gcc/config/darwin.opt
index 34ca5a922dd..5ab0e5cfdfd 100644
--- a/gcc/config/darwin.opt
+++ b/gcc/config/darwin.opt
@@ -155,6 +155,9 @@ Driver
pthread
Driver
+rdynamic
+Driver
+
seg_addr_table
Driver Separate Alias(Zseg_addr_table)
diff --git a/gcc/config/darwin12.h b/gcc/config/darwin12.h
new file mode 100644
index 00000000000..fdc1d0d4caf
--- /dev/null
+++ b/gcc/config/darwin12.h
@@ -0,0 +1,27 @@
+/* Target definitions for Darwin (Mac OS X) systems.
+ Copyright (C) 2009-2015 Free Software Foundation, Inc.
+ Contributed by Jack Howarth <howarth.at.gcc@gmail.com>.
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 3, or (at your option)
+any later version.
+
+GCC is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING3. If not see
+<http://www.gnu.org/licenses/>. */
+
+#undef LINK_GCC_C_SEQUENCE_SPEC
+#define LINK_GCC_C_SEQUENCE_SPEC \
+"%:version-compare(>= 10.6 mmacosx-version-min= -no_compact_unwind) \
+ %{rdynamic:-export_dynamic} %{!static:%{!static-libgcc: \
+ %:version-compare(>= 10.6 mmacosx-version-min= -lSystem) } } \
+ %{fno-pic|fno-PIC|fno-pie|fno-PIE|fapple-kext|mkernel|static|mdynamic-no-pic: \
+ %:version-compare(>= 10.7 mmacosx-version-min= -no_pie) } %G %L"