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