blob: 08c3bb3069ea54fcd32b3d164c94ea36493508d8 [file] [log] [blame]
Yue Lun03a82d92013-10-21 10:15:02 +08001
2include $(PRJ_PATH)/config
3
4ifndef SYS_PATH
5 $(error SYS_PATH isn't defined!)
6endif
7
8ifndef TOOL_PATH
9 $(error TOOL_PATH isn't defined!)
10endif
11
12#define cpu type such as PPC MIPS ARM X86
13ifndef CPU
14 CPU=mips
15endif
16
17#define os type such as linux netbsd vxworks
18ifndef OS
19 OS=linux
20endif
21
22ifndef OS_VER
23 OS_VER=2_6
24endif
25
26#support chip type such as ATHENA GARUDA
27ifndef CHIP_TYPE
28 SUPPORT_CHIP = GARUDA
29else
30 ifeq (GARUDA, $(CHIP_TYPE))
31 SUPPORT_CHIP = GARUDA
32 endif
33
34 ifeq (ATHENA, $(CHIP_TYPE))
35 SUPPORT_CHIP = ATHENA
36 endif
37
38 ifeq (SHIVA, $(CHIP_TYPE))
39 SUPPORT_CHIP = SHIVA
40 endif
41
42 ifeq (HORUS, $(CHIP_TYPE))
43 SUPPORT_CHIP = HORUS
44 endif
45
46 ifeq (ISIS, $(CHIP_TYPE))
47 SUPPORT_CHIP = ISIS
48 endif
49
50 ifeq (ISISC, $(CHIP_TYPE))
51 SUPPORT_CHIP = ISISC
52 endif
53
linchend4b91d02014-11-28 23:04:44 +080054 ifeq (DESS, $(CHIP_TYPE))
55 SUPPORT_CHIP = DESS
56 endif
57
Yue Lun03a82d92013-10-21 10:15:02 +080058 ifeq (ALL_CHIP, $(CHIP_TYPE))
59 ifneq (TRUE, $(FAL))
60 $(error FAL must be TRUE when CHIP_TYPE is defined as ALL_CHIP!)
61 endif
linchend4b91d02014-11-28 23:04:44 +080062 SUPPORT_CHIP = ISIS ISISC SHIVA DESS
Yue Lun03a82d92013-10-21 10:15:02 +080063 endif
64
65 ifndef SUPPORT_CHIP
66 $(error defined CHIP_TYPE isn't supported!)
67 endif
68endif
69
70#define compile tool prefix
71ifndef TOOLPREFIX
72 TOOLPREFIX=$(CPU)-$(OS)-uclibc-
73endif
74
75DEBUG_ON=FALSE
76OPT_FLAG=
77LD_FLAG=
78
79SHELLOBJ=ssdk_sh
80US_MOD=ssdk_us
81KS_MOD=ssdk_ks
82
83ifeq (TRUE, $(KERNEL_MODE))
84 RUNMODE=km
85else
86 RUNMODE=um
87endif
88
Yue Lundd6e3d92013-10-25 13:03:31 +080089BLD_DIR=$(PRJ_PATH)/build/$(OS)
Yue Lun03a82d92013-10-21 10:15:02 +080090BIN_DIR=$(PRJ_PATH)/build/bin
91
xiaofeis505213e2014-10-20 19:43:49 +080092VER=1.3.0
Yue Lun03a82d92013-10-21 10:15:02 +080093BUILD_NUMBER=$(shell cat $(PRJ_PATH)/make/.build_number)
94VERSION=$(VER).$(BUILD_NUMBER)
95BUILD_DATE=$(shell date -u +%F-%T)