Building the kernel packages for debian on armhf with make deb-pkg fails for some configurations with error: /usr/bin/xargs: md5sum: Argument list too long [...]/scripts/package/Makefile:90: recipe for target 'deb-pkg' failed make[1]: *** [deb-pkg] Error 126 Makefile:1163: recipe for target 'deb-pkg' failed make: *** [deb-pkg] Error 2 It can be fixed in scripts/package/builddeb with something like: --- linux-org/scripts/package/builddeb 2015-03-24 10:11:29.000000000 +0100 +++ linux-new/scripts/package/builddeb 2016-07-30 08:42:11.112361239 +0200 @@ -18,8 +18,8 @@ cp debian/copyright "$pdir/usr/share/doc/$pname/" cp debian/changelog "$pdir/usr/share/doc/$pname/changelog.Debian" gzip -9 "$pdir/usr/share/doc/$pname/changelog.Debian" - sh -c "cd '$pdir'; find . -type f ! -path './DEBIAN/*' -printf '%P\0' \ - | xargs -r0 md5sum > DEBIAN/md5sums" + sh -c "cd '$pdir'; find . -type f ! -path './DEBIAN/*' -exec md5sum '{}' ';' \ + | sed -re 's:^([0-9a-f][0-9a-f]* )./:\1:' > DEBIAN/md5sums" # Fix ownership and permissions chown -R root:root "$pdir"