diff --git a/kernel.spec b/kernel.spec index 7ceef2a..12b2343 100644 --- a/kernel.spec +++ b/kernel.spec @@ -5,14 +5,13 @@ %global Arch $(echo %{_host_cpu} | sed -e s/i.86/x86/ -e s/x86_64/x86/ -e s/aarch64.*/arm64/) -%global KernelVer %{version}-%{release}.%{_target_cpu} %global debuginfodir /usr/lib/debug %global upstream_version 5.10 %global upstream_sublevel 0 %global devel_release 176 %global maintenance_release .0.0 -%global pkg_release .89 +%global pkg_release .90 %define with_debuginfo 1 # Do not recompute the build-id of vmlinux in find-debuginfo.sh @@ -33,11 +32,15 @@ %define with_64kb %{?_with_64kb: 1} %{?!_with_64kb: 0} %if %{with_64kb} %global package64kb -64kb +%global kv_suffix +64kb +%define with_kabichk 0 %endif %else %define with_64kb 0 %endif +%global KernelVer %{version}-%{release}.%{_target_cpu}%{?kv_suffix} + #default is enabled. You can disable it with --without option %define with_perf %{?_without_perf: 0} %{?!_without_perf: 1} @@ -156,6 +159,7 @@ Requires: perl findutils This package provides kernel headers and makefiles sufficient to build modules against the %{KernelVer} kernel package. +%if !%{with_64kb} %package tools Summary: Assortment of tools for the Linux kernel Provides: %{name}-tools-libs @@ -209,6 +213,7 @@ language to use the interface to manipulate perf events. Summary: the kernel source %description source This package contains vaious source files from the kernel. +%endif %if 0%{?with_debuginfo} %define _debuginfo_template %{nil} @@ -226,6 +231,10 @@ Debug information is useful when developing applications that use this\ package or when debugging this package.\ %{nil} +%if %{with_64kb} +%debuginfo_template -n kernel-64kb +%files -n kernel-64kb-debuginfo -f debugfiles.list +%else %debuginfo_template -n kernel %files -n kernel-debuginfo -f debugfiles.list @@ -249,7 +258,8 @@ package or when debugging this package.\ %{expand:%%global _find_debuginfo_opts %{?_find_debuginfo_opts} -p '.*%{python3_sitearch}/perf.*(.debug)?|XXX' -o python3-perf-debugfiles.list} #with_perf %endif - +#with_64kb +%endif %endif %prep @@ -320,7 +330,7 @@ cp -a tools/perf tools/python3-perf %build cd linux-%{KernelVer} -perl -p -i -e "s/^EXTRAVERSION.*/EXTRAVERSION = -%{release}.%{_target_cpu}/" Makefile +perl -p -i -e "s/^EXTRAVERSION.*/EXTRAVERSION = -%{release}.%{_target_cpu}%{?kv_suffix}/" Makefile ## make linux make mrproper %{_smp_mflags} @@ -429,6 +439,7 @@ make BPFTOOL=../../tools/bpf/bpftool/bpftool popd %install +%if !%{with_64kb} %if 0%{?with_source} %define _python_bytecompile_errors_terminate_build 0 mkdir -p $RPM_BUILD_ROOT/usr/src/ @@ -436,6 +447,7 @@ popd cp linux-%{KernelVer}/.config $RPM_BUILD_ROOT/usr/src/linux-%{KernelVer}/ cp linux-%{KernelVer}/.scmversion $RPM_BUILD_ROOT/usr/src/linux-%{KernelVer}/ %endif +%endif cd linux-%{KernelVer} @@ -642,6 +654,7 @@ popd ## install tools +%if !%{with_64kb} %if %{with_perf} # perf # perf tool binary and supporting scripts/binaries @@ -719,6 +732,7 @@ popd pushd tools/netacc make INSTALL_ROOT=%{buildroot} install popd +%endif %define __spec_install_post\ %{?__debug_package:%{__debug_install_post}}\ @@ -775,6 +789,7 @@ then done) fi +%if !%{with_64kb} %post -n %{name}-tools /sbin/ldconfig %systemd_post cpupower.service @@ -785,6 +800,7 @@ fi %postun -n %{name}-tools /sbin/ldconfig %systemd_postun cpupower.service +%endif %files %defattr (-, root, root) @@ -815,6 +831,7 @@ fi %defattr (-, root, root) /usr/include/* +%if !%{with_64kb} %if %{with_perf} %files -n perf %{_bindir}/perf @@ -886,7 +903,13 @@ fi /usr/src/linux-%{KernelVer}/.scmversion %endif +#with_64kb +%endif + %changelog +* Tue Dec 12 2023 zhaoxiaoqiang11 - 5.10.0-176.0.0.90 +- adapt spec for arm64 64kb page build + * Thu Dec 07 2023 Jialin Zhang - 5.10.0-176.0.0.89 - !3226 hinic: ethtool: Allow userspace to set more aggregation params - !3259 mbigen: vtimer: isolate mbigen vtimer funcs with macro