xref: /OK3568_Linux_fs/kernel/drivers/gpu/arm/midgard/Makefile (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun#
2*4882a593Smuzhiyun# (C) COPYRIGHT 2010-2016, 2017 ARM Limited. All rights reserved.
3*4882a593Smuzhiyun#
4*4882a593Smuzhiyun# This program is free software and is provided to you under the terms of the
5*4882a593Smuzhiyun# GNU General Public License version 2 as published by the Free Software
6*4882a593Smuzhiyun# Foundation, and any use by you of this program is subject to the terms
7*4882a593Smuzhiyun# of such GNU licence.
8*4882a593Smuzhiyun#
9*4882a593Smuzhiyun# A copy of the licence is included with the program, and can also be obtained
10*4882a593Smuzhiyun# from Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
11*4882a593Smuzhiyun# Boston, MA  02110-1301, USA.
12*4882a593Smuzhiyun#
13*4882a593Smuzhiyun#
14*4882a593Smuzhiyun
15*4882a593Smuzhiyun
16*4882a593Smuzhiyun
17*4882a593SmuzhiyunKDIR ?= /lib/modules/$(shell uname -r)/build
18*4882a593Smuzhiyun
19*4882a593SmuzhiyunBUSLOG_PATH_RELATIVE = $(CURDIR)/../../../..
20*4882a593SmuzhiyunUMP_PATH_RELATIVE = $(CURDIR)/../../../base/ump
21*4882a593SmuzhiyunKBASE_PATH_RELATIVE = $(CURDIR)
22*4882a593SmuzhiyunKDS_PATH_RELATIVE = $(CURDIR)/../../../..
23*4882a593SmuzhiyunEXTRA_SYMBOLS = $(UMP_PATH_RELATIVE)/src/Module.symvers
24*4882a593Smuzhiyun
25*4882a593Smuzhiyunifeq ($(MALI_UNIT_TEST), 1)
26*4882a593Smuzhiyun	EXTRA_SYMBOLS += $(KBASE_PATH_RELATIVE)/tests/internal/src/kernel_assert_module/linux/Module.symvers
27*4882a593Smuzhiyunendif
28*4882a593Smuzhiyun
29*4882a593Smuzhiyunifeq ($(MALI_BUS_LOG), 1)
30*4882a593Smuzhiyun#Add bus logger symbols
31*4882a593SmuzhiyunEXTRA_SYMBOLS += $(BUSLOG_PATH_RELATIVE)/drivers/base/bus_logger/Module.symvers
32*4882a593Smuzhiyunendif
33*4882a593Smuzhiyun
34*4882a593Smuzhiyun# GPL driver supports KDS
35*4882a593SmuzhiyunEXTRA_SYMBOLS += $(KDS_PATH_RELATIVE)/drivers/base/kds/Module.symvers
36*4882a593Smuzhiyun
37*4882a593Smuzhiyun# we get the symbols from modules using KBUILD_EXTRA_SYMBOLS to prevent warnings about unknown functions
38*4882a593Smuzhiyunall:
39*4882a593Smuzhiyun	$(MAKE) -C $(KDIR) M=$(CURDIR) EXTRA_CFLAGS="-I$(CURDIR)/../../../../include -I$(CURDIR)/../../../../tests/include $(SCONS_CFLAGS)" $(SCONS_CONFIGS) KBUILD_EXTRA_SYMBOLS="$(EXTRA_SYMBOLS)" modules
40*4882a593Smuzhiyun
41*4882a593Smuzhiyunclean:
42*4882a593Smuzhiyun	$(MAKE) -C $(KDIR) M=$(CURDIR) clean
43