1 |
Hi, |
2 |
|
3 |
please de-keyword gcc-4.2.0 for "~ppc-aix", there is a problem with |
4 |
libstdc++[1]. Although this is for gcc-4.2.1, besides some gentoo-caused |
5 |
build error I've encountered exactly the same with gcc-4.2.0. |
6 |
|
7 |
[1] http://gcc.gnu.org/ml/gcc-help/2007-09/msg00100.html |
8 |
|
9 |
For the gentoo-caused build error: |
10 |
|
11 |
gcc knows it needs "-bbigtoc" linker flag. Unfortunately, gcc_do_make() |
12 |
(from toolchain.eclass) calls "emake 'LDFLAGS=${LDFLAGS}'", which wipes |
13 |
out the gcc-preset "-Wl,-bbigtoc", set from gcc-4.2.0/config/mh-ppc-aix: |
14 |
|
15 |
$ find gcc-4.2.0 -type f | xargs fgrep bbigtoc |
16 |
gcc-4.2.0/config/mh-ppc-aix:BOOT_LDFLAGS = -Wl,-bbigtoc |
17 |
gcc-4.2.0/config/mh-ppc-aix:LDFLAGS = `case $(CC) in *gcc*) echo -Wl,-bbigtoc ;; esac;` |
18 |
|
19 |
My fix to get gcc-4.2.0 compiled (remember: libstdc++ not working) on |
20 |
aix was to |
21 |
append-ldflags -Wl,-bbigtoc |
22 |
in src_compile() for "${CHOST} == *-aix*". |
23 |
|
24 |
But maybe this should be done more intelligent by extracting LDFLAGS |
25 |
from config/mh-ppc-aix ? |
26 |
|
27 |
I'm thinking here on sth. like this: |
28 |
|
29 |
CC=$(tc-getCC) make -s -f - -f ${S}/config/mh-ppc-aix getldflags <<EOF |
30 |
getldflags:; echo \$(LDFLAGS) |
31 |
EOF |
32 |
|
33 |
Thoughts ? |
34 |
|
35 |
Eventually gcc_do_make() should avoid passing LDFLAGS (and others) if |
36 |
not preset by ebuild (or user) ? |
37 |
|
38 |
/haubi/ |
39 |
|
40 |
-- |
41 |
gentoo-alt@g.o mailing list |