Skip to content
Commit 9cedc5e8 authored by Masahiro Yamada's avatar Masahiro Yamada
Browse files

kbuild: use proper prefix for tarballs to fix rpm-pkg build error

Since commit f8d94c4e ("kbuild: do not create intermediate *.tar
for source tarballs"), 'make rpm-pkg' fails because the prefix of the
source tarball is 'linux.tar/' instead of 'linux/'. $(basename $@)
strips only '.gz' from the filename linux.tar.gz.

You need to strip two suffixes from compressed tarballs and one suffix
from uncompressed tarballs (for example 'perf-6.3.0.tar' generated by
'make perf-tar-src-pkg').

One tricky fix might be --prefix=$(firstword $(subst .tar, ,$@))/
but I think it is better to hard-code the prefix.

Fixes: f8d94c4e

 ("kbuild: do not create intermediate *.tar for source tarballs")
Reported-by: default avatarJiwei Sun <sunjw10@lenovo.com>
Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
Reviewed-by: default avatarNicolas Schier <nicolas@fjasle.eu>
parent 8b824220
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment