Building shared object file for an SH target
Yann Magnin
yann.magnin@epitech.eu
Thu Mar 19 15:25:40 GMT 2020
Hi everyone,
Recently I try to generate shared object files in SuperH-4 using a custom sh-elf-gcc (build options below) but the `-shared` flags seems to have no effect because the linker indicate `cannot find entry symbol start` and the generated file is of type `ELF 32-bit MSB executable, Renesas SH, version 1 (SYSV), statically linked, not stripped`.
I tried to compile 'gcc 9.3.0' and 'binutils 2.34.0' using '--enable-shared':
* ../gcc-9.3.0/configure --prefix=$HOME/opt/sh-elf-2.34-9.3.0 --target=sh3eb-elf --with-multilib-list=m3,m4-nofpu --enable-languages=c,c++ --enable-shared --without-headers --with-newlib --disable-nls --program-prefix=sh-elf-
* ../binutils-2.34/configure --prefix=$HOME/opt/sh-elf-2.34-9.3.0 --target=sh3eb-elf --enable-shared --with-multilib-list=m3,m4-nofpu --disable-nls --program-prefix=sh-elf-
But I have the same result.
I also tried with '--enable-host-shared' and nothing.
How can I do to enable shared file generation with gcc ?
Any insight would be deeply appreciated!
Cheers,
Yann
More information about the Gcc-help
mailing list