1 |
On 23 Jun 2004, Ned Ludd wrote: |
2 |
|
3 |
> Side Note Off Topic: |
4 |
> |
5 |
> Both arm & mips fail a simple |
6 |
> echo 'int main() { return 0; }' > main.c |
7 |
> gcc -o main main.c -pie |
8 |
> |
9 |
> /usr/lib/libc_nonshared.a(elf-init.oS)(.text+0x38): In function |
10 |
> `__libc_csu_init': |
11 |
> : undefined reference to `__init_array_start' |
12 |
> /usr/lib/libc_nonshared.a(elf-init.oS)(.text+0x3c): In function |
13 |
> `__libc_csu_init': |
14 |
> : undefined reference to `__init_array_end' |
15 |
> |
16 |
> I think these symbols are provided by linker scripts. |
17 |
> Seen anything floating around where others have run into the same thing? |
18 |
> If so recall the solution? |
19 |
|
20 |
Is the used gcc surely patched for pie? |
21 |
gcc (3.3.3+branch,3.4.0) does not support pie for arm (see my upstream |
22 |
pie patches for arm). at least gcc-3.3.3-piepatches-8.7.5, |
23 |
gcc-3.4.0-piepatches-8.7.6.1 have to be used. |
24 |
check if the startfile/endfile sections mention pie. |
25 |
|
26 |
mips could be another problem, because it defaults already to PIC. |
27 |
|
28 |
could you run gcc -v and send the result for both cases? |
29 |
|
30 |
Peter |
31 |
|
32 |
|
33 |
-- |
34 |
gentoo-embedded@g.o mailing list |