lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame^] | 1 | include $(zte_app_mak)
|
| 2 |
|
| 3 | all:
|
| 4 | echo "zte_webui compile do nothing"
|
| 5 |
|
| 6 | clean:
|
| 7 | echo "zte_webui clean do nothing"
|
| 8 |
|
| 9 | romfs:
|
| 10 | @mkdir -p $(ROOTFS_DIR)/etc_ro/web
|
| 11 | @cp -afvp $(APP_DIR)/zte_webui_min/* $(ROOTFS_DIR)/etc_ro/web
|
| 12 | find . -type f -name '*.js' | xargs -n1 -I {} java -jar $(YUICOMPRESSOR) {} -o $(ROOTFS_DIR)/etc_ro/web/{}
|
| 13 | find . -type f -name '*.css' | xargs -n1 -I {} java -jar $(YUICOMPRESSOR) {} -o $(ROOTFS_DIR)/etc_ro/web/{}
|
| 14 | find . -type f -name '*.html' | xargs -n1 -I {} sed -i 's/^[ \t]*//g' $(ROOTFS_DIR)/etc_ro/web/{}
|
| 15 | find . -type f -name '*.html' | xargs -n1 -I {} sed -i 's/[ \t]*$$//g' $(ROOTFS_DIR)/etc_ro/web/{}
|
| 16 | find . -type f -name '*.html' | xargs -n1 -I {} sed -i ":a;N;s/\r//g;ta" $(ROOTFS_DIR)/etc_ro/web/{}
|
| 17 | find . -type f -name '*.html' | xargs -n1 -I {} sed -i ":a;N;s/\n//g;ta" $(ROOTFS_DIR)/etc_ro/web/{}
|
| 18 | ifneq ($(CONFIG_WIFI_MODULE), aic8800)
|
| 19 | -rm -v $(ROOTFS_DIR)/etc_ro/web/subpg/wifi_ap_station.html
|
| 20 | endif
|
| 21 | ifeq ($(CONFIG_WEBUI_TYPE),CPE)
|
| 22 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 23 | -cp -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_cpe.js $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 24 | endif
|
| 25 | ifeq ($(CONFIG_WEBUI_TYPE),CPE_SW)
|
| 26 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 27 | -cp -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_cpe_sw.js $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 28 | endif
|
| 29 |
|
| 30 | ifeq ($(PRJ_IS_MIN), yes)
|
| 31 | -cp -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_min.js $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 32 | ifeq ($(CONFIG_WIFI_MODULE), xr819)
|
| 33 | -cp -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_xr819.js $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 34 | endif
|
| 35 | ifeq ($(CONFIG_WIFI_MODULE), ssv6x5x)
|
| 36 | -cp -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_ssv6x5x.js $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 37 | endif
|
| 38 | ifeq ($(CONFIG_WIFI_MODULE), aic8800)
|
| 39 | -cp -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_aic8800.js $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 40 | ifeq ($(CONFIG_WIFI_SINGLEAP), no)
|
| 41 | -sed -i 's/WIFI_SLEEP_SUPPORT:false,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 42 | -sed -i 's/HAS_BATTERY:false,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 43 | -sed -i 's/TURN_OFF_SUPPORT:false,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 44 | else
|
| 45 | -sed -i 's/AP_STATION_SUPPORT:true,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 46 | -sed -i 's/HAS_MULTI_SSID:true,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 47 | endif
|
| 48 | endif
|
| 49 | endif
|
| 50 |
|
| 51 | ifneq ($(CONFIG_USE_WEBUI_SECURITY),yes)
|
| 52 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/3rd/crypto-js.js
|
| 53 | -cp -v $(ROOTFS_DIR)/etc_ro/web/js/ext/crypto-js-null.js $(ROOTFS_DIR)/etc_ro/web/js/3rd/crypto-js.js
|
| 54 | -sed -i 's/PASSWORD_ENCODE:false,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 55 | endif
|
| 56 | ifeq ($(USE_FOTA),yes)
|
| 57 | -sed -i 's/UPGRADE_TYPE:"NONE",//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 58 | -sed -i 's/HAS_FOTA:false,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 59 | -sed -i 's/HAS_UPDATE_CHECK:false,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 60 | endif
|
| 61 | ifeq ($(CONFIG_MMI_LCD),yes)
|
| 62 | -sed -i 's/WIFI_SUPPORT_QR_CODE:false,//' $(ROOTFS_DIR)/etc_ro/web/js/ext/set.js
|
| 63 | endif
|
| 64 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/crypto-js-null.js
|
| 65 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_min.js
|
| 66 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_xr819.js
|
| 67 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_ssv6x5x.js
|
| 68 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_aic8800.js
|
| 69 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_cpe.js
|
| 70 | -rm -v $(ROOTFS_DIR)/etc_ro/web/js/ext/set_cpe_sw.js
|
| 71 | -rm -v $(ROOTFS_DIR)/etc_ro/web/makefile
|
| 72 | ifeq ($(CONFIG_USE_WEBUI_ZIP),yes)
|
| 73 | (cd $(ROOTFS_DIR)/etc_ro && zip -r web.zip web)
|
| 74 | (cd $(ROOTFS_DIR)/etc_ro && rm -rfv web)
|
| 75 | endif
|
| 76 |
|
| 77 |
|