• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2021 HiSilicon (Shanghai) Technologies CO., LIMITED.
2#
3# This program is free software; you can redistribute it and/or
4# modify it under the terms of the GNU General Public License
5# as published by the Free Software Foundation; either version 2
6# of the License, or (at your option) any later version.
7#
8# This program is distributed in the hope that it will be useful,
9# but WITHOUT ANY WARRANTY; without even the implied warranty of
10# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11# GNU General Public License for more details.
12#
13# You should have received a copy of the GNU General Public License
14# along with this program; if not, write to the Free Software
15# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
16
17# $(ROOT)/mpp/Makefile
18
19-include $(shell pwd)/../.config
20
21ifeq ($(PARAM_FILE),)
22    PARAM_FILE:=./Makefile.param
23    include $(PARAM_FILE)
24endif
25
26
27
28.PHONY:all prepare cbb component drv vendor clean
29
30sub_dir := prepare cbb component
31
32ifeq ($(CONFIG_INTERDRV), y)
33    sub_dir += interdrv
34endif
35
36
37all: $(sub_dir)
38
39prepare:
40	@cd $(SDK_PATH)/osal/$(OSTYPE) && make
41
42interdrv:
43	@cd $(INTERDRV_ROOT) && make
44
45
46cbb:
47	@cd cbb && make
48
49component:
50	@cd component && make
51
52
53clean:
54ifneq ($(OSTYPE),liteos)
55#	@cd $(SDK_PATH)/mpp/component/securec/src && make clean
56endif
57	@cd $(SDK_PATH)/osal/$(OSTYPE) && make clean
58ifeq ($(CONFIG_INTERDRV), y)
59	@cd $(INTERDRV_ROOT) && make clean
60endif
61	@cd component && make clean
62	@cd cbb && make clean
63	@rm -rf $(REL_KO)/*.ko
64	@rm -rf $(REL_OBJ)/*.o
65	@rm $(REL_KO)/extdrv -fr
66