do a "defconfig + elconfig" to get a .config
- Copy rhel/diff.config to config-aarch64. - Enable building the kernel config in such a way that the defconfig's options are _used_ but certain RHEL-specific options are overridden. - The build salt got carried over from the RHEL diff.config, remove that. - Unset CONFIG_DEBUG_INFO_REDUCED so that CONFIG_DEBUG_INFO_BTF can be enabled. Otherwise the build fails at the step where the bpftool package gets built.
This commit is contained in:
parent
ff349cb793
commit
30d3add7d3
9170
config-aarch64
9170
config-aarch64
File diff suppressed because it is too large
Load Diff
@ -128,7 +128,8 @@
|
|||||||
%define bldarch x86_64
|
%define bldarch x86_64
|
||||||
%define hdrarch x86_64
|
%define hdrarch x86_64
|
||||||
%define make_target bzImage
|
%define make_target bzImage
|
||||||
%define kernel_image arch/x86/boot/bzImage
|
%define kernel_image arch/%{asmarch}/boot/%{make_target}
|
||||||
|
%define defconfig arch/%{asmarch}/configs/%{bldarch}_defconfig
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%ifarch aarch64
|
%ifarch aarch64
|
||||||
@ -136,9 +137,12 @@
|
|||||||
%define bldarch arm64
|
%define bldarch arm64
|
||||||
%define hdrarch arm64
|
%define hdrarch arm64
|
||||||
%define make_target Image.gz
|
%define make_target Image.gz
|
||||||
%define kernel_image arch/arm64/boot/Image.gz
|
%define kernel_image arch/%{asmarch}/boot/%{make_target}
|
||||||
|
%define defconfig arch/%{asmarch}/configs/defconfig
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
%define elconfig arch/%{asmarch}/configs/el.config
|
||||||
|
|
||||||
%if %{with_vdso_install}
|
%if %{with_vdso_install}
|
||||||
%define use_vdso 1
|
%define use_vdso 1
|
||||||
%define _use_vdso 1
|
%define _use_vdso 1
|
||||||
@ -555,19 +559,19 @@ pathfix.py -i "%{__python3} %{py3_shbang_opts}" -n -p \
|
|||||||
|
|
||||||
mv COPYING COPYING-%{version}-%{release}
|
mv COPYING COPYING-%{version}-%{release}
|
||||||
|
|
||||||
cp -a %{SOURCE2} .
|
cp %{_sourcedir}/config-$(uname -m) %{elconfig}
|
||||||
cp -a %{SOURCE4} .
|
|
||||||
|
|
||||||
# Set the EXTRAVERSION string in the top level Makefile.
|
# Set the EXTRAVERSION string in the top level Makefile.
|
||||||
sed -i "s@^EXTRAVERSION.*@EXTRAVERSION = -%{release}.%{_target_cpu}@" Makefile
|
sed -i "s@^EXTRAVERSION.*@EXTRAVERSION = -%{release}.%{_target_cpu}@" Makefile
|
||||||
|
|
||||||
%ifarch x86_64 || aarch64
|
%ifarch x86_64 || aarch64
|
||||||
cp config-%{_target_cpu} .config
|
./scripts/kconfig/merge_config.sh %{defconfig} %{elconfig}
|
||||||
%{__make} ARCH=%{bldarch} listnewconfig | grep -E '^CONFIG_' > newoptions-el9-%{_target_cpu}.txt || true
|
%{__make} ARCH=%{bldarch} listnewconfig | grep -E '^CONFIG_' > newoptions-el9-%{_target_cpu}.txt || true
|
||||||
if [ -s newoptions-el9-%{_target_cpu}.txt ]; then
|
if [ -s newoptions-el9-%{_target_cpu}.txt ]; then
|
||||||
cat newoptions-el9-%{_target_cpu}.txt
|
cat newoptions-el9-%{_target_cpu}.txt
|
||||||
fi
|
fi
|
||||||
rm -f newoptions-el9-%{_target_cpu}.txt
|
rm -f newoptions-el9-%{_target_cpu}.txt
|
||||||
|
rm -vf .config*
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# Add DUP and kpatch certificates to system trusted keys for RHEL.
|
# Add DUP and kpatch certificates to system trusted keys for RHEL.
|
||||||
@ -575,17 +579,17 @@ rm -f newoptions-el9-%{_target_cpu}.txt
|
|||||||
openssl x509 -inform der -in %{SOURCE100} -out rheldup3.pem
|
openssl x509 -inform der -in %{SOURCE100} -out rheldup3.pem
|
||||||
openssl x509 -inform der -in %{SOURCE101} -out rhelkpatch1.pem
|
openssl x509 -inform der -in %{SOURCE101} -out rhelkpatch1.pem
|
||||||
cat rheldup3.pem rhelkpatch1.pem > certs/rhel.pem
|
cat rheldup3.pem rhelkpatch1.pem > certs/rhel.pem
|
||||||
for i in config-*; do
|
for i in %{elconfig}; do
|
||||||
sed -i 's@CONFIG_SYSTEM_TRUSTED_KEYS="*"@CONFIG_SYSTEM_TRUSTED_KEYS="certs/rhel.pem"@' $i
|
sed -i 's@CONFIG_SYSTEM_TRUSTED_KEYS="*"@CONFIG_SYSTEM_TRUSTED_KEYS="certs/rhel.pem"@' $i
|
||||||
done
|
done
|
||||||
%else
|
%else
|
||||||
for i in config-*; do
|
for i in %{elconfig}; do
|
||||||
sed -i 's@CONFIG_SYSTEM_TRUSTED_KEYS="*"@CONFIG_SYSTEM_TRUSTED_KEYS=""@' $i
|
sed -i 's@CONFIG_SYSTEM_TRUSTED_KEYS="*"@CONFIG_SYSTEM_TRUSTED_KEYS=""@' $i
|
||||||
done
|
done
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# Adjust the FIPS module name for RHEL9.
|
# Adjust the FIPS module name for RHEL9.
|
||||||
for i in config-*; do
|
for i in %{elconfig}; do
|
||||||
sed -i 's@CONFIG_CRYPTO_FIPS_NAME=.*@CONFIG_CRYPTO_FIPS_NAME="Red Hat Enterprise Linux 9 - Kernel Cryptographic API"@' $i
|
sed -i 's@CONFIG_CRYPTO_FIPS_NAME=.*@CONFIG_CRYPTO_FIPS_NAME="Red Hat Enterprise Linux 9 - Kernel Cryptographic API"@' $i
|
||||||
done
|
done
|
||||||
|
|
||||||
@ -597,9 +601,7 @@ popd > /dev/null
|
|||||||
pushd linux-%{KVERREL} > /dev/null
|
pushd linux-%{KVERREL} > /dev/null
|
||||||
|
|
||||||
%ifarch x86_64 || aarch64
|
%ifarch x86_64 || aarch64
|
||||||
cp config-%{_target_cpu} .config
|
./scripts/kconfig/merge_config.sh %{defconfig} %{elconfig}
|
||||||
|
|
||||||
%{__make} ARCH=%{bldarch} oldconfig
|
|
||||||
|
|
||||||
%if %{signkernel} || %{signmodules}
|
%if %{signkernel} || %{signmodules}
|
||||||
cp %{SOURCE23} certs/
|
cp %{SOURCE23} certs/
|
||||||
|
Loading…
Reference in New Issue
Block a user