mirror of
https://github.com/isfshax/isfshax.git
synced 2025-02-02 05:12:34 +01:00
Don't hardcode gcc version
This commit is contained in:
parent
a7e0f61c8a
commit
0d6def9490
8
Makefile
8
Makefile
@ -6,7 +6,9 @@ ifeq ($(strip $(DEVKITARM)),)
|
||||
$(error "Please set DEVKITARM in your environment. export DEVKITARM=<path to>devkitARM")
|
||||
endif
|
||||
|
||||
include $(DEVKITARM)/ds_rules
|
||||
include $(DEVKITARM)/base_rules
|
||||
|
||||
GCC_VERSION := $(shell $(CC) -dumpversion)
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# TARGET is the name of the output
|
||||
@ -44,7 +46,7 @@ CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions
|
||||
|
||||
ASFLAGS := -g $(ARCH) $(DEFINES)
|
||||
LDFLAGS = -n -nostartfiles -g --specs=../stage2/link.specs $(ARCH) -Wl,--gc-sections,-Map,$(TARGET).map \
|
||||
-L$(DEVKITARM)/lib/gcc/arm-none-eabi/5.3.0/be -L$(DEVKITARM)/arm-none-eabi/lib/be
|
||||
-L$(DEVKITARM)/lib/gcc/arm-none-eabi/$(GCC_VERSION)/be -L$(DEVKITARM)/arm-none-eabi/lib/be
|
||||
|
||||
LIBS :=
|
||||
|
||||
@ -140,6 +142,8 @@ $(TARGET)-strip.elf: $(TARGET).elf
|
||||
@$(STRIP) $< -o $@
|
||||
|
||||
$(TARGET).elf: $(OFILES)
|
||||
$(SILENTMSG) linking $(notdir $@)
|
||||
$(SILENTCMD)$(LD) $(LDFLAGS) $(OFILES) $(LIBPATHS) $(LIBS) -o $@
|
||||
|
||||
$(ELFLOADER):
|
||||
@$(MAKE) -C $(ROOTDIR)/stage2ldr
|
||||
|
Loading…
x
Reference in New Issue
Block a user