The following patch to ipvsadm 1.24-6 will allow ipvsadm to build on RHEL5 - I'm not sure how best to conditionalize the kernel version detection to work with other releases though.

Regards,
Robin

diff -Naur ipvsadm-1.24/ipvsadm.spec.in ipvsadm-1.24-scu/ipvsadm.spec.in
--- ipvsadm-1.24/ipvsadm.spec.in    2005-06-27 02:24:48.000000000 +1000
+++ ipvsadm-1.24-scu/ipvsadm.spec.in    2008-06-25 10:52:37.000000000 +1000
@@ -4,7 +4,7 @@
Name: ipvsadm
Version: @@VERSION@@
Release: @@RELEASE@@
-Copyright: GNU General Public Licence
+License: GNU General Public Licence
URL: http://www.LinuxVirtualServer.org/
Group: Applications/System
Source0: http://www.LinuxVirtualServer.org/software/ipvsadm-%{version}.tar.gz
diff -Naur ipvsadm-1.24/libipvs/Makefile ipvsadm-1.24-scu/libipvs/Makefile
--- ipvsadm-1.24/libipvs/Makefile    2005-06-27 01:59:51.000000000 +1000
+++ ipvsadm-1.24-scu/libipvs/Makefile    2008-06-25 11:18:53.000000000 +1000
@@ -1,7 +1,8 @@
# Makefile for libipvs

CC        = gcc
-INCLUDE        = -I/usr/src/linux/include
+KERNEL          = $(shell uname -r)-$(shell uname -m)
+INCLUDE        = -I/usr/src/kernels/$(KERNEL)/include
CFLAGS        = -Wall -Wunused -Wstrict-prototypes -g -O2

INCLUDE        += $(shell if [ -f ../../ip_vs.h ]; then    \
diff -Naur ipvsadm-1.24/Makefile ipvsadm-1.24-scu/Makefile
--- ipvsadm-1.24/Makefile    2005-12-11 03:00:07.000000000 +1100
+++ ipvsadm-1.24-scu/Makefile    2008-09-03 11:12:41.000000000 +1000
@@ -35,7 +35,8 @@
RPMSPECDIR    = $(shell rpm --eval '%_specdir')

CC        = gcc
-INCLUDE        = -I/usr/src/linux/include -I.. -I.
+KERNEL          = $(shell uname -r)-$(shell uname -m)
+INCLUDE        = -I/usr/src/kernels/$(KERNEL)/include -I.. -I.
SBIN        = $(BUILD_ROOT)/sbin
MANDIR        = usr/man
MAN        = $(BUILD_ROOT)/$(MANDIR)/man8

_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems

Reply via email to