From a818a2ae601dc1b15ae3cb50f4291f01187f2885 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Mon, 17 Jul 2017 20:54:16 +0200 Subject: [PATCH 1/2] mkosi: support mkosi's --without-tests switch This adds support for the mkosi switch --without-tests that is introduced by: https://github.com/systemd/mkosi/pull/122 With this in place doing "mkosi -ifT shell" is the fastest way from a git clone to a shell within a freshly compiled systemd system. --- mkosi.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkosi.build b/mkosi.build index a36460c6f5..c722e23192 100755 --- a/mkosi.build +++ b/mkosi.build @@ -27,7 +27,7 @@ export LC_CTYPE=C.UTF-8 test -f "$BUILDDIR"/build.ninja || meson "$BUILDDIR" ninja -C "$BUILDDIR" all -ninja -C "$BUILDDIR" test +[ "$WITH_TESTS" = 0 ] || ninja -C "$BUILDDIR" test ninja -C "$BUILDDIR" install mkdir -p "$DESTDIR"/etc From 9400405b4a8ef5f5e32f4b01f0a89ad3c17f3393 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 18 Jul 2017 10:30:52 +0200 Subject: [PATCH 2/2] mkosi: use '[' rather than 'test' everywhere --- mkosi.build | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mkosi.build b/mkosi.build index c722e23192..12e88b909c 100755 --- a/mkosi.build +++ b/mkosi.build @@ -25,7 +25,8 @@ [ -z "$BUILDDIR" ] && BUILDDIR=build export LC_CTYPE=C.UTF-8 -test -f "$BUILDDIR"/build.ninja || meson "$BUILDDIR" + +[ -f "$BUILDDIR"/build.ninja ] || meson "$BUILDDIR" ninja -C "$BUILDDIR" all [ "$WITH_TESTS" = 0 ] || ninja -C "$BUILDDIR" test ninja -C "$BUILDDIR" install