我一直在尝试编译包含 libCurl 的 ucLinux,但是任何时候我在配置中包含 curl 时都会在尝试编译 libbzip2 时出错。
我正在为冷火 68K 处理器交叉编译它。
它说 PIC 不支持重定位类型,但我不知道如何解决这个问题。我的印象是所有的库都需要编译为 PIC。
这是输出:
make[4]: Entering directory `/home/lantronix/linuxsdk/linux/lib/libbzip2'
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -O2 -g -fomit-frame-pointer -pipe -fno-common -fno-builtin -Wall -DEMBED -fno-dwarf2-cfi-asm -msep-data -Dlinux -D__linux__ -Dunix -D__uClinux__ -c blocksort.c
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -O2 -g -fomit-frame-pointer -pipe -fno-common -fno-builtin -Wall -DEMBED -fno-dwarf2-cfi-asm -msep-data -Dlinux -D__linux__ -Dunix -D__uClinux__ -c huffman.c
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -O2 -g -fomit-frame-pointer -pipe -fno-common -fno-builtin -Wall -DEMBED -fno-dwarf2-cfi-asm -msep-data -Dlinux -D__linux__ -Dunix -D__uClinux__ -c crctable.c
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -O2 -g -fomit-frame-pointer -pipe -fno-common -fno-builtin -Wall -DEMBED -fno-dwarf2-cfi-asm -msep-data -Dlinux -D__linux__ -Dunix -D__uClinux__ -c randtable.c
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -O2 -g -fomit-frame-pointer -pipe -fno-common -fno-builtin -Wall -DEMBED -fno-dwarf2-cfi-asm -msep-data -Dlinux -D__linux__ -Dunix -D__uClinux__ -c compress.c
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -O2 -g -fomit-frame-pointer -pipe -fno-common -fno-builtin -Wall -DEMBED -fno-dwarf2-cfi-asm -msep-data -Dlinux -D__linux__ -Dunix -D__uClinux__ -c decompress.c
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -O2 -g -fomit-frame-pointer -pipe -fno-common -fno-builtin -Wall -DEMBED -fno-dwarf2-cfi-asm -msep-data -Dlinux -D__linux__ -Dunix -D__uClinux__ -c bzlib.c
ucfront-gcc m68k-uclinux-gcc -mcpu=5208 -DCONFIG_COLDFIRE -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.3 blocksort.o huffman.o crctable.o randtable.o compress.o decompress.o bzlib.o
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
ERROR: reloc type R_68K_32 is not supported for PIC
43 bad relocs
/home/lantronix/linuxsdk/toolchains/freescale-coldfire-4.4/m68k-uclinux/bin/ld.real: warning: cannot find entry symbol _start; defaulting to 00000000
collect2: ld returned 1 exit status
make[4]: *** [all] Error 1
make[4]: Leaving directory `/home/lantronix/linuxsdk/linux/lib/libbzip2'
make[3]: *** [libbzip2] Error 2
make[3]: Leaving directory `/home/lantronix/linuxsdk/linux/lib'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/lantronix/linuxsdk/linux/lib'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/lantronix/linuxsdk/linux'
make: *** [build] Error 2