]> git.ipfire.org Git - people/amarx/ipfire-3.x.git/blame - iproute2/iproute2.nm
Merge remote-tracking branch 'stevee/openvswitch-systemd'
[people/amarx/ipfire-3.x.git] / iproute2 / iproute2.nm
CommitLineData
a9d112c3 1###############################################################################
802ea3af
MT
2# IPFire.org - An Open Source Firewall Solution #
3# Copyright (C) - IPFire Development Team <info@ipfire.org> #
a9d112c3
MT
4###############################################################################
5
802ea3af 6name = iproute2
c33262e9 7version = 3.4.0
d5598cce 8release = 1
a9d112c3 9
4bfc4e7c 10groups = Networking/Tools
802ea3af
MT
11url = http://www.linuxfoundation.org/en/Net:Iproute2
12license = GPLv2+
13summary = Advanced IP routing and network device configuration tools.
a9d112c3 14
802ea3af 15description
a9d112c3
MT
16 The iproute package contains networking utilities (ip and rtmon, for \
17 example) which are designed to use the advanced networking \
18 capabilities of the Linux 2.4.x and 2.6.x kernel.
802ea3af
MT
19end
20
c33262e9 21source_dl = http://kernel.org/pub/linux/utils/net/iproute2/
d5598cce 22sources = %{thisapp}.tar.xz
802ea3af
MT
23
24build
25 requires
26 bison
27 db4-devel
28 flex
d5598cce
MT
29 libnl-devel
30 linux-atm-devel >= 2.5.1
31 iptables-devel
802ea3af
MT
32 end
33
34 prepare_cmds
d5598cce 35 sed -e "s/_VERSION_/%{version}/" man/man8/ss.8
802ea3af
MT
36 end
37
d5598cce
MT
38 export RPM_OPT_FLAGS = %{CFLAGS}
39 export LIBDIR = %{libdir}
40 export IPT_LIB_DIR = %{libdir}/xtables
41
802ea3af 42 install
d5598cce
MT
43 # The installation routine that comes with that package
44 # is totally unusable for use, so do it manually.
45
46 mkdir -pv \
47 %{BUILDROOT}%{includedir} \
48 %{BUILDROOT}%{sbindir} \
49 %{BUILDROOT}%{mandir}/man{3,8} \
50 %{BUILDROOT}%{datadir}/tc \
51 %{BUILDROOT}%{libdir}/tc \
52 %{BUILDROOT}%{sysconfdir}/iproute2
53
54 # Install binaries.
c33262e9 55 for bin in genl/genl ip/{ifcfg,ip,routef,routel,rtmon,rtpr} tc/tc \
d5598cce
MT
56 misc/{arpd,ifstat,lnstat,nstat,rtacct,ss}; do
57 install -v -m 755 ${bin} %{BUILDROOT}%{sbindir}
58 done
59 ln -svf lnstat %{BUILDROOT}%{sbindir}/ctstat
60 ln -svf lnstat %{BUILDROOT}%{sbindir}/rtstat
61
62 # Install libs.
63 for lib in tc/q_atm.so tc/m_xt.so; do
64 install -v -m 755 ${lib} %{BUILDROOT}%{libdir}/tc
65 done
66 ln -svf m_xt.so %{BUILDROOT}%{libdir}/tc/m_ipt.so
67
68 # libnetlink
69 install -v -m 644 include/libnetlink.h %{BUILDROOT}%{includedir}
70 install -v -m 644 lib/libnetlink.a %{BUILDROOT}%{libdir}
71
72 # Install documentation.
73 install -v -m 644 man/man3/*.3 %{BUILDROOT}%{mandir}/man3
74 install -v -m 644 man/man8/*.8 %{BUILDROOT}%{mandir}/man8
75 ln -svf lnstat.8 %{BUILDROOT}%{mandir}/man8/ctstat.8
76 ln -svf lnstat.8 %{BUILDROOT}%{mandir}/man8/rtstat.8
77 ln -svf routel.8 %{BUILDROOT}%{mandir}/man8/routef.8
78
79 for sh in netem/normal.dist netem/pareto.dist netem/paretonormal.dist; do
80 install -v -m 644 ${sh} %{BUILDROOT}%{datadir}/tc
81 done
82
83 # Install configuration.
84 install -v -m 644 etc/iproute2/* %{BUILDROOT}%{sysconfdir}/iproute2
85 end
86
87 # Keep libnetlink.a.
88 keep_libraries
89 %{libdir}/libnetlink.a
802ea3af
MT
90 end
91end
92
93packages
94 package %{name}
4bfc4e7c 95 groups += Base
d5598cce
MT
96
97 configfiles = %{sysconfdir}/iproute2
98 end
99
100 package %{name}-devel
101 template DEVEL
802ea3af 102 end
1f9bc2f0
MT
103
104 package %{name}-debuginfo
105 template DEBUGINFO
106 end
802ea3af 107end