X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=kernel.spec;h=ea3afa8a462fdbcf4a4969efac2706d02e96b8ba;hb=087fc76d75ee9b6ee26b0b9b86fc206067c03701;hp=b592ed69c43fba0be21c9db260e8a919885e8a6b;hpb=74dcb546cf0037de5a86b142a36c8ff17380c70d;p=packages%2Fkernel.git diff --git a/kernel.spec b/kernel.spec index b592ed69..ea3afa8a 100644 --- a/kernel.spec +++ b/kernel.spec @@ -41,11 +41,6 @@ %{?debug:%define with_verbose 1} %define have_drm 1 -%ifarch %{ix86} %{x8664} x32 alpha %{arm} ia64 ppc ppc64 sparc sparc64 -%define have_ide 1 -%else -%define have_ide 0 -%endif %define have_sound 1 %define have_pcmcia 1 @@ -57,7 +52,6 @@ %if %{with myown} %define have_drm 0 -%define have_ide 0 %define have_sound 0 %define have_pcmcia 0 %endif @@ -72,8 +66,8 @@ %endif %define rel 1 -%define basever 5.9 -%define postver .3 +%define basever 5.15 +%define postver .10 # define this to '-%{basever}' for longterm branch %define versuffix %{nil} @@ -124,10 +118,10 @@ Epoch: 3 License: GPL v2 Group: Base/Kernel Source0: https://www.kernel.org/pub/linux/kernel/v5.x/linux-%{basever}.tar.xz -# Source0-md5: 0959d759fd19e146367221aff504ad91 +# Source0-md5: 071d49ff4e020d58c04f9f3f76d3b594 %if "%{postver}" != ".0" Patch0: https://www.kernel.org/pub/linux/kernel/v5.x/patch-%{version}.xz -# Patch0-md5: f7990758b88ec9e49f367793d1d7031e +# Patch0-md5: c876f09e70a498dc43c8706c18b56f76 %endif Source1: kernel.sysconfig @@ -197,16 +191,7 @@ Patch85: kernel-hostap.patch Patch100: kernel-vserver-2.3.patch Patch101: kernel-vserver-fixes.patch -# git://github.com/sfjro/aufs5-standalone.git, read README -# Patch creation: -# git clone git://github.com/sfjro/aufs5-standalone.git -# cd aufs5-standalone -# git checkout -b aufs5.8 origin/aufs5.8 -# cat aufs5-kbuild.patch aufs5-base.patch aufs5-mmap.patch aufs5-standalone.patch > ~/rpm/packages/kernel/kernel-aufs5.patch -# rm -rf linux && mkdir linux; cp -a Documentation fs include linux -# diff -urN /usr/share/empty linux | filterdiff -x linux/include/uapi/linux/Kbuild >> ~/rpm/packages/kernel/kernel-aufs5.patch -# cat aufs5-loopback.patch >> ~/rpm/packages/kernel/kernel-aufs5.patch -# +# see update-source.sh Patch145: kernel-aufs5.patch Patch146: kernel-aufs+vserver.patch @@ -220,11 +205,17 @@ Patch500: kernel-rt.patch Patch2000: kernel-small_fixes.patch Patch2001: kernel-pwc-uncompress.patch Patch2003: kernel-regressions.patch +Patch2004: Revert-ath-add-support-for-special-0x0-regulatory-domain.patch # for rescuecd # based on ftp://ftp.leg.uct.ac.za/pub/linux/rip/tmpfs_root-2.6.30.diff.gz Patch7000: kernel-inittmpfs.patch +# ARM only +Patch8000: rpi-wm8804.patch +Patch8001: kernel-pinebook-pro.patch +Patch8002: atheros-disallow-retrain-nongen1-pcie.patch + # Do not remove this line, please. It is easier for me to uncomment two lines, then patch # kernel.spec every time. #Patch50000: kernel-usb_reset.patch @@ -247,9 +238,11 @@ BuildRequires: hostname BuildRequires: kmod >= %{kmod_ver} BuildRequires: libstdc++-devel BuildRequires: openssl-devel +BuildRequires: openssl-tools BuildRequires: perl-base BuildRequires: rpm-build >= 4.5-24 -BuildRequires: rpmbuild(macros) >= 1.743 +BuildRequires: rpmbuild(macros) >= 1.752 +BuildRequires: tar >= 1:1.22 %ifarch ppc BuildRequires: uboot-mkimage %endif @@ -269,26 +262,26 @@ Requires: cpuinfo(pae) Suggests: crda Suggests: dracut Suggests: keyutils -Requires: linux-firmware +Suggests: linux-firmware Provides: %{name}(netfilter) = 20070806 Provides: %{name}(vermagic) = %{kernel_release} -Obsoletes: kernel%{_alt_kernel}-char-lirc-ene0100 -Obsoletes: kernel%{_alt_kernel}-char-lirc-it87 -Obsoletes: kernel%{_alt_kernel}-char-lirc-ite8709 -Obsoletes: kernel%{_alt_kernel}-char-lirc-mceusb -Obsoletes: kernel%{_alt_kernel}-char-lirc-streamzap -Obsoletes: kernel%{_alt_kernel}-isdn-mISDN -Obsoletes: kernel-firmware -Obsoletes: kernel-misc-acer_acpi -Obsoletes: kernel-misc-fuse -Obsoletes: kernel-misc-uvc -Obsoletes: kernel-modules -Obsoletes: kernel-net-ar81 -Obsoletes: kernel-net-hostap -Obsoletes: kernel-net-ieee80211 -Obsoletes: kernel-net-ipp2p -Obsoletes: kernel-net-rt61 -Obsoletes: kernel-smp +Obsoletes: kernel%{_alt_kernel}-char-lirc-ene0100 < 0.9.0 +Obsoletes: kernel%{_alt_kernel}-char-lirc-it87 < 0.9.0 +Obsoletes: kernel%{_alt_kernel}-char-lirc-ite8709 < 0.9.0 +Obsoletes: kernel%{_alt_kernel}-char-lirc-mceusb < 0.9.0 +Obsoletes: kernel%{_alt_kernel}-char-lirc-streamzap < 0.9.0 +Obsoletes: kernel%{_alt_kernel}-isdn-mISDN < 2.0.35 +Obsoletes: kernel-firmware < 3:2.6.33 +Obsoletes: kernel-misc-acer_acpi < 0.3-2 +Obsoletes: kernel-misc-fuse < 2.8.5-2 +Obsoletes: kernel-misc-uvc < 0.215.1-10 +Obsoletes: kernel-modules < 2.2.2-2 +Obsoletes: kernel-net-ar81 < 1.0.1.0-3 +Obsoletes: kernel-net-hostap < 0.4.7-2 +Obsoletes: kernel-net-ieee80211 < 1.2.18-7 +Obsoletes: kernel-net-ipp2p < 0.8.2.-17 +Obsoletes: kernel-net-rt61 < 1.1.0-2.2007122707.13 +Obsoletes: kernel-smp < 3:2.6.21 Conflicts: e2fsprogs < 1.29 Conflicts: isdn4k-utils < 3.1pre1 Conflicts: jfsutils < 1.1.3 @@ -436,7 +429,7 @@ Summary: vmlinux - uncompressed kernel image Summary(de.UTF-8): vmlinux - dekompressiertes Kernel Bild Summary(pl.UTF-8): vmlinux - rozpakowany obraz jądra Group: Base/Kernel -Obsoletes: kernel-smp-vmlinux +Obsoletes: kernel-smp-vmlinux < 3:2.6.21 %description vmlinux vmlinux - uncompressed kernel image. @@ -455,7 +448,7 @@ Group: Base/Kernel Requires(postun): %{name} = %{epoch}:%{version}-%{release} Requires: %{name} = %{epoch}:%{version}-%{release} Provides: kernel(vboxvideo) = %{kernel_release} -Obsoletes: kernel-smp-drm +Obsoletes: kernel-smp-drm < 3:2.6.21 AutoReqProv: no %description drm @@ -467,24 +460,6 @@ DRM Kernel Treiber. %description drm -l pl.UTF-8 Sterowniki DRM. -%package ide -Summary: IDE kernel modules -Summary(de.UTF-8): IDE Kernel Treiber -Summary(pl.UTF-8): Sterowniki IDE -Group: Base/Kernel -Requires(postun): %{name} = %{epoch}:%{version}-%{release} -Requires: %{name} = %{epoch}:%{version}-%{release} -AutoReqProv: no - -%description ide -IDE kernel modules. - -%description ide -l de.UTF-8 -IDE Kernel Treiber. - -%description ide -l pl.UTF-8 -Sterowniki IDE. - %package pcmcia Summary: PCMCIA modules Summary(de.UTF-8): PCMCIA Module @@ -492,7 +467,7 @@ Summary(pl.UTF-8): Moduły PCMCIA Group: Base/Kernel Requires(postun): %{name} = %{epoch}:%{version}-%{release} Requires: %{name} = %{epoch}:%{version}-%{release} -Obsoletes: kernel-smp-pcmcia +Obsoletes: kernel-smp-pcmcia < 3:2.6.21 Conflicts: pcmcia-cs < 3.1.21 Conflicts: pcmciautils < 004 AutoReqProv: no @@ -513,7 +488,7 @@ Summary(pl.UTF-8): Sterowniki dźwięku ALSA Group: Base/Kernel Requires(postun): %{name} = %{epoch}:%{version}-%{release} Requires: %{name} = %{epoch}:%{version}-%{release} -Obsoletes: kernel-smp-sound-alsa +Obsoletes: kernel-smp-sound-alsa < 3:2.6.21 AutoReqProv: no %description sound-alsa @@ -577,9 +552,7 @@ Summary(pl.UTF-8): Kod źródłowy jądra Linuksa Group: Development/Building Requires: %{name}-module-build = %{epoch}:%{version}-%{release} AutoReqProv: no -%if "%{_rpmversion}" >= "5" BuildArch: noarch -%endif %description source This is the source code for the Linux kernel. You can build a custom @@ -610,9 +583,7 @@ Summary(de.UTF-8): Kernel Dokumentation Summary(pl.UTF-8): Dokumentacja do jądra Linuksa Group: Documentation AutoReqProv: no -%if "%{_rpmversion}" >= "5" BuildArch: noarch -%endif %description doc This is the documentation for the Linux kernel, as found in @@ -691,6 +662,12 @@ cd linux-%{basever} %patch7000 -p1 %endif +%ifarch %{arm} aarch64 +%patch8000 -p1 +%patch8001 -p1 +%patch8002 -p1 +%endif + %if %{with rt} %patch500 -p1 rm -f localversion-rt @@ -704,6 +681,7 @@ rm -f localversion-rt %patch2000 -p1 %patch2001 -p1 #%patch2003 -p1 +%patch2004 -p1 # Do not remove this, please! #%%patch50000 -p1 @@ -717,13 +695,13 @@ sed -i 's#EXTRAVERSION =.*#EXTRAVERSION = %{?alt_kernel:.%{alt_kernel}}#g' Makef find '(' -name '*~' -o -name '*.orig' -o -name '.gitignore' ')' -print0 | xargs -0 -r -l512 rm -f find -name '*.py' -print0 | \ - xargs -0 %{__sed} -i -e '1s,/usr/bin/python,%{__python},' \ - -e '1s,/usr/bin/env python,%{__python},' \ - -e '1s,/usr/bin/env python3,%{__python3},' + xargs -0 %{__sed} -i -e '1s,/usr/bin/python$,%{__python},' \ + -e '1s,/usr/bin/env python$,%{__python},' \ + -e '1s,/usr/bin/env python3$,%{__python3},' -%{__sed} -i -e '1s,/usr/bin/python,%{__python},' \ - -e '1s,/usr/bin/env python,%{__python},' \ - -e '1s,/usr/bin/env python3,%{__python3},' \ +%{__sed} -i -e '1s,/usr/bin/python$,%{__python},' \ + -e '1s,/usr/bin/env python$,%{__python},' \ + -e '1s,/usr/bin/env python3$,%{__python3},' \ drivers/staging/greybus/tools/lbtest \ scripts/bloat-o-meter \ scripts/diffconfig \ @@ -743,8 +721,13 @@ find -name '*.pl' -print0 | \ scripts/documentation-file-ref-check \ scripts/get_dvb_firmware \ scripts/kernel-doc \ + scripts/sphinx-pre-install \ scripts/stackdelta +%{__sed} -i -e '1s,/usr/bin/env bash,%{__bash},' \ + tools/testing/selftests/powerpc/security/mitigation-patching.sh \ + scripts/config + %build install -d %{objdir} cat > %{targetobj}.mk <<'EOF' @@ -903,6 +886,10 @@ BuildConfig() { CONFIG_NFS_FS=y CONFIG_ROOT_NFS=y %endif + +%ifarch x32 + CONFIG_BPF_PRELOAD=n +%endif EOCONFIG %if %{with rescuecd} @@ -948,7 +935,14 @@ cd - %{__awk} %{?debug:-v dieOnError=1} -v infile=%{objdir}/%{defconfig} -f %{SOURCE8} %{objdir}/.config +%{__make} \ + TARGETOBJ=%{targetobj} \ + %{?with_verbose:V=1} \ + scripts + # build kernel +export DTC_FLAGS=-@ +ICECC_EXTRAFILES="${ICECC_EXTRAFILES:+$ICECC_EXTRAFILES:}$(test -d %{objdir}/scripts/gcc-plugins && find %{objdir}/scripts/gcc-plugins -name '*.so' | paste -s -d :)" %{__make} \ TARGETOBJ=%{targetobj} \ %{?with_verbose:V=1} \ @@ -960,11 +954,12 @@ rm -rf $RPM_BUILD_ROOT -C %{objdir} \ %{?with_verbose:V=1} \ DEPMOD=%{DepMod} \ - mod_compress_cmd=true \ INSTALL_MOD_PATH=$RPM_BUILD_ROOT \ + INSTALL_MOD_STRIP="--strip-debug --remove-section=.comment --remove-section=.note.GNU-stack" \ KERNELRELEASE=%{kernel_release} %ifarch %{arm} aarch64 +export DTC_FLAGS=-@ %{__make} %{MakeOpts} %{!?with_verbose:-s} dtbs_install \ -C %{objdir} \ %{?with_verbose:V=1} \ @@ -1129,6 +1124,10 @@ if [[ "$CREATE_SYMLINKS" != [Nn][Oo] ]]; then mv -f /boot/System.map{,.old} 2> /dev/null ln -sf vmlinuz-%{kernel_release} /boot/vmlinuz ln -sf System.map-%{kernel_release} /boot/System.map +%ifarch %{arm} aarch64 + mv -f /boot/dtb{,.old} 2> /dev/null + ln -sf dtb-%{kernel_release} /boot/dtb +%endif %if 0%{?alt_kernel:1} mv -f /boot/vmlinuz%{_alt_kernel}{,.old} 2> /dev/null mv -f /boot/System%{_alt_kernel}.map{,.old} 2> /dev/null @@ -1208,12 +1207,6 @@ fi %postun drm %depmod %{kernel_release} -%post ide -%depmod %{kernel_release} - -%postun ide -%depmod %{kernel_release} - %post pcmcia %depmod %{kernel_release} @@ -1274,9 +1267,6 @@ fi %if %{have_drm} %exclude /lib/modules/%{kernel_release}/kernel/drivers/gpu %endif -%if %{have_ide} -%exclude /lib/modules/%{kernel_release}/kernel/drivers/ide/* -%endif /lib/modules/%{kernel_release}/kernel/fs /lib/modules/%{kernel_release}/kernel/kernel /lib/modules/%{kernel_release}/kernel/lib @@ -1292,6 +1282,9 @@ fi %exclude /lib/modules/%{kernel_release}/kernel/drivers/media/pci/saa7134/saa7134-alsa.ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/usb/gadget/legacy/g_midi.ko* %endif +%ifarch %{arm} +%exclude /lib/modules/%{kernel_release}/kernel/drivers/staging/vc04_services/bcm2835-audio +%endif %endif %dir /lib/modules/%{kernel_release}/misc %if %{have_pcmcia} @@ -1302,7 +1295,6 @@ fi %exclude /lib/modules/%{kernel_release}/kernel/drivers/ata/pata_pcmcia.ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/bluetooth/*_cs.ko* %endif -%exclude /lib/modules/%{kernel_release}/kernel/drivers/ide/ide-cs.ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/net/arcnet/com20020_cs.ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/net/can/softing/softing_cs.ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/net/ethernet/3com/3c574_cs.ko* @@ -1364,15 +1356,6 @@ fi /lib/modules/%{kernel_release}/kernel/drivers/gpu %endif -%if %{have_ide} -%files ide -%defattr(644,root,root,755) -/lib/modules/%{kernel_release}/kernel/drivers/ide/* -%if %{have_pcmcia} -%exclude /lib/modules/%{kernel_release}/kernel/drivers/ide/ide-cs.ko* -%endif -%endif - %if %{have_pcmcia} %files pcmcia %defattr(644,root,root,755) @@ -1383,7 +1366,6 @@ fi /lib/modules/%{kernel_release}/kernel/drivers/bluetooth/*_cs.ko* /lib/modules/%{kernel_release}/kernel/drivers/ata/pata_pcmcia.ko* %endif -/lib/modules/%{kernel_release}/kernel/drivers/ide/ide-cs.ko* /lib/modules/%{kernel_release}/kernel/drivers/net/arcnet/com20020_cs.ko* /lib/modules/%{kernel_release}/kernel/drivers/net/can/softing/softing_cs.ko* /lib/modules/%{kernel_release}/kernel/drivers/net/ethernet/3com/3c574_cs.ko* @@ -1418,6 +1400,9 @@ fi /lib/modules/%{kernel_release}/kernel/drivers/media/usb/em28xx/em28xx-alsa.ko* /lib/modules/%{kernel_release}/kernel/drivers/media/pci/saa7134/saa7134-alsa.ko* %endif +%ifarch %{arm} +/lib/modules/%{kernel_release}/kernel/drivers/staging/vc04_services/bcm2835-audio +%endif %endif %files headers -f files.headers_exclude_kbuild @@ -1442,7 +1427,6 @@ fi %endif %exclude %dir %{_kernelsrcdir}/arch/um %{_kernelsrcdir}/arch/*/kernel/asm-offsets* -%{_kernelsrcdir}/arch/*/kernel/module.lds %{_kernelsrcdir}/arch/*/kernel/sigframe*.h %{_kernelsrcdir}/drivers/media/pci/bt8xx/bttv.h %{_kernelsrcdir}/kernel/bounds.c @@ -1465,8 +1449,6 @@ fi %{_kernelsrcdir}/scripts/mod/*.c %{_kernelsrcdir}/scripts/mod/modpost.h %attr(755,root,root) %{_kernelsrcdir}/scripts/mkcompile_h -%{_kernelsrcdir}/scripts/mkmakefile -%{_kernelsrcdir}/scripts/module-common.lds %attr(755,root,root) %{_kernelsrcdir}/scripts/setlocalversion %{_kernelsrcdir}/scripts/subarch.include %{_kernelsrcdir}/scripts/*.c @@ -1512,7 +1494,6 @@ fi %{_kernelsrcdir}/arch/s390/kvm %{_kernelsrcdir}/arch/x86/kvm %exclude %{_kernelsrcdir}/arch/*/kernel/asm-offsets* -%exclude %{_kernelsrcdir}/arch/*/kernel/module.lds %exclude %{_kernelsrcdir}/arch/*/kernel/sigframe*.h %exclude %{_kernelsrcdir}/drivers/media/pci/bt8xx/bttv.h %{_kernelsrcdir}/block @@ -1535,9 +1516,7 @@ fi %exclude %{_kernelsrcdir}/scripts/basic %exclude %{_kernelsrcdir}/scripts/kconfig %exclude %{_kernelsrcdir}/scripts/mkcompile_h -%exclude %{_kernelsrcdir}/scripts/mkmakefile %exclude %{_kernelsrcdir}/scripts/mod -%exclude %{_kernelsrcdir}/scripts/module-common.lds %exclude %{_kernelsrcdir}/scripts/setlocalversion %exclude %{_kernelsrcdir}/scripts/subarch.include %exclude %{_kernelsrcdir}/scripts/*.c