spec: do not recompute the build-id of vmlinux

Since rpm-build version 4.14.0-rc1(commit id: 4842adf), the new code
will recompute the build-id of vmlinux when generating debuginfo, and
results that the build-id is different from the boot image. Some debug
tools, like perf, when we use `-k` to specify vmlinux, it would refuse
to load vmlinux while detecing the build-id is different between vmlinux
and the current boot image.

We can use `$ file vmlinux` or `$ objdump -s -j .notes` to check
vmlinux's build-id, and `$ hexdump /sys/kernel/notes` to check current
boot image build-id.

This patch is prevent build-id changing from generating debuginfo
package.

Signed-off-by: fu.lin <fu.lin10@huawei.com>
Signed-off-by: yanglei <yanglei209@huawei.com>
This commit is contained in:
fu.lin 2020-12-26 03:09:04 +00:00
parent 085f93a6e2
commit dcece5b76b

View File

@ -1,4 +1,3 @@
%define with_signmodules 1
%define with_kabichk 0
@ -16,6 +15,13 @@
%global pkg_release .7
%define with_debuginfo 1
# Do not recompute the build-id of vmlinux in find-debuginfo.sh
%global _missing_build_ids_terminate_build 1
%global _no_recompute_build_ids 1
%undefine _include_minidebuginfo
%undefine _include_gdb_index
%undefine _unique_build_ids
%define with_source 1
%define with_python2 0