summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2014-12-07 16:18:58 +0100
committerDave Reisner <dreisner@archlinux.org>2014-12-28 23:45:31 +0100
commit514d5f1fa641b0bfc66d43f4c0c7e7830f747899 (patch)
treed82e6ec7503c9173a477de3cd5852fed26d9e607
parentb209e8c5e965965c50878fb57a628bca83a06f8d (diff)
downloadmkinitcpio-514d5f1fa641b0bfc66d43f4c0c7e7830f747899.tar.gz
mkinitcpio-514d5f1fa641b0bfc66d43f4c0c7e7830f747899.tar.xz
mkinitcpio avoiding adding a CPIO entry for '.'
The archive goes from looking like this: . ./buildconfig ./config ./init ./init_functions ./VERSION ./lib64 ./sbin To: buildconfig config init init_functions VERSION lib64 sbin Note the lack of the "root" entry and leading "./". This fixes an issue with packing ucode into the initramfs since the kernel really wants an exact match, and not path equivalency.
-rwxr-xr-xmkinitcpio2
1 files changed, 1 insertions, 1 deletions
diff --git a/mkinitcpio b/mkinitcpio
index 01fe8ba..d2d7ea8 100755
--- a/mkinitcpio
+++ b/mkinitcpio
@@ -222,7 +222,7 @@ build_image() {
fi
pushd "$BUILDROOT" >/dev/null
- find . -print0 |
+ find -mindepth 1 -printf '%P\0' |
LANG=C bsdcpio "${cpio_opts[@]}" |
$compress $COMPRESSION_OPTIONS > "$out"
pipesave=("${PIPESTATUS[@]}") # save immediately