blob: 5f29e9393f8074b9e7c5b37980abc9798e02d047 [file] [log] [blame]
wz.wang4cbe62b2024-06-28 11:28:43 +08001AP_PRJ ?= prj_cpe_min
2BOOT_PRJ ?= ufi_mini
3PACK_PRJ ?= prj_cpe
zw.wang4f1b5282024-08-14 15:47:35 +08004RF_TYPES ?= 230A
5DCXOS ?= yes
wz.wang6c460702024-07-01 10:20:35 +08006PATH_PRJ ?= lynq/CPE
zw.wangcd454f52024-11-13 17:56:28 +08007PATCH ?= no
zw.wang4f1b5282024-08-14 15:47:35 +08008ifeq ($(RF_TYPES), 230A)
9RF_TYPE_R306 = RF_TYPE=230A
10endif
11ifeq ($(DCXOS), yes)
12DCXO_R306 = DCXO=yes
13endif
wz.wang4cbe62b2024-06-28 11:28:43 +080014
15.PHONY:all
16all:copy boot ap pack
17 @echo OK
18.PHONY:pack
19pack:
20 make -C allbins/zx297520v3/$(PACK_PRJ)/scripts_linux/
21.PHONY:boot
22boot:
23 make -C boot/prj/zx297520v3/$(BOOT_PRJ)/build/ allclean all
24.PHONY:ap
25ap:
zw.wang4f1b5282024-08-14 15:47:35 +080026 make -C ap/project/zx297520v3/$(AP_PRJ)/build/ allclean all $(RF_TYPE_R306) $(DCXO_R306)
wz.wang4cbe62b2024-06-28 11:28:43 +080027.PHONY:ap_normal2
28ap_normal2:
zw.wang4f1b5282024-08-14 15:47:35 +080029 make -C ap/project/zx297520v3/$(AP_PRJ)/build/ normal2 $(RF_TYPE_R306) $(DCXO_R306)
wz.wang4cbe62b2024-06-28 11:28:43 +080030.PHONY:copy
31copy:
wz.wang6c460702024-07-01 10:20:35 +080032 cp -rf $(PATH_PRJ)/* .
zw.wangcd454f52024-11-13 17:56:28 +080033ifeq ($(PATCH), yes)
34 cp -rf $(PATH_PRJ)/nand_patch/* .
35else
36 @echo PATCH=no
37endif
w.deng2f3b5c72025-02-25 14:01:30 +080038ifeq ($(CUST),)
39 echo "CUST is empty or not defined"
40else
41 echo "CUST is defined and has a value: $(CUST)"
42 cp -rf $(PATH_PRJ)/$(CUST)/* .
43endif
44
wz.wang4cbe62b2024-06-28 11:28:43 +080045.PHONY:help
46help:
wz.wang6c460702024-07-01 10:20:35 +080047 @echo example prj_cpe_min : make or make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/CPE
zw.wangbd896262024-07-22 18:04:13 +080048 @echo example prj_cpe_aic8800dw : make AP_PRJ=prj_cpe PATH_PRJ=lynq/CPE_AIC8800DW
wz.wang6c460702024-07-01 10:20:35 +080049 @echo example prj_mifi_min_aic8800dw : make AP_PRJ=prj_mifi_min_aic8800dw BOOT_PRJ=mifi_mini_64 PATH_PRJ=lynq/MIFI/ PACK_PRJ=prj_mifi
zw.wangcfae4372024-08-12 16:41:12 +080050 @echo example R305 : make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/R305
zw.wang4f1b5282024-08-14 15:47:35 +080051 @echo example R306 : make AP_PRJ=prj_mifi_min BOOT_PRJ=mifi_mini_64 PACK_PRJ=prj_mifi PATH_PRJ=lynq/R306
mj.qu4cea4592024-08-29 22:35:55 -070052 @echo example CPE_COMMON : make AP_PRJ=prj_mifi_min BOOT_PRJ=mifi_mini_64 PACK_PRJ=prj_mifi PATH_PRJ=lynq/CPE_COMMON
qumengjia90e33962024-09-24 19:15:16 +080053 @echo example CPE_TELKOMSEL : make AP_PRJ=prj_mifi_min BOOT_PRJ=mifi_mini_64 PACK_PRJ=prj_mifi PATH_PRJ=lynq/CPE_TELKOMSEL
qumengjiaa295b332024-11-01 09:35:57 +080054 @echo example R307 : make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/R307
you.chen808f8ef2025-04-02 13:58:10 +080055 @echo example R307L : make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/R307L
qumengjia6d2212e2024-11-14 09:33:12 +080056 @echo example S300 : make AP_PRJ=prj_mifi_min BOOT_PRJ=mifi_mini_64 PACK_PRJ=prj_mifi PATH_PRJ=lynq/S300
mj.quf47abdc2025-01-14 17:23:20 -080057 @echo example S300_COMMON : make AP_PRJ=prj_mifi_min BOOT_PRJ=mifi_mini_64 PACK_PRJ=prj_mifi PATH_PRJ=lynq/S300_COMMON
yuezonghec78e2ef2025-02-13 17:57:46 -080058 @echo example MD310 : make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/MD310
w.deng64d2efd2025-02-26 16:43:45 +080059 @echo example MD310 TSEL/XL/HKM/HIFI: make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/MD310 CUST=TSEL/XL/HKM/HIFI
yuezonghec78e2ef2025-02-13 17:57:46 -080060 @echo example MD310EU : make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/MD310EU
w.dengf34a5312025-03-12 09:47:16 +080061 @echo example MD310EU AFC: make AP_PRJ=prj_cpe_min BOOT_PRJ=ufi_mini PACK_PRJ=prj_cpe PATH_PRJ=lynq/MD310EU CUST=AFC
zw.wangd8c38a42025-02-19 14:25:39 +080062 @echo example S300_AIC : make AP_PRJ=prj_mifi_min BOOT_PRJ=mifi_mini_64 PACK_PRJ=prj_mifi PATH_PRJ=lynq/S300_AIC
you.chen16678562025-02-20 11:26:11 +080063 @echo example R306_MTN : make AP_PRJ=prj_cpe BOOT_PRJ=cpe PACK_PRJ=prj_cpe PATH_PRJ=lynq/R306_MTN
wz.wang4cbe62b2024-06-28 11:28:43 +080064 @echo The default value of AP_PRJ is prj_cpe_min. The following values are optional :
65 @ls ap/project/zx297520v3/*/ -d | xargs -I {} basename "{}" | tr '\n' ' '
66 @echo
67 @echo
68 @echo The default value of BOOT_PRJ is ufi_mini. The following values are optional :
69 @ls boot/prj/zx297520v3/*/ -d | xargs -I {} basename "{}" | tr '\n' ' '
70 @echo
wz.wang6c460702024-07-01 10:20:35 +080071 @echo
72 @echo The default value of PACK_PRJ is prj_cpe. The following values are optional :
73 @ls allbins/zx297520v3/*/ -d | xargs -I {} basename "{}" | tr '\n' ' '
74 @echo
75 @echo
76 @echo The default value of PATH_PRJ is lynq/CPE. The following values are optional :
77 @ls lynq/*/ -d | tr '\n' ' '
78 @echo
zw.wangcd454f52024-11-13 17:56:28 +080079 @echo
80 @echo The default value of PATCH is no. The nand_patch directory is supported as follows :
81 @find lynq -mindepth 1 -maxdepth 2 -name nand_patch | xargs -I {} dirname "{}" | tr '\n' ' '
82 @echo
83 @echo To support the nand_patch directory, add PATCH=yes at the end of compilation.
84 @echo
wz.wang4cbe62b2024-06-28 11:28:43 +080085