diff options
author | Iain Sandoe <iain@sandoe.co.uk> | 2019-07-24 19:59:22 +0000 |
---|---|---|
committer | Iain Sandoe <iains@gcc.gnu.org> | 2019-07-24 19:59:22 +0000 |
commit | e34616747028ebeb0be867dc6a23682539bfab60 (patch) | |
tree | 9367ad2f575db466c3e4d353009c73c8afe02ef5 /gcc/config/i386 | |
parent | 856bb3ef935edfa315bf4552a25493f11ee949b6 (diff) | |
download | gcc-e34616747028ebeb0be867dc6a23682539bfab60.zip gcc-e34616747028ebeb0be867dc6a23682539bfab60.tar.gz gcc-e34616747028ebeb0be867dc6a23682539bfab60.tar.bz2 |
[Darwin] Partial reversion of 273749.
We still need to cater for pr80556, for the single-arch case.
2019-07-24 Iain Sandoe <iain@sandoe.co.uk>
gcc/
PR bootstrap/87030
* config/i386/darwin.h (REAL_LIBGCC_SPEC): Revert r273749.
From-SVN: r273768
Diffstat (limited to 'gcc/config/i386')
-rw-r--r-- | gcc/config/i386/darwin.h | 29 |
1 files changed, 28 insertions, 1 deletions
diff --git a/gcc/config/i386/darwin.h b/gcc/config/i386/darwin.h index d9c8f20..84afedc 100644 --- a/gcc/config/i386/darwin.h +++ b/gcc/config/i386/darwin.h @@ -39,6 +39,33 @@ along with GCC; see the file COPYING3. If not see #endif #endif +/* WORKAROUND pr80556: + For x86_64 Darwin10 and later, the unwinder is in libunwind (redirected + from libSystem). This doesn't use the keymgr (see keymgr.c) and therefore + the calls that libgcc makes to obtain the KEYMGR_GCC3_DW2_OBJ_LIST are not + updated to include new images, and might not even be valid for a single + image. + Therefore, for 64b exes at least, we must use the libunwind implementation, + even when static-libgcc is specified. We put libSystem first so that + unwinder symbols are satisfied from there. + We default to 64b for single-arch builds, so apply this unconditionally. */ +#undef REAL_LIBGCC_SPEC +#define REAL_LIBGCC_SPEC \ + "%{static-libgcc|static: \ + %:version-compare(>= 10.6 mmacosx-version-min= -lSystem) \ + -lgcc_eh -lgcc; \ + shared-libgcc|fexceptions|fgnu-runtime: \ + %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_s.10.4) \ + %:version-compare(>< 10.5 10.6 mmacosx-version-min= -lgcc_s.10.5) \ + %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_ext.10.4) \ + %:version-compare(>= 10.5 mmacosx-version-min= -lgcc_ext.10.5) \ + -lgcc ; \ + :%:version-compare(>< 10.3.9 10.5 mmacosx-version-min= -lgcc_s.10.4) \ + %:version-compare(>< 10.5 10.6 mmacosx-version-min= -lgcc_s.10.5) \ + %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_ext.10.4) \ + %:version-compare(>= 10.5 mmacosx-version-min= -lgcc_ext.10.5) \ + -lgcc }" + /* Size of the Obj-C jump buffer. */ #define OBJC_JBLEN ((TARGET_64BIT) ? ((9 * 2) + 3 + 16) : (18)) @@ -120,9 +147,9 @@ along with GCC; see the file COPYING3. If not see %{mpc64:crtprec64.o%s} \ %{mpc80:crtprec80.o%s}" TM_DESTRUCTOR +/* We default to x86_64 for single-arch builds, bi-arch overrides. */ #define DARWIN_ARCH_SPEC "x86_64" -/* We default to x86_64 for single-arch builds, bi-arch overrides. */ #undef SUBTARGET_EXTRA_SPECS #define SUBTARGET_EXTRA_SPECS \ DARWIN_EXTRA_SPECS \ |