Isaac Dunham
2012-11-30 19:37:46 UTC
I've been building pcc with a local patch I'm experimenting with; it changes config.sub & configure to add -DLD_MUSL and changes the linker when I use linux-musl as ostype, but otherwise acts like Linux.
The patched version builds when x86 is the target.
When I tried building with mips as target; it failed to build with:
===> cc/ccom
make[2]: Entering directory `/mnt/mesa/src/musl/loc/cvs/pcc/cc/ccom'
/opt/musl/bin/musl-gcc -static -Bstatic -static builtins.o cgram.o code.o common.o compat.o external.o gcc_compat.o init.o inline.o local.o local2.o main.o match.o optim.o optim2.o order.o pftn.o reader.o regs.o scan.o stabs.o symtabs.o table.o trees.o -o mips-muslin-linux-musl-ccom
builtins.o:(.rodata+0x5b8): undefined reference to `builtin_cfa'
builtins.o:(.rodata+0x5cc): undefined reference to `builtin_frame_address'
builtins.o:(.rodata+0x5e0): undefined reference to `builtin_return_address'
collect2: ld returned 1 exit status
make[2]: *** [mips-muslin-linux-musl-ccom] Error 1
make[2]: Leaving directory `/mnt/mesa/src/musl/loc/cvs/pcc/cc/ccom'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/mnt/mesa/src/musl/loc/cvs/pcc/cc'
make: *** [all] Error 2
grep suggests that builtin_cfa is available on x86(64) and vax, possibly meaning that everything else will break if you try targeting it...
The patched version builds when x86 is the target.
When I tried building with mips as target; it failed to build with:
===> cc/ccom
make[2]: Entering directory `/mnt/mesa/src/musl/loc/cvs/pcc/cc/ccom'
/opt/musl/bin/musl-gcc -static -Bstatic -static builtins.o cgram.o code.o common.o compat.o external.o gcc_compat.o init.o inline.o local.o local2.o main.o match.o optim.o optim2.o order.o pftn.o reader.o regs.o scan.o stabs.o symtabs.o table.o trees.o -o mips-muslin-linux-musl-ccom
builtins.o:(.rodata+0x5b8): undefined reference to `builtin_cfa'
builtins.o:(.rodata+0x5cc): undefined reference to `builtin_frame_address'
builtins.o:(.rodata+0x5e0): undefined reference to `builtin_return_address'
collect2: ld returned 1 exit status
make[2]: *** [mips-muslin-linux-musl-ccom] Error 1
make[2]: Leaving directory `/mnt/mesa/src/musl/loc/cvs/pcc/cc/ccom'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/mnt/mesa/src/musl/loc/cvs/pcc/cc'
make: *** [all] Error 2
grep suggests that builtin_cfa is available on x86(64) and vax, possibly meaning that everything else will break if you try targeting it...
--
Isaac Dunham <***@lavabit.com>
Isaac Dunham <***@lavabit.com>