]> git.pld-linux.org Git - packages/xorg-driver-video-fglrx.git/commitdiff
- updated kernel modules build system
authorJan Rękorajski <baggins@pld-linux.org>
Tue, 27 Jan 2015 19:05:20 +0000 (20:05 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Tue, 27 Jan 2015 19:05:20 +0000 (20:05 +0100)
xorg-driver-video-fglrx.spec

index 4fad6f155cf02d5575ae21b6d4cded47fa8f3727..980767330dd6e8aac2c334981a3e22467f5364e0 100644 (file)
 exit 1
 %endif
 
-%if "%{_alt_kernel}" != "%{nil}"
-%if 0%{?build_kernels:1}
-%{error:alt_kernel and build_kernels are mutually exclusive}
-exit 1
-%endif
-%undefine      with_userspace
-%global                _build_kernels          %{alt_kernel}
-%else
-%global                _build_kernels          %{?build_kernels:,%{?build_kernels}}
-%endif
-
 %if %{without userspace}
 # nothing to be placed to debuginfo package
 %define                _enable_debug_packages  0
 %endif
 
-%define                kbrs    %(echo %{_build_kernels} | tr , '\\n' | while read n ; do echo %%undefine alt_kernel ; [ -z "$n" ] || echo %%define alt_kernel $n ; echo "BuildRequires:kernel%%{_alt_kernel}-module-build >= 3:2.6.20.2" ; done)
-%define                kpkg    %(echo %{_build_kernels} | tr , '\\n' | while read n ; do echo %%undefine alt_kernel ; [ -z "$n" ] || echo %%define alt_kernel $n ; echo %%kernel_pkg ; done)
-%define                bkpkg   %(echo %{_build_kernels} | tr , '\\n' | while read n ; do echo %%undefine alt_kernel ; [ -z "$n" ] || echo %%define alt_kernel $n ; echo %%build_kernel_pkg ; done)
-
 %ifarch %{ix86}
 %define                arch_sufix      %{nil}
 %define                arch_dir        x86
@@ -76,8 +61,8 @@ Patch5:               %{pname}-GPL-only.patch
 Patch6:                %{pname}-intel_iommu.patch
 Patch7:                linux-3.17.patch
 URL:           http://ati.amd.com/support/drivers/linux/linux-radeon.html
-%{?with_kernel:%{expand:%kbrs}}
-BuildRequires: rpmbuild(macros) >= 1.678
+%{?with_kernel:%{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:2.6.20.2}}
+BuildRequires: rpmbuild(macros) >= 1.701
 BuildRequires: sed >= 4.0
 Requires:      %{pname}-libs = %{epoch}:%{version}-%{rel}
 Requires:      xorg-xserver-server
@@ -222,7 +207,7 @@ cp -pf common/lib/modules/fglrx/build_mod/2.6.x/Makefile common/lib/modules/fglr
 %install_kernel_modules -D installed -m common/lib/modules/fglrx/build_mod/fglrx -d misc\
 %{nil}
 
-%{?with_kernel:%{expand:%kpkg}}
+%{?with_kernel:%{expand:%create_kernel_packages}}
 
 %prep
 %setup -q -c
@@ -260,7 +245,7 @@ cp -a arch/%{arch_dir}/etc/* common/etc
 
 %build
 cd fglrx-%{intver}
-%{?with_kernel:%{expand:%bkpkg}}
+%{?with_kernel:%{expand:%build_kernel_packages}}
 
 %install
 rm -rf $RPM_BUILD_ROOT
This page took 0.068374 seconds and 4 git commands to generate.