1 |
Hi,
|
2 |
|
3 |
Francois Bissey <francois.bissey@×××××××××××××.nz> writes:
|
4 |
|
5 |
> Very much like the bootstrapping described in LFS and in line with |
6 |
> the way IBM does things for its “advanced toolchain” for power7/8. |
7 |
> I actually have an alternate toolchain provided by IBM the last one |
8 |
> for SLES11 provides glibc-2.17+gcc-4.8.5+. gcc is patched to find ld64.so.1 |
9 |
> in the right place _and_ a rpath is added at the spec level also. |
10 |
> Anyway gcc/config/rs6000 is a bit more complicated than the i386 one |
11 |
> and for some reasons bits are missed by the sed line: |
12 |
> grep "_DYNAMIC_LINKER." gcc/config/rs6000/linux64.h |
13 |
> #define GLIBC_DYNAMIC_LINKER32 "/shared/work_no_backup/ppc64-prefix/lib/ld.so.1" |
14 |
> #define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv1:/lib64/ld64.so.1;:/lib64/ld64.so.2}” <== |
15 |
> #define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv2:/lib64/ld64.so.2;:/lib64/ld64.so.1}” <== |
16 |
> #define UCLIBC_DYNAMIC_LINKER32 "/shared/work_no_backup/ppc64-prefix/lib/ld-uClibc.so.0" |
17 |
> #define UCLIBC_DYNAMIC_LINKER64 "/shared/work_no_backup/ppc64-prefix/lib/ld64-uClibc.so.0" |
18 |
> #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}" |
19 |
> #define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}" |
20 |
> #define GNU_USER_DYNAMIC_LINKER32 \ |
21 |
> CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32) |
22 |
> #define GNU_USER_DYNAMIC_LINKER64 \ |
23 |
> CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64) |
24 |
> -dynamic-linker " GNU_USER_DYNAMIC_LINKER32 "}}" |
25 |
> -dynamic-linker " GNU_USER_DYNAMIC_LINKER64 "}}” |
26 |
> That explains a lot. |
27 |
|
28 |
Yeah, the present sed phrase
|
29 |
"s,(_DYNAMIC_LINKER.*\")(/lib),\1${EPREFIX}\2," does not capture
|
30 |
|
31 |
#define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv1:/lib64/ld64.so.1;:/lib64/ld64.so.2}”
|
32 |
|
33 |
We should write it
|
34 |
|
35 |
"/_DYNAMIC_LINKER/s,([\":])(/lib),\1${EPREFIX}\2,g"
|
36 |
|
37 |
instead probably.
|
38 |
|
39 |
> My -dumpspecs from the advanced toolchain has |
40 |
> /opt/at7.0%{mabi=elfv2:/lib64/ld64.so.2;:/lib64/ld64.so.1} I will try |
41 |
> to fix this, thanks for pointer, I was wondering where the gcc hack |
42 |
> was. |
43 |
|
44 |
You can hack it manually by using the specs file. Or use a better sed
|
45 |
phrase.
|
46 |
|
47 |
Yours,
|
48 |
Benda |