123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208 |
- -include ../../Rules.make
- export PATH=/bin:/sbin:/usr/bin:$(SDK_PATH_TARGET)/usr/bin:$PATH
- #define library variable
- Lib_SQLite3 = "-L../../../Modularization/ocppfiles" -lsqlite3
- Lib_RatedCurrentLib = "-L./" -lm -lModule_RatedCurrent
- Lib_Xml = "-L../GPL/libxml2-2.7.6/release/lib" -lxml2
- Lib_Openssl = "-L../GPL/openssl-1.1.1n/release/lib" -lssl
- all: clean Module_RFIDLib Module_SystexLib Infypwr_PsuCommObj Phihong_PsuCommObj Module_RatedCurrentLib Module_UpgradeLib UUpwr_PsuCommObj \
- Module_Wifi Module_4g WebServiceLib Module_EventLogging Module_ProduceUtils Module_DcMeter Module_PowerSharing_Task Module_Firewall \
- Ocpp16 Ocpp20 Ocppph \
- Module_Payment Module_Payment_Bazel8 Module_Payment_Enegate
- clean:
- rm -f libModule_RFID.a
- rm -f Module_Wifi
- rm -f Module_4g
- rm -f WebService
- rm -f logPackTools
- rm -f OcppBackend
- rm -f OcppBackendPH
- rm -f libPhihong_PsuCommObj.a
- rm -f libModule_Upgrade.a
- rm -f libInfypwr_PsuCommObj.a
- rm -f libUUpwr_PsuCommObj.a
- rm -f Module_ProduceUtils
- rm -f Module_PhBackend
- rm -f OcppBackend20
- rm -f Module_DcMeter
- rm -f Module_PowerSharing
- Module_ProduceUtils:
- @echo "===== Module_ProduceUtils =========================================="
- rm -f Module_ProduceUtils
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -I ../Projects -o Module_ProduceUtils.o Module_ProduceUtils.c
- $(CC) -o Module_ProduceUtils Module_ProduceUtils.o
- rm -f Module_ProduceUtils.o
- mv -f Module_ProduceUtils ../rootfs/root
- Module_RatedCurrentLib:
- @echo "===== Module_RatedCurrentLib ======================================="
- rm -f libModule_RatedCurrent.a
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -o Module_RatedCurrent.o Module_RatedCurrent.c
- $(AR) -r libModule_RatedCurrent.a Module_RatedCurrent.o
- rm -f Module_RatedCurrent.o
- Module_RFIDLib:
- @echo "===== Module_RFIDLib ==============================================="
- rm -f libModule_RFID.a
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -o Module_RFID.o Module_RFID.c
- $(AR) -r libModule_RFID.a Module_RFID.o
- rm -f Module_RFID.o
- Module_SystexLib:
- @echo "===== Module_SystexLib ============================================="
- rm -f libModule_Systex.a
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -o Module_Systex.o Module_Systex.c
- $(AR) -r libModule_Systex.a Module_Systex.o
- rm -f Module_Systex.o
- Module_Wifi:
- @echo "===== Module_Wifi =================================================="
- rm -f Module_Wifi
- $(CC) -D $(Project) -I ../Projects -I .//ocppfiles -I ../GPL/json-c-json-c-0.13.1-20180305/release/include -O0 -Wall -c -fmessage-length=0 -o Module_Wifi.o Module_Wifi.c
- $(CC) -o Module_Wifi Module_Wifi.o ${Lib_SQLite3} -L ../GPL/json-c-json-c-0.13.1-20180305/release/lib -ljson-c
- rm -f Module_Wifi.o
- mv -f Module_Wifi ../rootfs/root
- Module_4g:
- @echo "===== Module_4g ==================================================="
- rm -f Module_4g
- $(CC) -D $(Project) -I ../Projects -O0 -Wall -c -fmessage-length=0 -o Module_4g.o Module_4g.c
- $(CC) -o Module_4g Module_4g.o
- rm -f Module_4g.o
- mv -f Module_4g ../rootfs/root
- WebServiceLib:
- @echo "===== WebServiceLib =============================================="
- rm -f WebService
- $(CC) -D $(Project) -I ../GPL/json-c-json-c-0.13.1-20180305/release/include/json-c -I ../Projects -O0 -Wall -c -fmessage-length=0 -o WebService.o -ljson-c -lm -w WebService.c
- $(CC) -L ../GPL/json-c-json-c-0.13.1-20180305/release/lib -o WebService WebService.o -ljson-c -lm
- rm -f WebService.o
- $(CC) -D $(Project) -I ../Projects -O0 -Wall -c -fmessage-length=0 -o logPackTools.o logPackTools.c
- $(CC) -o logPackTools logPackTools.o
- rm -f logPackTools.o
- mv -f WebService ../rootfs/root/
- mv -f logPackTools ../rootfs/root/
- Ocppph:
- @echo "===== Ocppph ====================================================="
- rm -f OcppBackendPH;
- $(CC) -D $(TLS_EXPIRED) -D $(Project) "-Wl,-rpath-link,../GPL/openssl-1.1.1n/release/lib" -D__USE_XOPEN -D_GNU_SOURCE ./ocppph/Module_OcppBackend.c ./ocppph/MessageHandler.c ./ocppph/JsonParser.c ./ocppph/SystemLogMessage.c ./ocppph/hashmap.c ./ocppph/common.c -I ../Projects -I ../GPL/libwebsockets-2.2.2-stable/release/include -I ../GPL/json-c-json-c-0.13.1-20180305/release/include -include ./Module_RatedCurrent.h -L ../GPL/libwebsockets-2.2.2-stable/release/lib -L ../GPL/json-c-json-c-0.13.1-20180305/release/lib -L ./ -lwebsockets -lrt -luuid -lpthread -lc -lsqlite3 -ljson-c ${Lib_Openssl} ${Lib_RatedCurrentLib} -o OcppBackendPH
- mv -f OcppBackendPH ../rootfs/root/
- Ocpp16:
- @echo "===== Ocpp16 ====================================================="
- rm -f OcppBackend;
- $(CC) -D $(TLS_EXPIRED) -D $(Project) "-Wl,-rpath-link,../GPL/openssl-1.1.1n/release/lib" -D__USE_XOPEN -D_GNU_SOURCE ./ocppfiles/Module_OcppBackend.c ./ocppfiles/MessageHandler.c ./ocppfiles/JsonParser.c ./ocppfiles/SystemLogMessage.c ./ocppfiles/hashmap.c ./ocppfiles/common.c -I ../Projects -I ../GPL/libwebsockets-2.2.2-stable/release/include -I ../GPL/json-c-json-c-0.13.1-20180305/release/include -include ./Module_RatedCurrent.h -L ../GPL/libwebsockets-2.2.2-stable/release/lib -L ../GPL/json-c-json-c-0.13.1-20180305/release/lib -L ./ -lwebsockets -lrt -luuid -lpthread -lc -lsqlite3 -ljson-c ${Lib_Openssl} ${Lib_RatedCurrentLib} -o OcppBackend
- mv -f OcppBackend ../rootfs/root/
- Ocpp20:
- @echo "===== Ocpp20 ====================================================="
- rm -f OcppBackend20;
- $(CC) -D $(TLS_EXPIRED) -D $(Project) "-Wl,-rpath-link,../GPL/openssl-1.1.1n/release/lib" -D__USE_XOPEN -D_GNU_SOURCE ./ocpp20/Module_OcppBackend20.c ./ocpp20/MessageHandler.c ./ocpp20/JsonParser.c ./ocpp20/SystemLogMessage.c ./ocpp20/hashmap.c ./ocpp20/common.c -I ../Projects -I ../GPL/libwebsockets-2.2.2-stable/release/include -I ../GPL/json-c-json-c-0.13.1-20180305/release/include -include ./Module_RatedCurrent.h -L ../GPL/libwebsockets-2.2.2-stable/release/lib -L ../GPL/json-c-json-c-0.13.1-20180305/release/lib -L ./ -lwebsockets -lrt -luuid -lpthread -lc -lsqlite3 -ljson-c ${Lib_Openssl} ${Lib_RatedCurrentLib} -o OcppBackend20
- mv -f OcppBackend20 ../rootfs/root/
- Phihong_PsuCommObj:
- @echo "===== Module_PsuCommObj =========================================="
- rm -f libPhihong_PsuCommObj.a
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -o Phihong_PsuCommObj.o Phihong_PsuCommObj.c
- $(AR) -r libPhihong_PsuCommObj.a Phihong_PsuCommObj.o
- rm -f Phihong_PsuCommObj.o
- Infypwr_PsuCommObj:
- @echo "===== Infypwr_PsuCommObj =========================================="
- rm -f libInfypwr_PsuCommObj.a
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -o Infypwr_PsuCommObj.o Infypwr_PsuCommObj.c
- $(AR) -r libInfypwr_PsuCommObj.a Infypwr_PsuCommObj.o
- rm -f Infypwr_PsuCommObj.o
- UUpwr_PsuCommObj:
- rm -f libUUpwr_PsuCommObj.a
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -o UUpwr_PsuCommObj.o UUpwr_PsuCommObj.c
- $(AR) -r libUUpwr_PsuCommObj.a UUpwr_PsuCommObj.o
- rm -f UUpwr_PsuCommObj.o
- Module_UpgradeLib:
- @echo "===== Module_UpgradeLib =========================================="
- rm -f libModule_Upgrade.a
- $(CC) -D $(Project) -O0 -Wall -c -fmessage-length=0 -o Module_Upgrade.o Module_Upgrade.c
- $(AR) -r libModule_Upgrade.a Module_Upgrade.o
- rm -f Module_Upgrade.o
- Module_EventLogging:
- @echo "===== Module_EventLogging ========================================"
- rm -f Module_EventLogging
- $(CC) -D $(Project) -I ../Projects -I ./ocppfiles -O0 -Wall -c -fmessage-length=0 -o Module_EventLogging.o Module_EventLogging.c
- $(CC) -L ./ocppfiles -lsqlite3 -o Module_EventLogging Module_EventLogging.o
- rm -f Module_EventLogging.o
- mv -f Module_EventLogging ../rootfs/root
- Module_PhBackend:
- @echo "===== Module_PhBackend ==========================================="
- rm -f Module_Phbackend
- $(CC) -D $(Project) -I ../Projects -O0 -Wall -c -fmessage-length=0 -o Module_PhBackend.o Module_PhBackend.c
- $(CC) -o Module_PhBackend Module_PhBackend.o ${Lib_RatedCurrentLib}
- rm -f Module_PhBackend.o
- mv -f Module_PhBackend ../rootfs/root
- Module_InitUpgrade:
- @echo "===== Module_InitUpgrade ========================================="
- rm -f Module_InitUpgrade
- $(CC) -D $(Project) -I ../Projects -O0 -Wall -c -fmessage-length=0 -o Module_InitUpgrade.o Module_InitUpgrade.c
- $(CC) -o Module_InitUpgrade Module_InitUpgrade.o
- rm -f Module_InitUpgrade.o
- mv -f Module_InitUpgrade ../rootfs/root
- Module_Payment:
- @echo "===== Module_Payment ============================================="
- rm -f Module_Payment
- $(CC) -D $(Project) -I ../Projects -O0 -Wall -c -fmessage-length=0 -o Module_Payment.o Module_Payment.c
- $(CC) -o Module_Payment Module_Payment.o
- rm -f Module_Payment.o
- mv -f Module_Payment ../rootfs/root
- Module_Payment_Bazel8:
- @echo "===== Module_Payment_Bazel8 ======================================"
- rm -f Module_Payment_Bazel8
- $(CC) -D $(Project) -I ../Projects -I ../GPL/libxml2-2.7.6/release/include/libxml2 -O0 -Wall -c -fmessage-length=0 -o Module_Payment_Bazel8.o Module_Payment_Bazel8.c
- $(CC) -o Module_Payment_Bazel8 Module_Payment_Bazel8.o -lrt ${Lib_Xml}
- rm -f Module_Payment_Bazel8.o
- mv -f Module_Payment_Bazel8 ../rootfs/root
- Module_Payment_Enegate:
- @echo "===== Module_Payment_Enegate ===================================="
- rm -f Module_Payment_Enegate
- $(CC) -D $(Project) -I ../Projects -O0 -Wall -c -fmessage-length=0 -include ./Module_RatedCurrent.h -o Module_Payment_Enegate.o Module_Payment_Enegate.c
- $(CC) -o Module_Payment_Enegate Module_Payment_Enegate.o -lrt ${Lib_RatedCurrentLib}
- rm -f Module_Payment_Enegate.o
- mv -f Module_Payment_Enegate ../rootfs/root
- Module_DcMeter:
- @echo "===== Module_DcMeter ============================================="
- rm -f Module_DcMeter;
- $(CC) -D $(Project) "-Wl,-rpath-link,../GPL/openssl-1.1.1n/release/lib" ./DcMeter/Module_DcMeter.c ./DcMeter/meterComm.c ./DcMeter/curlApi.c ./DcMeter/SystemLogMessage.c -I ./ -I ../Projects -I ../GPL/curl-7.61.1/release/include -I ../GPL/json-c-json-c-0.13.1-20180305/release/include -L ../GPL/json-c-json-c-0.13.1-20180305/release/lib -L ../GPL/curl-7.61.1/release/lib -ljson-c -lcurl -lssl -o Module_DcMeter ${Lib_RatedCurrentLib}
- mv -f Module_DcMeter ../rootfs/root/
- Module_PCBTest:
- @echo "===== Module_PCBTest ============================================="
- rm -f Module_PCBTest
- $(CC) -o Module_PCBTest ./PCBTest/Module_PCBTest.c ./PCBTest/Comm_Test.c ./PCBTest/Ethernet_Test.c ./PCBTest/IO_Test.c ./PCBTest/PrimaryMCU_Test.c ./PCBTest/Storage_Test.c -I ./
- mv -f Module_PCBTest ../rootfs/root
- Module_PowerSharing_Task:
- @echo "===== Module_PowerSharing_Task ==================================="
- rm -f Module_PowerSharing
- $(CC) -D $(Project) "-I../Projects" "-I./ocppfiles" "-include./Module_RatedCurrent.h" -O0 -Wall -fmessage-length=0 Module_PowerSharing.c ${Lib_RatedCurrentLib} -lm -lrt -o Module_PowerSharing
- rm -f *.o
- mv -f Module_PowerSharing ../rootfs/root
- Module_Firewall:
- @echo "===== Module_Firewall_Task ======================================="
- rm -f Module_Firewall
- $(CC) -D $(Project) "-I../Projects" -O0 -Wall -fmessage-length=0 ./Firewall/Module_Firewall.c ./Firewall/yuarel.c -lrt -o Module_Firewall
- rm -f *.o
- mv -f Module_Firewall ../rootfs/root
|