On 26/02/2019 19:01, Segher Boessenkool wrote:
Hi Arnaud,
On Tue, Feb 26, 2019 at 01:38:49PM +0000, BALARD Arnaud wrote:
When I do the "make build-verbose" I get the following error :
"PATH/openbios/arch/sparc32/context.c: In function 'switch_to': "PATH/openbios/arch/sparc32/context.c:116:5: error: PIC register clobbered by 'l7' in 'asm' Asm_volatile_("\n\tcall_switch_context" ^~~
Either your GCC is too old, or it is too new, or the openbios code is wrong and should not list l7 here, or this is compiled with PIC enabled, while it should not.
Lots of options, sorry :-/ But it's easy to try newer or older GCC versions, that might help you to build openbios at least.
If it helps, the self-compiled cross gcc I use for building openbios-sparc32 looks like this:
$ sparc-elf-gcc -v Using built-in specs. COLLECT_GCC=sparc-elf-gcc COLLECT_LTO_WRAPPER=/home/build/sparc-cross/libexec/gcc/sparc-elf/7.3.0/lto-wrapper Target: sparc-elf Configured with: ../gcc-7.3.0/configure --prefix=/home/build/sparc-cross --target=sparc-elf --disable-libssp --enable-languages=c Thread model: single gcc version 7.3.0 (GCC)
ATB,
Mark.