blob: 6a98cfafc3f76b173a1bbc16492b689e8488f057 [file] [log] [blame]
rjw1f884582022-01-06 17:20:42 +08001ifeq (y,$(CONFIG_MODULES))
2
3ifeq ($(CONFIG_FTRACE),y)
4 ifeq ($(CONFIG_TRACING),y)
5 FTRACE_READY := y
6 endif
7endif
8
9#PLATFORM := $(subst ",,$(CONFIG_MTK_PLATFORM))
10PLATFORM := mt2712
11MET_COMMON_USE := yes
12
13$(info ******** Start to build met_drv for $(PLATFORM) ********)
14
15
16ifeq ($(MET_COMMON_USE),yes)
17 # met common code structure, new build flow
18 MET_COMMON_DIR := $(src)/common
19 ifeq ($(FTRACE_READY),y)
20 include $(MET_COMMON_DIR)/Kbuild
21 ccflags-y += -DCONFIG_MET_MODULE -DMET_PLF_USE
22 ccflags-y += -I$(MET_COMMON_DIR)/
23 else
24 $(warning Not building met.ko due to CONFIG_FTRACE/CONFIG_TRACING is not set)
25 endif
26else
27 $(warning not support $(PLATFORM), build met default)
28 MET_DEF_DIR := $(src)
29 include $(MET_DEF_DIR)/default/Kbuild
30endif
31else
32$(warning Not building met.ko due to CONFIG_MODULES is not set)
33endif