forked from intel-gpu/intel-gpu-i915-backports
-
Notifications
You must be signed in to change notification settings - Fork 29
/
Makefile.kernel
65 lines (56 loc) · 1.8 KB
/
Makefile.kernel
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
ifeq ($(CONFIG_BACKPORT_INTEGRATE),)
# Since 2.6.21, try-run is available, but cc-disable-warning
# was only added later, so we add it here ourselves:
backport-cc-disable-warning = $(call try-run,\
$(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) -W$(strip $(1)) -c -x c /dev/null -o "$$TMP",-Wno-$(strip $(1)))
NOSTDINC_FLAGS := \
-I$(M)/backport-include \
-I$(M)/backport-include/uapi \
$(call backport-cc-disable-warning, unused-but-set-variable) \
-DCPTCFG_BACKPORTS_RELEASE_TAG=\"$(BACKPORTS_RELEASE_TAG)\" \
-DCPTCFG_DII_KERNEL_HEAD=\"$(DII_KERNEL_HEAD)\" \
-DCPTCFG_BASE_KERNEL_NAME=\"$(BASE_KERNEL_NAME)\" \
-DCPTCFG_DII_KERNEL_TAG=\"$(DII_KERNEL_TAG)\" \
$(BACKPORTS_GIT_TRACKER_DEF) \
ifneq ("$(CPTCFG_I915_NO_DRM)", "y")
NOSTDINC_FLAGS += \
-I$(M)/i915-include \
-I$(M)/drm-include \
-I$(M)/i915-include/uapi \
-I$(M)/drm-include/uapi \
-include $(M)/backport-include/backport/backport.h \
$(CFLAGS)
else
NOSTDINC_FLAGS += \
-I$(M)/i915-include \
-I$(M)/i915-include/uapi \
-include $(M)/backport-include/backport/backport.h \
$(CFLAGS)
endif
export backport_srctree = $(M)
else
export BACKPORT_DIR = backports/
export backport_srctree = $(BACKPORT_DIR)
NOSTDINC_FLAGS := \
-I$(BACKPORT_DIR)/backport-include/ \
-I$(BACKPORT_DIR)/backport-include/uapi \
-I$(BACKPORT_DIR)/include/ \
-I$(BACKPORT_DIR)/include/drm \
-I$(BACKPORT_DIR)/include/uapi \
-include $(BACKPORT_DIR)/backport-include/backport/backport.h \
$(CFLAGS)
endif
obj-y += compat/
ifeq (y,$(filter y,$(CPTCFG_ONLY_DMABUF) $(CPTCFG_BUILD_DMABUF_I915_MEI)))
ifneq ("$(CPTCFG_I915_NO_DRM)", "y")
obj-y += drivers/dma-buf/
endif
endif
ifeq (y,$(filter y,$(CPTCFG_ONLY_I915) $(CPTCFG_BUILD_DMABUF_I915_MEI)))
ifeq ("$(CPTCFG_I915_NO_DRM)", "y")
obj-y += drivers/gpu/drm/i915/
else
obj-y += drivers/gpu/drm/
obj-y += drivers/char/agp/
endif
endif