- added depmod options so modules can be installed for kernel other than running
[packages/e1000.git] / e1000.spec
CommitLineData
5672dc74
JB
1#
2# Conditional build:
6b39b5a2 3# _without_dist_kernel without distribution kernel
5672dc74 4#
6b39b5a2 5%define _orig_name e1000
6b39b5a2
PG
6
7Summary: Intel(R) PRO/1000 driver for Linux
8Summary(pl): Sterownik do karty Intel(R) PRO/1000
9Name: kernel-net-%{_orig_name}
6135fb7a
PG
10Version: 4.4.12
11%define _rel 1
24e60443 12Release: %{_rel}@%{_kernel_ver_str}
6b39b5a2
PG
13License: BSD
14Vendor: Intel Corporation
15Group: Base/Kernel
6135fb7a 16Source0: ftp://aiedownload.intel.com/df-support/4833/eng/%{_orig_name}-%{version}.tar.gz
cc65c159 17%{!?_without_dist_kernel:BuildRequires: kernel-headers > 2.4 }
6b39b5a2
PG
18BuildRequires: %{kgcc_package}
19URL: http://support.intel.com/support/network/adapter/pro100/
5672dc74
JB
20%{!?_without_dist_kernel:%requires_releq_kernel_up}
21Requires(post,postun): /sbin/depmod
22Provides: kernel(e1000)
6b39b5a2
PG
23Obsoletes: e1000
24Obsoletes: linux-net-e1000
6b39b5a2
PG
25BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27%description
fbba5257
PG
28This package contains the Linux driver for the Intel(R) PRO/1000
29family of 10/100/1000 Ethernet network adapters.
6b39b5a2
PG
30
31%description -l pl
fbba5257
PG
32Ten pakiet zawiera sterownik dla Linuksa do kart sieciowych
3310/100/1000Mbit z rodziny Intel(R) PRO/1000.
6b39b5a2
PG
34
35%package -n kernel-smp-net-%{_orig_name}
36Summary: Intel(R) PRO/1000 driver for Linux SMP
37Summary(pl): Sterownik do karty Intel(R) PRO/1000
38Release: %{_rel}@%{_kernel_ver_str}
39Group: Base/Kernel
6b39b5a2 40%{!?_without_dist_kernel:%requires_releq_kernel_smp}
5672dc74
JB
41Requires(post,postun): /sbin/depmod
42Provides: kernel(e1000)
6b39b5a2
PG
43Obsoletes: e1000
44Obsoletes: linux-net-e1000
6b39b5a2
PG
45
46%description -n kernel-smp-net-%{_orig_name}
47This package contains the Linux SMP driver for the Intel(R) PRO/1000
48family of 10/100/1000 Ethernet network adapters.
49
50%description -n kernel-smp-net-%{_orig_name} -l pl
51Ten pakiet zawiera sterownik dla Linuksa SMP do kart sieciowych
5210/100/1000Mbit z rodziny Intel(R) PRO/1000.
53
54%prep
55%setup -q -n %{_orig_name}-%{version}
56
57%build
239f289f 58%ifarch %{ix86}
cdde7fde 59%{__make} -C src SMP=1 CC="%{kgcc} -DCONFIG_X86_LOCAL_APIC -DSTB_WA" KSRC=%{_kernelsrcdir}
239f289f 60%else
61%{__make} -C src SMP=1 CC="%{kgcc} -DSTB_WA" KSRC=%{_kernelsrcdir}
62%endif
6b39b5a2 63mv -f src/%{_orig_name}.o src/%{_orig_name}-smp.o
cdde7fde
JB
64%{__make} -C src clean KSRC=%{_kernelsrcdir}
65%{__make} -C src CC="%{kgcc} -DSTB_WA" KSRC=%{_kernelsrcdir}
6b39b5a2
PG
66
67%install
68rm -rf $RPM_BUILD_ROOT
69install -d $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/misc
70install -d $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}smp/misc
71install src/%{_orig_name}-smp.o $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}smp/misc/%{_orig_name}.o
72install src/%{_orig_name}.o $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/misc/%{_orig_name}.o
73
fbba5257 74%clean
6b39b5a2
PG
75rm -rf $RPM_BUILD_ROOT
76
77%post
5672dc74 78/sbin/depmod -a -F /boot/System.map-%{_kernel_ver} %{_kernel_ver}
6b39b5a2
PG
79
80%postun
5672dc74 81/sbin/depmod -a -F /boot/System.map-%{_kernel_ver} %{_kernel_ver}
6b39b5a2 82
5672dc74
JB
83%post -n kernel-smp-net-%{_orig_name}
84/sbin/depmod -a -F /boot/System.map-%{_kernel_ver}smp %{_kernel_ver}smp
6b39b5a2
PG
85
86%postun -n kernel-smp-net-%{_orig_name}
5672dc74 87/sbin/depmod -a -F /boot/System.map-%{_kernel_ver}smp %{_kernel_ver}smp
6b39b5a2
PG
88
89%files
90%defattr(644,root,root,755)
cdde7fde 91%doc %{_orig_name}.7 README ldistrib.txt
6b39b5a2
PG
92/lib/modules/%{_kernel_ver}/misc/*
93
94%files -n kernel-smp-net-%{_orig_name}
95%defattr(644,root,root,755)
cdde7fde 96%doc %{_orig_name}.7 README ldistrib.txt
6b39b5a2 97/lib/modules/%{_kernel_ver}smp/misc/*
This page took 0.064758 seconds and 4 git commands to generate.