- upgrade to 2.6.16-060323

- don't hardcode /usr/lib in tc (#186607)
This commit is contained in:
Radek Vokál 2006-03-27 08:12:02 +00:00
parent 9143b62a9e
commit 6f2fda2db6
4 changed files with 68 additions and 7 deletions

View File

@ -1 +1 @@
iproute2-2.6.15-060110.tar.gz
iproute2-2.6.16-060323.tar.gz

View File

@ -1,17 +1,18 @@
%define date_version 060110
%define date_version 060323
%define cbq_version v0.7.3
Summary: Advanced IP routing and network device configuration tools.
Name: iproute
Version: 2.6.15
Release: 2
Version: 2.6.16
Release: 1
Group: Applications/System
Source: http://developer.osdl.org/dev/iproute2/download/iproute2-%{version}-%{date_version}.tar.gz
URL: http://linux-net.osdl.org/index.php/Iproute2
Patch1: iproute2-2.4.7-rt_config.patch
#Patch1: iproute2-2.4.7-rt_config.patch
Patch2: iproute2-2.6.9-kernel.patch
Patch5: iproute2-ss050901-opt_flags.patch
Patch7: iproute2-051007-add_tunnel.patch
Patch8: iproute2-2.6.16-libdir.patch
License: GNU GPL
BuildRoot: %{_tmppath}/%{name}-%{version}-root
@ -25,12 +26,15 @@ capabilities of the Linux 2.4.x and 2.6.x kernel.
%prep
%setup -q -n iproute2-%{version}-%{date_version}
%patch1 -p1
#%patch1 -p1
%patch2 -p1 -b .kernel
%patch5 -p1 -b .opt_flags
%patch7 -p1 -b .tunnel_add
%patch8 -p1 -b .libdir
%build
export LIBDIR=%{_libdir}
make
make -C doc
@ -87,6 +91,10 @@ EOF
%config(noreplace) /etc/sysconfig/cbq/*
%changelog
* Sun Mar 26 2006 Radek Vokál <rvokal@redhat.com> - 2.6.16-1
- upgrade to 2.6.16-060323
- don't hardcode /usr/lib in tc (#186607)
* Wed Feb 22 2006 Radek Vokál <rvokal@redhat.com> - 2.6.15-2
- own /usr/lib/tc (#181953)
- obsoletes shapecfg (#182284)

View File

@ -0,0 +1,53 @@
--- iproute2-2.6.16-060323/tc/Makefile.libdir 2005-07-06 00:11:37.000000000 +0200
+++ iproute2-2.6.16-060323/tc/Makefile 2006-03-27 07:09:28.000000000 +0200
@@ -42,7 +42,7 @@
TCLIB += tc_cbq.o
TCLIB += tc_estimator.o
-CFLAGS += -DCONFIG_GACT -DCONFIG_GACT_PROB
+CFLAGS += -DCONFIG_GACT -DCONFIG_GACT_PROB -DLIBDIR=\"$(LIBDIR)\"
TCSO :=
TCSO += q_netem.so
--- iproute2-2.6.16-060323/tc/q_netem.c.libdir 2005-12-10 01:01:02.000000000 +0100
+++ iproute2-2.6.16-060323/tc/q_netem.c 2006-03-27 07:09:28.000000000 +0200
@@ -60,7 +60,11 @@
char *line = NULL;
char name[128];
+ #ifdef LIBDIR
+ snprintf(name, sizeof(name), "%s/tc/%s.dist", LIBDIR, type);
+ #else
snprintf(name, sizeof(name), "/usr/lib/tc/%s.dist", type);
+ #endif
if ((f = fopen(name, "r")) == NULL) {
fprintf(stderr, "No distribution data for %s (%s: %s)\n",
type, name, strerror(errno));
--- iproute2-2.6.16-060323/tc/tc.c.libdir 2005-10-07 18:33:21.000000000 +0200
+++ iproute2-2.6.16-060323/tc/tc.c 2006-03-27 07:11:53.000000000 +0200
@@ -98,8 +98,11 @@
for (q = qdisc_list; q; q = q->next)
if (strcmp(q->id, str) == 0)
return q;
-
+ #ifdef LIBDIR
+ snprintf(buf, sizeof(buf), "%s/tc/q_%s.so", LIBDIR, str);
+ #else
snprintf(buf, sizeof(buf), "/usr/lib/tc/q_%s.so", str);
+ #endif
dlh = dlopen(buf, RTLD_LAZY);
if (!dlh) {
/* look in current binary, only open once */
@@ -144,8 +147,11 @@
for (q = filter_list; q; q = q->next)
if (strcmp(q->id, str) == 0)
return q;
-
+ #ifdef LIBDIR
+ snprintf(buf, sizeof(buf), "%s/tc/f_%s.so", LIBDIR, str);
+ #else
snprintf(buf, sizeof(buf), "/usr/lib/tc/f_%s.so", str);
+ #endif
dlh = dlopen(buf, RTLD_LAZY);
if (dlh == NULL) {
dlh = BODY;

View File

@ -1 +1 @@
04f57a6d366d36426d276178b600f5c5 iproute2-2.6.15-060110.tar.gz
f31d4516b35bbfeaa72c762f5959e97c iproute2-2.6.16-060323.tar.gz