From 2560e543a1871b86cb1c29b31ce9141eaec94e8c Mon Sep 17 00:00:00 2001 From: "Lance R. Vick" Date: Thu, 20 Jul 2023 18:24:42 -0700 Subject: [PATCH] support path prefix --- Makefile | 1 + scripts/host-env | 2 ++ 2 files changed, 3 insertions(+) diff --git a/Makefile b/Makefile index 3244be3..398175a 100644 --- a/Makefile +++ b/Makefile @@ -318,6 +318,7 @@ define toolchain $(2) \ --env UID=$(UID) \ --env GID=$(GID) \ + --env PATH_PREFIX=$(PATH_PREFIX) \ --platform=linux/$(ARCH) \ --privileged \ --cpus $(CPUS) \ diff --git a/scripts/host-env b/scripts/host-env index 159136d..0464734 100755 --- a/scripts/host-env +++ b/scripts/host-env @@ -5,6 +5,8 @@ uid=${UID?} gid=${GID?} user=${USER:-"build"} export HOME="/home/${user}" +[ ! -z "$PATH_PREFIX" ] && \ + export PATH="${PATH_PREFIX}:${PATH}" # If running user is not root, pivot to custom user/group if [ "$uid" != "0" ]; then