forked from ayufan-rock64/linux-build
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.dev.mk
45 lines (40 loc) · 1.28 KB
/
Makefile.dev.mk
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
.PHONY: info
info:
@echo version: $$(KERNEL_VERSION)
@echo release: $$(KERNEL_RELEASE)
.PHONY: help
help:
@echo Available targets:
@grep -h '^.PHONY: .*#' Makefile* | cut -d: -f2- | expand -t20 | sort
@echo
@echo Extra targets:
@echo " " $$(grep -h '^.PHONY: [^#]*$$' Makefile* | cut -d: -f2- | sort)
arm-trusted-firmware kernel kernel-mainline u-boot:
@echo Run "make sync"
@exit 1
.PHONY: sync # download all subtrees
sync:
repo init -u https://github.com/pfeerick-rock64/linux-manifests -b default --depth=1 --no-clone-bundle
repo sync -j 20 -c --force-sync
.PHONY: pull-trees # merge all subtree into current tree
pull-trees:
git subtree pull --prefix build https://github.com/rockchip-linux/build debian
git subtree pull --prefix build https://github.com/rock64-linux/build debian
.PHONY: shell # run docker shell to build image
shell:
@echo Entering shell...
@docker run --rm \
-it \
-e HOME -v $(HOME):$(HOME) \
-e USER \
-u $$(id -u):$$(id -g) \
$$(id -Gz | xargs -0 -n1 -I{} echo "--group-add={}") \
-v /etc/passwd:/etc/passwd:ro \
-v /dev/bus/usb:/dev/bus/usb \
-v $(SSH_AUTH_SOCK):$(SSH_AUTH_SOCK) \
-e SSH_AUTH_SOCK \
--privileged \
-h rock64-build-env \
-v $(CURDIR):$(CURDIR) \
-w $(CURDIR) \
pfeerick/rock64-dockerfiles:x86_64