From a46e864afc53ab3bc8eeb37e06192291b135ce92 Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Sun, 5 Feb 2012 17:09:19 +0000 Subject: [PATCH] - dropped pcmcia bcond, pae enabled by default fo i686, support only TLD architectures --- kernel-vanilla.spec | 63 +++++++++------------------------------------ 1 file changed, 12 insertions(+), 51 deletions(-) diff --git a/kernel-vanilla.spec b/kernel-vanilla.spec index 0260186..a870c83 100644 --- a/kernel-vanilla.spec +++ b/kernel-vanilla.spec @@ -2,9 +2,7 @@ # # Conditional build: %bcond_without source # don't build kernel-vanilla-source package -%bcond_without pcmcia # don't build pcmcia %bcond_with verbose # verbose build (V=1) -%bcond_with pae # build PAE (HIGHMEM64G) support on uniprocessor %{?debug:%define with_verbose 1} @@ -19,7 +17,7 @@ %define _enable_debug_packages 0 -%define alt_kernel vanilla%{?with_pae:-pae} +%define alt_kernel vanilla # kernel release (used in filesystem and eventually in uname -r) # modules will be looked from /lib/modules/%{kernel_release} @@ -95,23 +93,17 @@ Conflicts: reiserfsprogs < 3.6.3 Conflicts: udev < 1:071 Conflicts: util-linux < 2.10o Conflicts: xfsprogs < 2.6.0 -%if %{with pae} -ExclusiveArch: %{ix86} -ExcludeArch: i386 i486 i586 -%else -ExclusiveArch: %{ix86} %{x8664} -%endif +ExclusiveArch: i586 i686 x86_64 ExclusiveOS: Linux BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) -%ifarch %{ix86} %{x8664} +%ifarch i586 i686 x86_64 %define target_arch_dir x86 -%endif -%ifnarch %{ix86} %{x8664} +%else %define target_arch_dir %{_target_base_arch} %endif -%ifarch %{ix86} +%ifarch i586 i686 %define kernel_config x86 %else %define kernel_config %{_target_base_arch} @@ -377,40 +369,15 @@ find '(' -name '*~' -o -name '*.orig' -o -name '.gitignore' ')' -print0 | xargs %build TuneUpConfigForIX86 () { set -x -%ifarch %{ix86} - pae= - [ "$2" = "yes" ] && pae=yes - %if %{with pae} - pae=yes - %endif - %ifnarch i386 - sed -i 's:CONFIG_M386=y:# CONFIG_M386 is not set:' $1 - %endif - %ifarch i486 - sed -i 's:# CONFIG_M486 is not set:CONFIG_M486=y:' $1 - %endif +%ifarch i586 i686 %ifarch i586 - sed -i 's:# CONFIG_M586 is not set:CONFIG_M586=y:' $1 - %endif - %ifarch i686 + sed -i "s:# CONFIG_HIGHMEM4G is not set:CONFIG_HIGHMEM4G=y:" $1 + sed -i "s:CONFIG_HIGHMEM64G=y:# CONFIG_HIGHMEM64G is not set:" $1 + sed -i ":CONFIG_X86_PAE=y:d" $1 + %else + sed -i 's:CONFIG_M586=y# CONFIG_M586 is not set::' $1 sed -i 's:# CONFIG_M686 is not set:CONFIG_M686=y:' $1 %endif - %ifarch pentium3 - sed -i 's:# CONFIG_MPENTIUMIII is not set:CONFIG_MPENTIUMIII=y:' $1 - %endif - %ifarch pentium4 - sed -i 's:# CONFIG_MPENTIUM4 is not set:CONFIG_MPENTIUM4=y:' $1 - %endif - %ifarch athlon - sed -i 's:# CONFIG_MK7 is not set:CONFIG_MK7=y:' $1 - %endif - %ifarch i686 athlon pentium3 pentium4 - if [ "$pae" = "yes" ]; then - sed -i "s:CONFIG_HIGHMEM4G=y:# CONFIG_HIGHMEM4G is not set:" $1 - sed -i "s:# CONFIG_HIGHMEM64G is not set:CONFIG_HIGHMEM64G=y\nCONFIG_X86_PAE=y:" $1 - fi - sed -i 's:CONFIG_MATH_EMULATION=y:# CONFIG_MATH_EMULATION is not set:' $1 - %endif return 0 %endif } @@ -455,10 +422,8 @@ PreInstallKernel() { mkdir -p $KERNEL_INSTALL_DIR/boot install System.map $KERNEL_INSTALL_DIR/boot/System.map-$KernelVer -%ifarch %{ix86} %{x8664} install arch/x86/boot/bzImage $KERNEL_INSTALL_DIR/boot/vmlinuz-$KernelVer install vmlinux $KERNEL_INSTALL_DIR/boot/vmlinux-$KernelVer -%endif %{__make} %CrossOpts modules_install firmware_install \ %{?with_verbose:V=1} \ @@ -667,7 +632,7 @@ fi /lib/modules/%{kernel_release}/kernel/kernel /lib/modules/%{kernel_release}/kernel/lib -%ifarch %{x8664} +%ifarch x86_64 /lib/modules/%{kernel_release}/kernel/mm %endif @@ -684,7 +649,6 @@ fi %dir /lib/modules/%{kernel_release}/misc -%if %{with pcmcia} %dir /lib/modules/%{kernel_release}/kernel/drivers/pcmcia /lib/modules/%{kernel_release}/kernel/drivers/pcmcia/pcmcia*ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/pcmcia/[!p]* @@ -702,7 +666,6 @@ fi %exclude /lib/modules/%{kernel_release}/kernel/drivers/net/wireless/libertas/*_cs.ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/parport/parport_cs.ko* %exclude /lib/modules/%{kernel_release}/kernel/drivers/usb/host/sl811_cs.ko* -%endif /lib/modules/%{kernel_release}/kernel/security @@ -722,7 +685,6 @@ fi /lib/modules/%{kernel_release}/kernel/drivers/gpu/drm %endif -%if %{with pcmcia} %files pcmcia %defattr(644,root,root,755) %exclude /lib/modules/%{kernel_release}/kernel/drivers/pcmcia/pcmcia*ko* @@ -739,7 +701,6 @@ fi /lib/modules/%{kernel_release}/kernel/drivers/net/wireless/libertas/*_cs.ko* /lib/modules/%{kernel_release}/kernel/drivers/parport/parport_cs.ko* /lib/modules/%{kernel_release}/kernel/drivers/usb/host/sl811_cs.ko* -%endif %if %{have_sound} %files sound-alsa -- 2.46.0