-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathMakefile.extra
More file actions
73 lines (58 loc) · 1.94 KB
/
Makefile.extra
File metadata and controls
73 lines (58 loc) · 1.94 KB
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
66
67
68
69
70
71
72
73
# This file is auto generated by rsdk infra-package-update.
# DO NOT EDIT IT DIRECTLY!
# Custom rules should be placed in .github/local/Makefile.local
KERNEL_FORK ?= qcom
ARCH ?= arm64
CROSS_COMPILE ?= aarch64-linux-gnu-
DPKG_FLAGS ?= -d
KERNEL_DEFCONFIG ?= defconfig radxa.config
CUSTOM_ENV_DEFINITIONS ?=
CUSTOM_MAKE_DEFINITIONS ?=
SUPPORT_CLEAN ?= true
KMAKE ?= $(CUSTOM_ENV_DEFINITIONS) $(MAKE) -C "$(SRC-KERNEL)" -j$(shell nproc) \
$(CUSTOM_MAKE_DEFINITIONS) \
ARCH=$(ARCH) CROSS_COMPILE=$(CROSS_COMPILE) HOSTCC=$(CROSS_COMPILE)gcc \
KDEB_COMPRESS="xz" KDEB_CHANGELOG_DIST="unstable" DPKG_FLAGS=$(DPKG_FLAGS) \
LOCALVERSION=-$(shell dpkg-parsechangelog -S Version | cut -d "-" -f 2)-$(KERNEL_FORK) \
KERNELRELEASE=$(shell dpkg-parsechangelog -S Version)-$(KERNEL_FORK) \
KDEB_PKGVERSION=$(shell dpkg-parsechangelog -S Version)
post_build_dep: arm64_crossbuild_dep
#
# Build
#
.PHONY: build
build: pre_build build-defconfig build-bindeb post_build
SRC-KERNEL ?= src
.PHONY: build-defconfig
build-defconfig: $(SRC-KERNEL)
$(KMAKE) $(KERNEL_DEFCONFIG)
.PHONY: build-modules
build-modules: $(SRC-KERNEL)
$(KMAKE) modules
.PHONY: build-all
build-all: $(SRC-KERNEL)
$(KMAKE) all
.PHONY: build-bindeb
build-bindeb: $(SRC-KERNEL) build-all
$(KMAKE) bindeb-pkg
mv linux-*_arm64.deb linux-upstream*_arm64.changes linux-upstream*_arm64.buildinfo ../
.PHONY: build-dtbs
build-dtbs: $(SRC-KERNEL)
$(KMAKE) defconfig dtbs
#
# Clean
#
.PHONY: distclean
distclean: clean
if [ "$(SUPPORT_CLEAN)" = "true" ]; then $(KMAKE) distclean; fi
.PHONY: clean
clean: clean-deb
if [ "$(SUPPORT_CLEAN)" = "true" ]; then $(KMAKE) clean; fi
.PHONE: clean-build
clean-build:
rm -rf debian/linux-*/ linux-*_arm64.deb linux-upstream*_arm64.changes linux-upstream*_arm64.buildinfo
.PHONY: clean-deb
clean-deb: clean-build
# This file is auto generated by rsdk infra-package-update.
# DO NOT EDIT IT DIRECTLY!
# Custom rules should be placed in .github/local/Makefile.local