diff --git a/mkosi.images/build/mkosi.conf.d/debian-ubuntu/mkosi.build.chroot b/mkosi.images/build/mkosi.conf.d/debian-ubuntu/mkosi.build.chroot index b17483a03f..569bf64499 100755 --- a/mkosi.images/build/mkosi.conf.d/debian-ubuntu/mkosi.build.chroot +++ b/mkosi.images/build/mkosi.conf.d/debian-ubuntu/mkosi.build.chroot @@ -111,8 +111,9 @@ if ! build; then if [[ -f debian/not-installed ]]; then pushd debian/tmp grep --invert-match "^#" ../not-installed | - xargs -I {} bash -O nullglob -c "printf '%s\n' {}" | - sed "/^$/d" | + xargs -I {} sh -c "test -d '{}' && echo '{}/**/*' || echo '{}'" | + xargs -I {} bash -O nullglob -O globstar -c "printf '%s\n' {}" | + sed --expression "/^$/d" --expression "s#//*#/#g" | xargs -I {} sh -c "test -f '{}' && echo '{}' || true" >>/tmp/packaged-files popd fi