2016-11-08 17:02:24 +01:00
|
|
|
export ROMABLE = 1
|
|
|
|
|
2017-03-30 16:47:51 +02:00
|
|
|
include $(RIOTCPU)/mips_pic32_common/Makefile.include
|
2017-12-12 15:44:44 +01:00
|
|
|
include $(RIOTMAKE)/arch/mips.inc.mk
|
2016-11-08 17:02:24 +01:00
|
|
|
|
|
|
|
# define build specific options
|
2019-08-27 16:06:41 +02:00
|
|
|
CFLAGS += -march=m4k -DSKIP_COPY_TO_RAM
|
2016-11-08 17:02:24 +01:00
|
|
|
|
2020-01-02 09:48:19 +01:00
|
|
|
LINKFLAGS += -Wl,--defsym,__use_excpt_boot=0 $(CFLAGS)
|
|
|
|
LINKFLAGS += -Tpic32mx512_12_128_uhi.ld
|
2016-11-08 17:02:24 +01:00
|
|
|
|
|
|
|
# the pickit programmer (MPLAB-IPE) wants physical addresses in the hex file!!
|
2019-08-27 16:06:41 +02:00
|
|
|
OBJCOPY = objcopy #use system objcopy as toolchain one is broken.
|
|
|
|
OFLAGS += \
|
2018-03-27 12:28:35 +02:00
|
|
|
--change-section-lma .bootflash-0xA0000000 \
|
|
|
|
--change-section-lma .exception_vector-0x80000000 \
|
|
|
|
--change-section-lma .text-0x80000000 \
|
|
|
|
--change-section-lma .init-0x80000000 \
|
|
|
|
--change-section-lma .fini-0x80000000 \
|
|
|
|
--change-section-lma .eh_frame-0x80000000 \
|
|
|
|
--change-section-lma .ctors-0x80000000 \
|
|
|
|
--change-section-lma .dtors-0x80000000 \
|
|
|
|
--change-section-lma .rodata-0x80000000 \
|
|
|
|
--change-section-lma .data-0x80000000 \
|
|
|
|
--change-section-lma .bss-0x80000000 \
|
|
|
|
--change-section-lma .startdata-0x80000000 \
|
2020-01-14 23:49:28 +01:00
|
|
|
|
|
|
|
ifneq (,$(filter cpp,$(FEATURES_USED)))
|
|
|
|
OFLAGS += --change-section-lma .gcc_except_table-0x80000000
|
|
|
|
endif
|
2020-06-30 22:47:55 +02:00
|
|
|
|
|
|
|
# system objcopy is not able to generate a binfile for MIPS
|
|
|
|
BINFILE =
|