diff --git a/mkosi.conf.d/10-arch/mkosi.build.chroot b/mkosi.conf.d/10-arch/mkosi.build.chroot index 2c99a67a252..268bdc2ee74 100755 --- a/mkosi.conf.d/10-arch/mkosi.build.chroot +++ b/mkosi.conf.d/10-arch/mkosi.build.chroot @@ -33,7 +33,7 @@ if ((LLVM)) && [[ -n "$SANITIZERS" ]]; then fi MKOSI_MESON_OPTIONS="-D mode=developer -D b_sanitize=${SANITIZERS:-none}" -if ((WIPE)); then +if ((WIPE)) && [[ -d "$BUILDDIR/meson-private" ]]; then MKOSI_MESON_OPTIONS="$MKOSI_MESON_OPTIONS --wipe" fi diff --git a/mkosi.conf.d/10-centos-fedora/mkosi.build.chroot b/mkosi.conf.d/10-centos-fedora/mkosi.build.chroot index 21f106292bb..2b3341ccbd7 100755 --- a/mkosi.conf.d/10-centos-fedora/mkosi.build.chroot +++ b/mkosi.conf.d/10-centos-fedora/mkosi.build.chroot @@ -62,7 +62,7 @@ if ((LLVM)) && [[ -n "$SANITIZERS" ]]; then fi MKOSI_MESON_OPTIONS="-D mode=developer -D b_sanitize=${SANITIZERS:-none}" -if ((WIPE)); then +if ((WIPE)) && [[ -d "$BUILDDIR/meson-private" ]]; then MKOSI_MESON_OPTIONS="$MKOSI_MESON_OPTIONS --wipe" fi diff --git a/mkosi.conf.d/10-debian-ubuntu/mkosi.build.chroot b/mkosi.conf.d/10-debian-ubuntu/mkosi.build.chroot index f1eed039246..1a03dcd9564 100755 --- a/mkosi.conf.d/10-debian-ubuntu/mkosi.build.chroot +++ b/mkosi.conf.d/10-debian-ubuntu/mkosi.build.chroot @@ -56,7 +56,7 @@ if ((LLVM)) && [[ -n "$SANITIZERS" ]]; then fi MKOSI_MESON_OPTIONS="-D mode=developer -D b_sanitize=${SANITIZERS:-none}" -if ((WIPE)); then +if ((WIPE)) && [[ -d "$BUILDDIR/meson-private" ]]; then MKOSI_MESON_OPTIONS="$MKOSI_MESON_OPTIONS --wipe" fi diff --git a/mkosi.conf.d/10-opensuse/mkosi.build.chroot b/mkosi.conf.d/10-opensuse/mkosi.build.chroot index 67481d0b10c..286fd582a60 100755 --- a/mkosi.conf.d/10-opensuse/mkosi.build.chroot +++ b/mkosi.conf.d/10-opensuse/mkosi.build.chroot @@ -63,7 +63,7 @@ if [[ -z "${MKOSI_LDFLAGS// }" ]]; then fi MKOSI_MESON_OPTIONS="-D mode=developer -D b_sanitize=${SANITIZERS:-none}" -if ((WIPE)); then +if ((WIPE)) && [[ -d "$BUILDDIR/meson-private" ]]; then MKOSI_MESON_OPTIONS="$MKOSI_MESON_OPTIONS --wipe" fi