- rel up
[packages/e1000.git] / e1000.spec
... / ...
CommitLineData
1#
2# Conditional build:
3%bcond_without dist_kernel # allow non-distribution kernel
4%bcond_without kernel # don't build kernel modules
5%bcond_with verbose # verbose build (V=1)
6
7%ifarch sparc
8%undefine with_smp
9%endif
10
11%if %{without kernel}
12%undefine with_dist_kernel
13%endif
14%if "%{_alt_kernel}" != "%{nil}"
15%undefine with_userspace
16%endif
17# nothing to be placed to debuginfo package
18%define _enable_debug_packages 0
19
20%define rel 10
21%define pname e1000
22Summary: Intel(R) PRO/1000 driver for Linux
23Summary(pl.UTF-8): Sterownik do karty Intel(R) PRO/1000
24Name: %{pname}%{_alt_kernel}
25Version: 8.0.19
26Release: %{rel}
27License: GPL v2
28Group: Base/Kernel
29Source0: http://dl.sourceforge.net/e1000/%{pname}-%{version}.tar.gz
30# Source0-md5: dc66dcbfd7c2e48af8cfc86f4f174fce
31URL: http://sourceforge.net/projects/e1000/
32%{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.20.2}
33BuildRequires: rpmbuild(macros) >= 1.379
34BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36%description
37This package contains the Linux driver for the Intel(R) PRO/1000
38adapters with 8254x non-PCIe chipsets.
39
40%description -l pl.UTF-8
41Ten pakiet zawiera sterownik dla Linuksa do kart sieciowych z rodziny
42Intel(R) PRO/1000 opartych o układy 8254x niebędące PCIe.
43
44%package -n kernel%{_alt_kernel}-net-e1000
45Summary: Intel(R) PRO/1000 driver for Linux
46Summary(pl.UTF-8): Sterownik do karty Intel(R) PRO/1000
47Release: %{rel}@%{_kernel_ver_str}
48Group: Base/Kernel
49Requires(post,postun): /sbin/depmod
50%if %{with dist_kernel}
51%requires_releq_kernel
52Requires(postun): %releq_kernel
53%endif
54Obsoletes: e1000
55Obsoletes: linux-net-e1000
56
57%description -n kernel%{_alt_kernel}-net-e1000
58This package contains the Linux driver for the Intel(R) PRO/1000
59adapters with 8254x non-PCIe chipsets.
60
61%description -n kernel%{_alt_kernel}-net-e1000 -l pl.UTF-8
62Ten pakiet zawiera sterownik dla Linuksa do kart sieciowych z rodziny
63Intel(R) PRO/1000 opartych o układy 8254x nie będące PCIe.
64
65%prep
66%setup -q -n %{pname}-%{version}
67cat > src/Makefile <<'EOF'
68obj-m := e1000.o
69e1000-objs := e1000_main.o e1000_82540.o e1000_82542.o e1000_82541.o e1000_82543.o \
70e1000_mac.o e1000_nvm.o e1000_phy.o e1000_manage.o e1000_param.o e1000_ethtool.o \
71kcompat.o e1000_api.o
72
73EXTRA_CFLAGS=-DDRIVER_E1000
74EOF
75
76%build
77%build_kernel_modules -C src -m %{pname}
78
79%install
80rm -rf $RPM_BUILD_ROOT
81%install_kernel_modules -m src/%{pname} -d kernel/drivers/net -n %{pname} -s current
82# blacklist kernel module
83cat > $RPM_BUILD_ROOT/etc/modprobe.d/%{_kernel_ver}/%{pname}.conf <<'EOF'
84blacklist e1000
85alias e1000 e1000-current
86EOF
87
88%clean
89rm -rf $RPM_BUILD_ROOT
90
91%post -n kernel%{_alt_kernel}-net-e1000
92%depmod %{_kernel_ver}
93
94%postun -n kernel%{_alt_kernel}-net-e1000
95%depmod %{_kernel_ver}
96
97%files -n kernel%{_alt_kernel}-net-e1000
98%defattr(644,root,root,755)
99%doc e1000.7 README
100/etc/modprobe.d/%{_kernel_ver}/%{pname}.conf
101/lib/modules/%{_kernel_ver}/kernel/drivers/net/%{pname}*.ko*
This page took 0.025857 seconds and 4 git commands to generate.