forked from Imagelibrary/rtems
Added C++ linking rule from Rosimildo DaSilva <rdasilva@connecttel.com>.
This commit is contained in:
@@ -89,7 +89,7 @@ define make-exe
|
||||
-Wl,--oformat,elf32-i386 -o $(basename $@).obj \
|
||||
-o $(basename $@).obj \
|
||||
$(LINK_OBJS) $(LINK_LIBS)
|
||||
$(OBJCOPY) -O a.out-i386 \
|
||||
$(OBJCOPY) -O elf32-i386 \
|
||||
--remove-section=.rodata \
|
||||
--remove-section=.comment \
|
||||
--remove-section=.note \
|
||||
@@ -103,6 +103,25 @@ define make-exe
|
||||
$(CC) $(CPPFLAGS) $(CFLAGS) $(CFLAGS_LD) -Wl,-Ttext,$(RELOCADDR) \
|
||||
-o $(basename $@).coff $(LINK_OBJS) $(LINK_LIBS)
|
||||
endef
|
||||
define make-cxx-exe
|
||||
$(CXX) $(CPPFLAGS) $(CFLAGS) $(CFLAGS_LD) -Wl,-Ttext,$(RELOCADDR) \
|
||||
-Wl,--oformat,elf32-i386 -o $(basename $@).obj \
|
||||
-o $(basename $@).obj \
|
||||
$(LINK_OBJS) $(LINK_LIBS)
|
||||
$(OBJCOPY) -O elf32-i386 \
|
||||
--remove-section=.rodata \
|
||||
--remove-section=.comment \
|
||||
--remove-section=.note \
|
||||
--strip-unneeded $(basename $@).obj $@
|
||||
$(OBJCOPY) -O binary $(basename $@).obj $(basename $@).bin
|
||||
$(PROJECT_TOOLS)/bin2boot -v $(basename $@).bt $(HEADERADDR)\
|
||||
$(START16FILE) $(START16ADDR) 0 $(basename $@).bin $(RELOCADDR) 0
|
||||
$(NM) -g -n $(basename $@).obj > $(basename $@).num
|
||||
$(SIZE) $(basename $@).obj
|
||||
$(INSTALL_VARIANT) -m 555 $(basename $@).bt ${PROJECT_RELEASE}/BootImgs
|
||||
$(CXX) $(CPPFLAGS) $(CFLAGS) $(CFLAGS_LD) -Wl,-Ttext,$(RELOCADDR) \
|
||||
-o $(basename $@).coff $(LINK_OBJS) $(LINK_LIBS)
|
||||
endef
|
||||
endif
|
||||
|
||||
# Miscellaneous additions go here
|
||||
|
||||
Reference in New Issue
Block a user