Skip to content

Commit

Permalink
PRCv14: makefile cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
lukefahr committed Sep 26, 2017
1 parent 8524746 commit d58b0ea
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions platforms/m3/prc_v14/software/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ CXX := $(CROSS_COMPILE)-g++
LD := $(CROSS_COMPILE)-ld
OBJDUMP := $(CROSS_COMPILE)-objdump
OBJCOPY := $(CROSS_COMPILE)-objcopy
NM := $(CROSS_COMPILE)-nm

################################################################################
## You should not need to edit this makefile beyond this point
Expand Down Expand Up @@ -109,12 +110,12 @@ $(DIRS):
%.elf: COBJ=$(patsubst %.c,%.o,$(wildcard $(dir $@)*.c))
%.elf: SOBJ=$(patsubst %.s,%.o,$(wildcard $(dir $@)*.s))
%.elf: libs/memmap $(LIBS) $$(COBJ) $$(SOBJ)
@if [ -n "$$(echo $$(arm-none-eabi-nm $(filter-out $<,$^) | grep use_gdb))" ]; then \
@if [ -n "$$(echo $$( $(NM) $(filter-out $<,$^) | grep use_gdb))" ]; then \
$(LD) $(LDFLAGS) -T$^ $(GDB) \
"$$(echo $$(arm-none-eabi-gcc -print-libgcc-file-name) | tr -d '\r')" -o $@ ;\
"$$(echo $$( $(CC) -print-libgcc-file-name) | tr -d '\r')" -o $@ ;\
else \
$(LD) $(LDFLAGS) -T$^ \
"$$(echo $$(arm-none-eabi-gcc -print-libgcc-file-name) | tr -d '\r')" -o $@ ;\
"$$(echo $$( $(CC) -print-libgcc-file-name) | tr -d '\r')" -o $@ ;\
fi
$(OBJDUMP) -Sd $@ > $*.asm

Expand Down

0 comments on commit d58b0ea

Please sign in to comment.