Install genl, ifstat, routef, routel and rtpr
In addition, the install section is rewritten, buildroot removed and URLs corrected.
This commit is contained in:
parent
3b446e3f98
commit
181ef45663
5
cbq-0000.example
Normal file
5
cbq-0000.example
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
DEVICE=eth0,10Mbit,1Mbit
|
||||||
|
RATE=128Kbit
|
||||||
|
WEIGHT=10Kbit
|
||||||
|
PRIO=5
|
||||||
|
RULE=192.168.1.0/24
|
124
iproute.spec
124
iproute.spec
@ -1,14 +1,13 @@
|
|||||||
#%define date_version 20091106
|
%global cbq_version v0.7.3
|
||||||
%define cbq_version v0.7.3
|
|
||||||
|
|
||||||
Summary: Advanced IP routing and network device configuration tools
|
Summary: Advanced IP routing and network device configuration tools
|
||||||
Name: iproute
|
Name: iproute
|
||||||
Version: 2.6.38.1
|
Version: 2.6.38.1
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
Group: Applications/System
|
Group: Applications/System
|
||||||
##Source: iproute2-%{date_version}.tar.bz2
|
URL: http://www.linuxfoundation.org/collaborate/workgroups/networking/%{name}2
|
||||||
Source: http://developer.osdl.org/dev/iproute2/download/iproute2-%{version}.tar.bz2
|
Source0: http://devresources.linuxfoundation.org/dev/iproute2/download/%{name}2-%{version}.tar.bz2
|
||||||
URL: http://linux-net.osdl.org/index.php/Iproute2
|
Source1: cbq-0000.example
|
||||||
|
Source2: avpkt
|
||||||
Patch0: man-pages.patch
|
Patch0: man-pages.patch
|
||||||
Patch1: iproute2-2.6.29-kernel.patch
|
Patch1: iproute2-2.6.29-kernel.patch
|
||||||
Patch2: iproute2-ss050901-opt_flags.patch
|
Patch2: iproute2-ss050901-opt_flags.patch
|
||||||
@ -22,17 +21,15 @@ Patch9: iproute2-print-route-u32.patch
|
|||||||
Patch10: iproute2-2.6.33-create-peer-veth-without-a-name.patch
|
Patch10: iproute2-2.6.33-create-peer-veth-without-a-name.patch
|
||||||
|
|
||||||
License: GPLv2+ and Public Domain
|
License: GPLv2+ and Public Domain
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
||||||
BuildRequires: tex(latex) tex(dvips) linuxdoc-tools
|
BuildRequires: tex(latex) tex(dvips) linuxdoc-tools
|
||||||
BuildRequires: flex linux-atm-libs-devel psutils db4-devel bison
|
BuildRequires: flex linux-atm-libs-devel psutils db4-devel bison
|
||||||
# introduction new iptables (xtables) which broke ipt
|
|
||||||
Requires: iptables >= 1.4.5
|
|
||||||
BuildRequires: iptables-devel >= 1.4.5
|
BuildRequires: iptables-devel >= 1.4.5
|
||||||
|
Requires: iptables >= 1.4.5
|
||||||
|
|
||||||
%description
|
%description
|
||||||
The iproute package contains networking utilities (ip and rtmon, for
|
The iproute package contains networking utilities (ip and rtmon, for example)
|
||||||
example) which are designed to use the advanced networking
|
which are designed to use the advanced networking capabilities of the Linux
|
||||||
capabilities of the Linux 2.4.x and 2.6.x kernel.
|
2.4.x and 2.6.x kernel.
|
||||||
|
|
||||||
%package doc
|
%package doc
|
||||||
Summary: ip and tc documentation with examples
|
Summary: ip and tc documentation with examples
|
||||||
@ -65,52 +62,66 @@ make %{?_smp_mflags}
|
|||||||
make -C doc
|
make -C doc
|
||||||
|
|
||||||
%install
|
%install
|
||||||
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
|
mkdir -p \
|
||||||
|
%{buildroot}/sbin \
|
||||||
|
%{buildroot}%{_sbindir} \
|
||||||
|
%{buildroot}%{_mandir}/man8 \
|
||||||
|
%{buildroot}%{_datadir}/tc \
|
||||||
|
%{buildroot}%{_libdir}/tc \
|
||||||
|
%{buildroot}%{_sysconfdir}/iproute2 \
|
||||||
|
%{buildroot}%{_sysconfdir}/sysconfig/cbq
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/sbin \
|
# /sbin
|
||||||
$RPM_BUILD_ROOT%{_sbindir} \
|
for binary in \
|
||||||
$RPM_BUILD_ROOT%{_mandir}/man8 \
|
examples/cbq.init-%{cbq_version} \
|
||||||
$RPM_BUILD_ROOT/%{_sysconfdir}/iproute2 \
|
ip/ifcfg \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/tc \
|
ip/ip \
|
||||||
$RPM_BUILD_ROOT%{_libdir}/tc
|
ip/routef \
|
||||||
|
ip/routel \
|
||||||
|
ip/rtpr \
|
||||||
|
tc/tc
|
||||||
|
do install -m755 ${binary} %{buildroot}/sbin
|
||||||
|
done
|
||||||
|
mv %{buildroot}/sbin/cbq.init-%{cbq_version} %{buildroot}/sbin/cbq
|
||||||
|
|
||||||
install -m 755 ip/ip ip/ifcfg ip/rtmon tc/tc $RPM_BUILD_ROOT/sbin
|
# /usr/sbin
|
||||||
install -m 755 misc/ss misc/nstat misc/rtacct misc/lnstat misc/arpd $RPM_BUILD_ROOT%{_sbindir}
|
for binary in \
|
||||||
#netem is static
|
genl/genl \
|
||||||
#install -m 755 tc/q_netem.so $RPM_BUILD_ROOT%{_libdir}/tc
|
misc/arpd \
|
||||||
install -m 755 tc/q_atm.so $RPM_BUILD_ROOT%{_libdir}/tc
|
misc/ifstat \
|
||||||
install -m 644 netem/normal.dist netem/pareto.dist netem/paretonormal.dist $RPM_BUILD_ROOT%{_datadir}/tc
|
misc/lnstat \
|
||||||
install -m 644 man/man8/*.8 $RPM_BUILD_ROOT/%{_mandir}/man8
|
misc/nstat \
|
||||||
rm -r $RPM_BUILD_ROOT/%{_mandir}/man8/ss.8
|
misc/rtacct \
|
||||||
iconv -f latin1 -t utf8 < man/man8/ss.8 > $RPM_BUILD_ROOT/%{_mandir}/man8/ss.8
|
misc/ss
|
||||||
install -m 755 examples/cbq.init-%{cbq_version} $RPM_BUILD_ROOT/sbin/cbq
|
do install -m755 ${binary} %{buildroot}%{_sbindir}
|
||||||
install -d -m 755 $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/cbq
|
done
|
||||||
|
|
||||||
cp -f etc/iproute2/* $RPM_BUILD_ROOT/%{_sysconfdir}/iproute2
|
# Libs
|
||||||
rm -rf $RPM_BUILD_ROOT/%{_libdir}/debug/*
|
for library in \
|
||||||
|
tc/q_atm.so
|
||||||
|
do install -m755 ${library} %{buildroot}%{_libdir}/tc
|
||||||
|
done
|
||||||
|
|
||||||
#copy the tex file from source for time when tex was broken
|
# Manpages
|
||||||
#source1 was created from last functional version
|
iconv -f latin1 -t utf8 man/man8/ss.8 > man/man8/ss.8.utf8 &&
|
||||||
#tar -xvzf %{SOURCE1}
|
mv man/man8/ss.8.utf8 man/man8/ss.8
|
||||||
#mkdir -p $RPM_BUILD_ROOT/%{_defaultdocdir}/%{name}-%{version}
|
install -m644 man/man8/*.8 %{buildroot}%{_mandir}/man8
|
||||||
#cd %{name}-doc-2.6.22
|
|
||||||
#cp -pR *.ps ../doc
|
|
||||||
|
|
||||||
#create example avpkt file
|
# Share files
|
||||||
cat <<EOF > $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/cbq/cbq-0000.example
|
for shared in \
|
||||||
DEVICE=eth0,10Mbit,1Mbit
|
netem/normal.dist \
|
||||||
RATE=128Kbit
|
netem/pareto.dist \
|
||||||
WEIGHT=10Kbit
|
netem/paretonormal.dist
|
||||||
PRIO=5
|
do install -m644 ${shared} %{buildroot}%{_datadir}/tc
|
||||||
RULE=192.168.1.0/24
|
done
|
||||||
EOF
|
|
||||||
|
|
||||||
cat <<EOF > $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/cbq/avpkt
|
# Config files
|
||||||
AVPKT=3000
|
install -m644 etc/iproute2/* %{buildroot}%{_sysconfdir}/iproute2
|
||||||
EOF
|
for config in \
|
||||||
|
%{SOURCE1} \
|
||||||
%clean
|
%{SOURCE2}
|
||||||
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
|
do install -m644 ${config} %{buildroot}%{_sysconfdir}/sysconfig/cbq
|
||||||
|
done
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
@ -136,6 +147,13 @@ EOF
|
|||||||
%doc RELNOTES
|
%doc RELNOTES
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Apr 21 2011 Petr Sabata <psabata@redhat.com> - 2.6.38.1-2
|
||||||
|
- General cleanup
|
||||||
|
- Use global instead of define
|
||||||
|
- Buildroot removal
|
||||||
|
- Correcting URL and Source links
|
||||||
|
- Install genl, ifstat, routef, routel and rtpr (rhbz#697319)
|
||||||
|
|
||||||
* Fri Mar 18 2011 Petr Sabata <psabata@redhat.com> - 2.6.38.1-1
|
* Fri Mar 18 2011 Petr Sabata <psabata@redhat.com> - 2.6.38.1-1
|
||||||
- 2.6.38.1 bump
|
- 2.6.38.1 bump
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user