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