diff options
Diffstat (limited to 'sys-devel/gcc-apple')
-rw-r--r-- | sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild index 1b20668b569d..22cbde635fe1 100644 --- a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild +++ b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r2.ebuild @@ -110,7 +110,7 @@ src_prepare() { epatch "${FILESDIR}"/${P}-darwin14.patch # bootstrapping might fail with host provided gcc on 10.4/x86 - if ! is_crosscompile && ! echo "int main(){return 0;}" | gcc -o "${T}"/foo \ + if ! is_crosscompile && ! echo "int main(){return 0;}" | $(tc-getCC) -o "${T}"/foo \ -mdynamic-no-pic -x c - >/dev/null 2>&1; then einfo "-mdynamic-no-pic doesn't work - disabling..." @@ -121,6 +121,14 @@ src_prepare() { || die "Failed to rewrite $XD" fi + if [[ ${CHOST} == powerpc*-darwin* ]] && \ + ! echo "int main(){return 0;}" | \ + $(tc-getCC) -o "${T}"/foo -no-cpp-precomp -x c - >/dev/null 2>&1; + then + einfo "-no-cpp-precomp not supported by compiler - disabling ..." + sed -i -e 's/-no-cpp-precomp//' configure.in configure || die + fi + epatch "${FILESDIR}"/${P}-perl-5.18.patch epatch "${FILESDIR}"/${PN}-4.2.1-prefix-search-dirs-r1.patch |