summaryrefslogtreecommitdiff
path: root/os/Makefile
diff options
context:
space:
mode:
authorDevaev Maxim <[email protected]>2018-07-05 15:13:27 +0000
committerDevaev Maxim <[email protected]>2018-07-05 15:13:27 +0000
commit033ad8922c6407bd9e7ca77817afdb4ed40ffc82 (patch)
tree0ac0f0136c44232c37a876066e66013d479d184a /os/Makefile
parentfa3d894172103ab1036140f7f0a61a5c0689f9ab (diff)
new pi-builder
Diffstat (limited to 'os/Makefile')
-rw-r--r--os/Makefile38
1 files changed, 21 insertions, 17 deletions
diff --git a/os/Makefile b/os/Makefile
index f2696448..8b1bcbe5 100644
--- a/os/Makefile
+++ b/os/Makefile
@@ -1,32 +1,36 @@
+_BUILD_DIR=./.build
+
all:
cat Makefile
v1:
make _pikvm PIKVM_PLATFORM=v1
-_pikvm: pi-builder
- rm -rf pi-builder/builder/scripts/pikvm
- cp -a platforms/$(PIKVM_PLATFORM) pi-builder/builder/scripts/pikvm
- cd pi-builder && make _rpi \
+_pikvm: $(_BUILD_DIR)
+ rm -rf $(_BUILD_DIR)/stages/pikvm
+ rm -rf $(_BUILD_DIR)/builder/scripts/pikvm
+ cp -a platforms/$(PIKVM_PLATFORM) $(_BUILD_DIR)/stages/pikvm
+ cd $(_BUILD_DIR) && make _rpi \
PLATFORM=rpi-2 \
BUILDER=pikvm-builder \
- STAGES="base keys watchdog ro pikvm"
+ STAGES="base os ssh watchdog ro pikvm" \
+ HOSTNAME=pikvm
-pi-builder:
- git clone https://github.com/mdevaev/pi-builder --depth=1
+$(_BUILD_DIR):
+ git clone --depth=1 https://github.com/mdevaev/pi-builder $(_BUILD_DIR)
-format: pi-builder
- cd pi-builder && make format
+format: $(_BUILD_DIR)
+ cd $(_BUILD_DIR) && make format
-install: pi-builder
- cd pi-builder && make install
+install: $(_BUILD_DIR)
+ cd $(_BUILD_DIR) && make install
-scan: pi-builder
- cd pi-builder && make scan
+scan: $(_BUILD_DIR)
+ cd $(_BUILD_DIR) && make scan
-clean: pi-builder
- cd pi-builder && make clean
+clean: $(_BUILD_DIR)
+ cd $(_BUILD_DIR) && make clean
clean-all:
- -cd pi-builder && make clean
- rm -rf pi-builder
+ -cd $(_BUILD_DIR) && make clean-all
+ rm -rf $(_BUILD_DIR)