Makefile 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. -include ../../../../Rules.make
  2. export PATH=/bin:/sbin:/usr/bin:$(SDK_PATH_TARGET)/usr/bin:$PATH
  3. #define library variable
  4. Lib_Module_RFID = -L../../../Modularization -lModule_RFID
  5. Lib_Module_Upgrade = "-L../../../Modularization" -lModule_Upgrade
  6. all: CopyFile apps
  7. apps: Module_InternalComm_Task Module_FactoryConfig_Task Module_EventLogging_Task Module_AlarmDetect_Task Module_CSU_Task
  8. Module_InternalComm_Task:
  9. @echo "===== Module_InternalComm_Task ==================================="
  10. rm -f Module_InternalComm
  11. $(CC) "-I../../" "-include../../../Modularization/Module_Upgrade.h" -O0 -g3 -Wall -c -fmessage-length=0 -o Module_InternalComm.o "./Module_InternalComm.c"
  12. $(CC) -o Module_InternalComm Module_InternalComm.o ${Lib_Module_Upgrade}
  13. rm -f *.o
  14. mv -f Module_InternalComm ../Images/root
  15. @echo \
  16. Module_FactoryConfig_Task:
  17. @echo "===== Module_FactoryConfig_Task =================================="
  18. rm -f Module_FactoryConfig
  19. $(CC) "-I../../" -O0 -g3 -Wall -c -fmessage-length=0 -o Module_FactoryConfig.o "./Module_FactoryConfig.c"
  20. $(CC) -o Module_FactoryConfig Module_FactoryConfig.o
  21. rm -f *.o
  22. mv -f Module_FactoryConfig ../Images/root
  23. @echo \
  24. Module_EventLogging_Task:
  25. @echo "===== Module_EventLogging_Task ==================================="
  26. rm -f Module_EventLogging
  27. $(CC) "-I../../" -O0 -g3 -Wall -c -fmessage-length=0 -o Module_EventLogging.o "./Module_EventLogging.c"
  28. $(CC) -o Module_EventLogging Module_EventLogging.o
  29. rm -f *.o
  30. mv -f Module_EventLogging ../Images/root
  31. @echo \
  32. Module_AlarmDetect_Task:
  33. @echo "===== Module_AlarmDetect_Task ===================================="
  34. rm -f Module_AlarmDetect
  35. $(CC) "-I../../" -O0 -g3 -Wall -c -fmessage-length=0 -o Module_AlarmDetect.o "./Module_AlarmDetect.c"
  36. $(CC) -o Module_AlarmDetect Module_AlarmDetect.o
  37. rm -f *.o
  38. mv -f Module_AlarmDetect ../Images/root
  39. @echo \
  40. Module_CSU_Task:
  41. @echo "===== Module_CSU_Task ============================================"
  42. rm -f main
  43. $(CC) "-I../../" "-include../../../Modularization/Module_Upgrade.h" "-include../../../Modularization/Module_RFID.h" -O0 -g3 -Wall -c -fmessage-length=0 -o main.o "./main.c"
  44. $(CC) -o main main.o ${Lib_Module_RFID} ${Lib_Module_Upgrade}
  45. rm -f *.o
  46. mv -f main ../Images/root
  47. @echo \
  48. CopyFile:
  49. rm -rfv ../Images/root
  50. mkdir -p ../Images/root