Makefile.mpc5676r 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. # Makefile for CW308T-MPC5676R Target
  2. #Normal installation of S32 goes here:
  3. NXPS32DSROOT = C:/NXP/S32DS_Power_v2.1
  4. #NXPS32DSROOT = D:/devtools/NXP/S32DS_Power_v2.1
  5. VPATH += :$(HALPATH)/mpc5676r
  6. VPATH += :$(HALPATH)/mpc5676r/nxp
  7. VPATH += :$(HALPATH)/mpc5676r/nxp/device
  8. VPATH += :$(HALPATH)/mpc5676r/nxp/drivers/src/CAN
  9. VPATH += :$(HALPATH)/mpc5676r/nxp/drivers/src/PINS/siu
  10. #VPATH += :$(HALPATH)/mpc5676r/nxp/drivers/src/PINS/siul2
  11. VPATH += :$(HALPATH)/mpc5676r/nxp/drivers/src/CLOCK
  12. VPATH += :$(HALPATH)/mpc5676r/nxp/drivers/src/IRQ
  13. VPATH += :$(HALPATH)/mpc5676r/nxp/drivers/src/SEM
  14. VPATH += :$(HALPATH)/mpc5676r/nxp/drivers/src/ESCI
  15. VPATH += :$(HALPATH)/mpc5676r/nxp/pal/src/UART
  16. VPATH += :$(HALPATH)/mpc5676r/nxp/source
  17. VPATH += :$(HALPATH)/mpc5676r/nxp/osif
  18. VPATH += :$(HALPATH)/mpc5676r/nxp/startup
  19. VPATH += :$(HALPATH)/mpc5676r/nxp/util
  20. VPATH += :$(HALPATH)/mpc5676r/nxp/config
  21. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp
  22. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/device
  23. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/drivers/src/CAN
  24. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/drivers/src/PINS/siu
  25. #EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/drivers/src/PINS/siul2
  26. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/drivers/src/SEM
  27. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/drivers/src/IRQ
  28. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/drivers/src/ESCI
  29. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/drivers/inc
  30. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/pal/src/UART
  31. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/pal/inc
  32. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/source
  33. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/startup
  34. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/osif
  35. EXTRAINCDIRS += $(HALPATH)/mpc5676r/nxp/util
  36. EXTRAINCDIRS += $(NXPS32DSROOT)/S32DS/build_tools/e200_ewl2/EWL_C/include
  37. EXTRAINCDIRS += $(NXPS32DSROOT)/S32DS/build_tools/e200_ewl2/EWL_C/include/pa
  38. ASRC += startup_MPC5676R.S intc_sw_handlers.S
  39. SRC += MPC5676R_hwinit.c MPC5676R_intrinit.c
  40. SRC += sema42_driver.c
  41. SRC += osif_baremetal.c
  42. SRC += flexcan_driver.c flexcan_hw_access.c flexcan_irq.c
  43. SRC += pins_siu_driver.c siu_hw_access.c
  44. SRC += clock_MPC5676R.c
  45. SRC += interrupt_manager_MPC56xx.c sema42_driver.c
  46. SRC += esci_driver.c esci_hw_access.c esci_irq.c
  47. SRC += uart_pal.c
  48. SRC += canCom1.c Cpu.c pin_mux.c uart_pal1.c
  49. SRC += MPC5676R_hal.c
  50. #TODO - should this be DCPU_MPC5676R???
  51. MCU_FLAGS = -std=c99 -DSTART_FROM_FLASH -DCPU_MPC5777C -DTURN_ON_CPU0 -DDEV_ERROR_DETECT -O0 -g3 -Wall -fmessage-length=0 -fstrict-volatile-bitfields -ffunction-sections -fdata-sections -mcpu=e200z7 -specs=ewl_c9x_noio.specs -mbig -mvle -mregnames -mhard-float --sysroot="$(NXPS32DSROOT)/S32DS/build_tools/e200_ewl2"
  52. CC = powerpc-eabivle-gcc
  53. OBJCOPY = powerpc-eabivle-objcopy
  54. OBJDUMP = powerpc-eabivle-objdump
  55. SIZE = powerpc-eabivle-size
  56. AR = powerpc-eabivle-ar rcs
  57. NM = powerpc-eabivle-nm
  58. #Output Format = Binary for this target
  59. FORMAT = binary
  60. CPPFLAGS += -E
  61. ASFLAGS +=
  62. CPPDEFS += $(CDEFS)
  63. #TODO - nosys.specs instead??
  64. #TODO - removed the line '-specs=ewl_c9x_noio.specs' from this as it otherwise caused an error???
  65. LDFLAGS += -T"$(HALPATH)\mpc5676r\nxp\56xx_flash.ld" -Wl,-Map,"simpleflexcan.map" -Xlinker --gc-sections -mcpu=e200z7 -mhard-float --sysroot="$(NXPS32DSROOT)/S32DS/build_tools/e200_ewl2"
  66. #LDFLAGS += -specs=nosys.specs s -T $(HALPATH)/mpc5676r/nxp/MPC5676R_FLASH.lcf -Xlinker --gc-sections -lm