From 29288652eaa245ccf7fe591f76460ef228d7dd4d Mon Sep 17 00:00:00 2001 From: Daniil Baturin Date: Mon, 15 Apr 2024 17:17:49 +0000 Subject: build: T3664: add a parameterized make rule for build targets to simplify the now-rather-tricky build script invocation --- Makefile | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 18fd3939..f72d4fd1 100644 --- a/Makefile +++ b/Makefile @@ -7,12 +7,10 @@ all: @echo "Make what specifically?" @echo "The most common target is 'iso'" -.PHONY: iso -.ONESHELL: -iso: clean - set -o pipefail - @./build-vyos-image iso - exit 0 +%: + sudo \ + VYOS_TEMPLATE_DIR=`pwd`/vyos-1x/data/templates/ \ + ./build-vyos-image --reuse-iso vyos-1.5-rolling-202404130016-amd64.iso $* .PHONY: checkiso .ONESHELL: -- cgit v1.2.3 From 008bb5063d6794e5526e2c5ba9fa5e0c2d2866f2 Mon Sep 17 00:00:00 2001 From: Daniil Baturin Date: Mon, 15 Apr 2024 19:05:51 +0000 Subject: build: T3664: correct the parameterized make rule --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index f72d4fd1..e8982735 100644 --- a/Makefile +++ b/Makefile @@ -10,7 +10,7 @@ all: %: sudo \ VYOS_TEMPLATE_DIR=`pwd`/vyos-1x/data/templates/ \ - ./build-vyos-image --reuse-iso vyos-1.5-rolling-202404130016-amd64.iso $* + ./build-vyos-image $* .PHONY: checkiso .ONESHELL: -- cgit v1.2.3 From abb5b518ab1e14801e03779a75f78c0b4f86d804 Mon Sep 17 00:00:00 2001 From: Daniil Baturin Date: Tue, 16 Apr 2024 19:01:00 +0000 Subject: build: T3664: move sudo out of the make target to avoid permission problems --- Makefile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index e8982735..9d8b2d0d 100644 --- a/Makefile +++ b/Makefile @@ -8,9 +8,7 @@ all: @echo "The most common target is 'iso'" %: - sudo \ - VYOS_TEMPLATE_DIR=`pwd`/vyos-1x/data/templates/ \ - ./build-vyos-image $* + VYOS_TEMPLATE_DIR=`pwd`/vyos-1x/data/templates/ ./build-vyos-image $* .PHONY: checkiso .ONESHELL: -- cgit v1.2.3