codeblocks中自己做的向导,在链接的时候出错。怎么办。
是从一个makefile
如下:
# Blacksun Empire g++ MakeFile generator
# This is a machine generated file-do not edit
# 2012/9/14 13:21:55
TOOLROOT = C:/Cygnus/arm-tools/i686-pc-cygwin/bin
CC = $(TOOLROOT)/arm-elf-gcc
CXX = $(TOOLROOT)/arm-elf-g++
OBJCOPY = $(TOOLROOT)/arm-elf-objcopy
AR = $(TOOLROOT)/arm-elf-ar
LD = $(TOOLROOT)/arm-elf-ld
OUTPUT_DIR = ./
OUTPUT_NAME = ./qiping.elf
OUTPUT_BIN = ./qiping.bin
LIB = C:/Cygnus/arm-tools/i686-pc-cygwin/arm-elf/lib
GCCLIB = C:/Cygnus/arm-tools/i686-pc-cygwin/lib/gcc-lib/arm-elf/3.0.3
TEXT = 1280000
DATA = 0003000
BSS = 0020000
INC_PATH = -I"C:/Cygnus/arm-tools/i686-pc-cygwin/arm-elf/include" -I"C:/Cygnus/arm-tools/i686-pc-cygwin/lib/gcc-lib/arm-elf/3.0.3/include" -I"./Include"
DEFINE =
CPPFLAGS = $(INC_PATH) $(DEFINE)
ENDIAN_AS = -Wa,-EL
ENDIANFLAG = -mlittle-endian -A 'endian(little)'
CFLAGS += $(INC_PATH) $(DEFINE) $(ENDIANFLAG) -fno-rtti -DMACHINE_TYPE_ARM -w -O0 -g -gdwarf-2
ASFLAGS = -x assembler-with-cpp -Wa,--gstabs -Wa,-mall $(ENDIAN_AS)
LDFLAGS = -n -N -nostartupfiles -static -EL -e_start -g
LINK_DIR = ./
LINK_SCRIPT := "C:CygnusGMakerGMaker.LD"
LIBS = ./lib/p130.a ./lib/p130-flash.a $(LIB)/libm.a $(LIB)/libc.a $(GCCLIB)/libgcc.a
SOURCES = cstartup_flash.s main.c function.c
OBJECTS := cstartup_flash.o main.o function.o
all: $(OBJECTS) $(OUTPUT_NAME) $(OUTPUT_BIN)
cstartup_flash.o: cstartup_flash.s
$(CC) -c $(CFLAGS) $(ASFLAGS) cstartup_flash.s
main.o: main.c
$(CC) -c $(CFLAGS) main.c
function.o: function.c
$(CC) -c $(CFLAGS) function.c
$(OUTPUT_NAME): $(OBJECTS)
$(LD) -Ttext $(TEXT) -Tdata $(DATA) -Tbss $(BSS) $(LDFLAGS) -L"$(LINK_DIR)" -T$(LINK_SCRIPT) -o $@ $^ $(LIBS)
$(OUTPUT_BIN): $(OUTPUT_NAME)
$(OBJCOPY) -R .data -R .rdata -R .sbss -R .bss -O binary $(OUTPUT_NAME) tempbin.1
$(OBJCOPY) -R .text -R .rodata --change-section-address .data=0 -O binary $(OUTPUT_NAME) tempbin.2
cat -B tempbin.1 tempbin.2 > $(OUTPUT_BIN)
rm tempbin.1 tempbin.2
rm -f $(OBJECTS)
做了一个向导,但是在编译时出错,怎么办
[100.0%] arm-elf-ld.exe -Ldefaultsrc -o defaultP130.elf defaultsrccstartup_flash.o defaultsrcmain.o -T ld/target.ld -v -Ttext 1280000 -Tdata 0008000 -Tbss 0003000 -n -N -nostartupfiles -static -EL -e_start -g libfile_sys.a libP130.a C:/Cygnus/arm-tools/i686-pc-cygwin/arm-elf/lib/libm.a C:/Cygnus/arm-tools/i686-pc-cygwin/arm-elf/lib/libc.a C:/Cygnus/arm-tools/i686-pc-cygwin/lib/gcc-lib/arm-elf/3.0.3/libgcc.a
arm-elf-ld: Error: highbios.o uses hard floating point, whereas startupfiles uses soft floating point
File format not recognized: failed to merge target specific data of file libP130.a(highbios.o)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
自己顶
没有吗