官方QQ群收藏本站

百问linux嵌入式论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 42|回复: 1

裸机编译链接错误,xxx.o compiled for EABI version 5

[复制链接]

2

主题

6

帖子

48

积分

新手上路

Rank: 1

积分
48
发表于 2020-2-7 17:09:19 | 显示全部楼层 |阅读模式
注意:如果点击空白处无法输入,则点击字会有输入提示符 | 则可以使用键盘进行输入!

此板块为  [ARM裸机加强版]
  • 问题所在章节:
  • 005_ARM裸机1期加强版(又叫新1期,156节,23节免费,已完结)\新1期视频(156节,23节免费)\第018课_ADC和触摸屏(12节)\第002节_ADC编程_P
  • 发生问题的运行环境:
  • arm-linux-gcc -v
  • Reading specs from /work/tools/gcc-3.4.5-glibc-2.3.6/lib/gcc/arm-linux/3.4.5/specs
  • Configured with: /work/tools/create_crosstools/crosstool-0.43/build/arm-linux/gcc-3.4.5-glibc-2.3.6/gcc-3.4.5/configure --target=arm-linux --host=i686-host_pc-linux-gnu --prefix=/work/tools/gcc-3.4.5-glibc-2.3.6 --with-float=soft --with-headers=/work/tools/gcc-3.4.5-glibc-2.3.6/arm-linux/include --with-local-prefix=/work/tools/gcc-3.4.5-glibc-2.3.6/arm-linux --disable-nls --enable-threads=posix --enable-symvers=gnu --enable-__cxa_atexit --enable-languages=c,c++ --enable-shared --enable-c99 --enable-long-long
  • Thread model: posix
  • gcc version 3.4.5

  • 问题发生描述:
按照老师的视频,学了adc之前的视频后跳转到后面毕业班uboot,kernel,rootfs移植学习,过程中按照视频的节奏,修改过交叉编译器版本,变为4.3.2,学完后
想回来继续看裸机的部分,还是按照视频操作,但是在编译的时候发现一直报错,后来我想可能是交叉编译器版本的问题,重新换回3.4.5后进行make还是有错误,


  • 输出的错误信息:
book@www.100ask.org:/work/hardware/020_adc/001th$ make clean
rm *.bin *.o *.elf *.dis
rm: cannot remove '*.bin': No such file or directory
rm: cannot remove '*.dis': No such file or directory
makefile:20: recipe for target 'clean' failed
make: *** [clean] Error 1
book@www.100ask.org:/work/hardware/020_adc/001th$
book@www.100ask.org:/work/hardware/020_adc/001th$
book@www.100ask.org:/work/hardware/020_adc/001th$ make
arm-linux-gcc -march=armv4 -c -o start.o start.S
arm-linux-gcc -march=armv4 -c -o led.o led.c
arm-linux-gcc -march=armv4 -c -o uart.o uart.c
uart.c: In function `printfhex':
uart.c:73: warning: comparison is always true due to limited range of data type
arm-linux-gcc -march=armv4 -c -o init.o init.c
arm-linux-gcc -march=armv4 -c -o nandflash.o nandflash.c
arm-linux-gcc -march=armv4 -c -o main.o main.c
arm-linux-gcc -march=armv4 -c -o exception.o exception.c
arm-linux-gcc -march=armv4 -c -o interrupt.o interrupt.c
arm-linux-gcc -march=armv4 -c -o timer.o timer.c
arm-linux-gcc -march=armv4 -c -o norflash.o norflash.c
arm-linux-gcc -march=armv4 -c -o my_printf.o my_printf.c
arm-linux-gcc -march=armv4 -c -o string_utils.o string_utils.c
arm-linux-gcc -march=armv4 -c -o lib1funcs.o lib1funcs.S
#arm-linux-ld -Ttext 0 -Tdata 0x30000000  start.o led.o uart.o init.o main.o -o sdram.elf
arm-linux-ld -T sdram.lds start.o led.o uart.o init.o nandflash.o main.o exception.o interrupt.o timer.o norflash.o my_printf.o string_utils.o lib1funcs.o lcd/font.o lcd/framebuffer.o lcd/geometry.o lcd/lcd.o lcd/lcd_4.3.o lcd/lcd_controller.o lcd/lcd_test.o lcd/s3c2440_lcd_controller.o lcd/font_8x16.o adc_touchscreen/adc.o adc_touchscreen/adc_test.o libgcc.a -o sdram.elf
arm-linux-ld: ERROR: lcd/font.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/font.o
arm-linux-ld: ERROR: lcd/framebuffer.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/framebuffer.o
arm-linux-ld: ERROR: lcd/geometry.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/geometry.o
arm-linux-ld: ERROR: lcd/lcd.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/lcd.o
arm-linux-ld: ERROR: lcd/lcd_4.3.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/lcd_4.3.o
arm-linux-ld: ERROR: lcd/lcd_controller.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/lcd_controller.o
arm-linux-ld: ERROR: lcd/lcd_test.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/lcd_test.o
arm-linux-ld: ERROR: lcd/s3c2440_lcd_controller.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/s3c2440_lcd_controller.o
arm-linux-ld: ERROR: lcd/font_8x16.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file lcd/font_8x16.o
arm-linux-ld: ERROR: adc_touchscreen/adc.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file adc_touchscreen/adc.o
arm-linux-ld: ERROR: adc_touchscreen/adc_test.o is compiled for EABI version 5, whereas sdram.elf is compiled for version 0
arm-linux-ld: failed to merge target specific data of file adc_touchscreen/adc_test.o
lcd/font.o(.text+0x18): In function `font_init':
: internal error: unsupported relocation error
makefile:15: recipe for target 'all' failed
make: *** [all] Segmentation fault (core dumped)
book@www.100ask.org:/work/hardware/020_adc/001th$

报错的主要信息是说里面文件编译的版本不同.
请老师指点一下排查的思路!
回复

使用道具 举报

2

主题

6

帖子

48

积分

新手上路

Rank: 1

积分
48
 楼主| 发表于 2020-2-8 12:03:52 | 显示全部楼层
删除ubantu上的目标工程,重新上传,make编译,没有问题了。!具体的原因还是没有查到,现在只是不影响继续学习进度。
回复 支持 反对

使用道具 举报

技术支持
在线咨询
咨询热线
0755-86200561
微信扫一扫
获取更多资讯!

Archiver|小黑屋|百问linux嵌入式论坛     

GMT+8, 2020-2-22 11:59 , Processed in 0.127514 second(s), 9 queries , File On.

Powered by Discuz! X3.3 Licensed

© 2001-2017 Comsenz Inc. Template By 【未来科技】【 www.wekei.cn 】

快速回复 返回顶部 返回列表