summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJürg Billeter <j@bitron.ch>2019-12-05 05:52:33 +0100
committerJürg Billeter <j@bitron.ch>2019-12-17 14:18:11 +0100
commit7ffd9a7ebf417624d948117938ecda26e87bbbd2 (patch)
treeda22499c929eb7823e801bde04a807dd333a0881
parentcea7e315b1e7776189cb8575f6687971977d1cd6 (diff)
downloadbuildstream-7ffd9a7ebf417624d948117938ecda26e87bbbd2.tar.gz
testing/_utils/site.py: Add BUILDBOX_RUN variable
-rw-r--r--src/buildstream/testing/_utils/site.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/buildstream/testing/_utils/site.py b/src/buildstream/testing/_utils/site.py
index f3b45dbf6..9fbddf13e 100644
--- a/src/buildstream/testing/_utils/site.py
+++ b/src/buildstream/testing/_utils/site.py
@@ -82,3 +82,12 @@ if HAVE_SANDBOX is not None:
pass
elif IS_LINUX and HAVE_BWRAP and (not IS_WSL):
HAVE_SANDBOX = "bwrap"
+
+
+BUILDBOX_RUN = None
+if HAVE_SANDBOX == "buildbox-run":
+ try:
+ path = utils.get_host_tool("buildbox-run")
+ BUILDBOX_RUN = os.path.basename(os.readlink(path))
+ except (ProgramNotFoundError, OSError):
+ pass