]> git.pld-linux.org Git - packages/iproute2.git/blob - iproute2.spec
eb083cbc9b47b5fa4f2c32189226e709373d8426
[packages/iproute2.git] / iproute2.spec
1 # conditional build
2 # --without tetex       # with tetex-2 there shuld be BR tetex-tex-babel
3 # --without tc (don't build tc program, it break static linkage)
4 # --without dist_kernel
5
6 %define         _kernel24       %(echo %{_kernel_ver} | grep -q '2\.[012]\.' ; echo $?)
7 %define mainver         2.4.7
8 %define snapshot        ss020116
9 Summary:        Utility to control Networking behavior in 2.2.X kernels
10 Summary(es):    Herramientas para encaminamiento avanzado y configuración de interfaces de red
11 Summary(pl):    Narzêdzie do kontrolowania Sieci w kernelach 2.2
12 Summary(pt_BR): Ferramentas para roteamento avançado e configuração de interfaces de rede
13 Name:           iproute2
14 Version:        %{mainver}.%{snapshot}
15 %define _rel    10
16 Release:        %{_rel}@%{_kernel_ver_str}
17 License:        GPL
18 Vendor:         Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
19 Group:          Networking/Admin
20 Source0:        ftp://ftp.inr.ac.ru/ip-routing/%{name}-%{mainver}-now-%{snapshot}.tar.gz
21 # Source0-md5:  2c7e5f3a10e703745ecdc613f7a7d187
22 Source1:        %{name}-owl-man.tar.bz2
23 # Source1-md5: cd4425df972a4ab001db31a5eb1c5da5
24 Patch0:         %{name}-make.patch
25 Patch1:         %{name}-uClibc.patch
26 Patch2:         %{name}-fix-2_2.patch
27 Patch3:         %{name}-label.patch
28 Patch4:         %{name}-latest.patch
29 Patch5:         %{name}-htb2_tc.patch
30 Patch6:         wrr-iproute2-2.2.4.patch
31 Patch7:         htb3.6_tc.patch
32 Patch8:         %{name}-no_libresolv.patch
33 Patch9:         %{name}-2.2.4-now-ss001007-esfq.diff
34 %{!?_without_tc:BuildRequires:  db-devel}
35 BuildRequires:  bison
36 %{!?_without_tetex:BuildRequires:       latex2html}
37 %{!?_without_tetex:BuildRequires:       psutils}
38 %{!?_without_tetex:BuildRequires:       sgml-tools}
39 %{!?_without_tetex:BuildRequires:       tetex-dvips}
40 %{!?_without_tetex:BuildRequires:       tetex-latex}
41 Obsoletes:      iproute
42 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44 %define         _sbindir        /sbin
45 %define         _sysconfdir     /etc/iproute2
46
47 %description
48 Linux 2.2 maintains compatibility with the basic configuration
49 utilities of the network (ifconfig, route) but a new utility is
50 required to exploit the new characteristics and features of the
51 kernel. This package includes the new utilities.
52
53 %description -l es
54 Linux mantiene compatibilidad con los utilitarios estándares de
55 configuración de la red, pero se necesitan nuevos utilitarios para
56 usar los recursos y características del nuevo núcleo. Este paquete
57 incluye los nuevos utilitarios.
58
59 %description -l pl
60 Ten pakiet zawiera programy pozwalaj±ce na kontrolê routingu i innych
61 aspektów dotycz±cych sieci.
62
63 %description -l pt_BR
64 O Linux mantém compatibilidade com os utilitários padrão de
65 configuração da rede, mas novos utilitários são necessários para fazer
66 uso das características e recursos da nova kernel. This package
67 includes the new utilities.
68
69 %package -n libnetlink-devel
70 Summary:        Library for the netlink interface
71 Summary(pl):    Biblioteka do interfejsu netlink
72 Group:          Development/Libraries
73
74 %description -n libnetlink-devel
75 This library provides an interface for kernel-user netlink interface.
76
77 %description -n libnetlink-devel -l pl
78 Ta biblioteka udostêpnia interfejs do interfejsu netlink miêdzy j±drem
79 a przestrzeni± u¿ytkownika.
80
81 %prep
82 %setup -q -n %{name} -a1
83 %patch0 -p1
84 %patch1 -p1
85 %patch2 -p1
86 #%%patch3 -p1
87 #%%patch4 -p1
88 %if %{_kernel24}
89 %patch7 -p1
90 %else
91 %patch5 -p1
92 %endif
93 %patch6 -p1
94 %patch8 -p1
95 %patch9 -p1
96
97 %build
98 WRRDEF=""
99 grep -q tc_wrr_class_weight %{_kernelsrcdir}/include/linux/pkt_sched.h || WRRDEF="-DNEED_WRR_DEFS"
100
101 %{__make} \
102         CC="%{__cc}" \
103         OPT="%{rpmcflags} ${WRRDEF}" \
104         KERNEL_INCLUDE="%{_kernelsrcdir}/include" \
105         %{?_without_tc:SUBDIRS="lib ip" LDFLAGS="%{rpmldflags}"}
106 %{!?_without_tetex:%{__make} -C doc}
107
108 %install
109 rm -rf $RPM_BUILD_ROOT
110 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_sysconfdir},%{_mandir}/man8,%{_libdir},%{_includedir}}
111
112 install ip/{ip,rtmon,routel} %{!?_without_tc:tc/tc} $RPM_BUILD_ROOT%{_sbindir}
113 install etc/iproute2/rt_protos \
114         etc/iproute2/rt_realms \
115         etc/iproute2/rt_scopes \
116         etc/iproute2/rt_tables \
117         $RPM_BUILD_ROOT%{_sysconfdir}
118 install man/*   $RPM_BUILD_ROOT%{_mandir}/man8
119 install lib/libnetlink.a $RPM_BUILD_ROOT%{_libdir}
120 install include/libnetlink.h $RPM_BUILD_ROOT%{_includedir}
121
122 %clean
123 rm -rf $RPM_BUILD_ROOT
124
125 %files
126 %defattr(644,root,root,755)
127 %doc README README.iproute2+tc RELNOTES
128 %{!?_without_tetex:%doc doc/*.ps}
129 %attr(755,root,root) %{_sbindir}/*
130 %dir %{_sysconfdir}
131 %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/*
132 %{_mandir}/man8/*
133
134 %files -n libnetlink-devel
135 %defattr(644,root,root,755)
136 %{_libdir}/*
137 %{_includedir}/*
This page took 0.03258 seconds and 2 git commands to generate.