summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2009-10-10 17:39:51 +0000
committerRobin H. Johnson <robbat2@gentoo.org>2009-10-10 17:39:51 +0000
commit84c406b8fa42ad25f6231c3e821c82bc83699f5f (patch)
treee44fdfe0b67cd1a0f785a138a7aab025c21b42e2 /sys-cluster/ipvsadm
parentMerge from Prefix (diff)
downloadgentoo-2-84c406b8fa42ad25f6231c3e821c82bc83699f5f.tar.gz
gentoo-2-84c406b8fa42ad25f6231c3e821c82bc83699f5f.tar.bz2
gentoo-2-84c406b8fa42ad25f6231c3e821c82bc83699f5f.zip
Version bump as requested in bug #288436. Lots of build fixes included: parallel fix, CFLAGS, real -fPIC, libnl, no more kernel sources needed.
(Portage version: 2.2_rc42/cvs/Linux x86_64)
Diffstat (limited to 'sys-cluster/ipvsadm')
-rw-r--r--sys-cluster/ipvsadm/ChangeLog9
-rw-r--r--sys-cluster/ipvsadm/files/ipvsadm-1.25-build-fixup.diff78
-rw-r--r--sys-cluster/ipvsadm/ipvsadm-1.25.ebuild67
3 files changed, 153 insertions, 1 deletions
diff --git a/sys-cluster/ipvsadm/ChangeLog b/sys-cluster/ipvsadm/ChangeLog
index b46848ced798..1d9a04f0ee09 100644
--- a/sys-cluster/ipvsadm/ChangeLog
+++ b/sys-cluster/ipvsadm/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for sys-cluster/ipvsadm
# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/ChangeLog,v 1.38 2009/09/23 20:40:53 patrick Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/ChangeLog,v 1.39 2009/10/10 17:39:51 robbat2 Exp $
+
+*ipvsadm-1.25 (10 Oct 2009)
+
+ 10 Oct 2009; Robin H. Johnson <robbat2@gentoo.org> +ipvsadm-1.25.ebuild,
+ +files/ipvsadm-1.25-build-fixup.diff:
+ Version bump as requested in bug #288436. Lots of build fixes included:
+ parallel fix, CFLAGS, real -fPIC, libnl, no more kernel sources needed.
23 Sep 2009; Patrick Lauer <patrick@gentoo.org> ipvsadm-1.21-r1.ebuild:
Remove virtual/libc
diff --git a/sys-cluster/ipvsadm/files/ipvsadm-1.25-build-fixup.diff b/sys-cluster/ipvsadm/files/ipvsadm-1.25-build-fixup.diff
new file mode 100644
index 000000000000..dee72895c200
--- /dev/null
+++ b/sys-cluster/ipvsadm/files/ipvsadm-1.25-build-fixup.diff
@@ -0,0 +1,78 @@
+diff -Nuar --exclude '*.spec' ipvsadm-1.25.orig/libipvs/Makefile ipvsadm-1.25/libipvs/Makefile
+--- ipvsadm-1.25.orig/libipvs/Makefile 2008-09-21 10:02:03.000000000 +0000
++++ ipvsadm-1.25/libipvs/Makefile 2009-10-10 17:28:48.000000000 +0000
+@@ -1,14 +1,14 @@
+ # Makefile for libipvs
+
+ CC = gcc
+-CFLAGS = -Wall -Wunused -Wstrict-prototypes -g -fPIC
++OPTFLAGS = -Wall -Wunused -Wstrict-prototypes -fPIC
+ ifneq (0,$(HAVE_NL))
+-CFLAGS += -DLIBIPVS_USE_NL
++DEFINES += -DLIBIPVS_USE_NL
+ endif
+
+ INCLUDE += $(shell if [ -f ../../ip_vs.h ]; then \
+ echo "-I../../."; fi;)
+-DEFINES = $(shell if [ ! -f ../../ip_vs.h ]; then \
++DEFINES += $(shell if [ ! -f ../../ip_vs.h ]; then \
+ echo "-DHAVE_NET_IP_VS_H"; fi;)
+
+ .PHONY = all clean install dist distclean rpm rpms
+@@ -24,7 +24,7 @@
+ $(CC) -shared -Wl,-soname,$@ -o $@ $^
+
+ %.o: %.c
+- $(CC) $(CFLAGS) $(INCLUDE) $(DEFINES) -c -o $@ $<
++ $(CC) $(OPTFLAGS) $(CFLAGS) $(INCLUDE) $(DEFINES) -c -o $@ $<
+
+ clean:
+ rm -f *.[ao] *~ *.orig *.rej core *.so
+diff -Nuar --exclude '*.spec' ipvsadm-1.25.orig/Makefile ipvsadm-1.25/Makefile
+--- ipvsadm-1.25.orig/Makefile 2008-09-23 16:14:46.000000000 +0000
++++ ipvsadm-1.25/Makefile 2009-10-10 17:33:55.000000000 +0000
+@@ -45,11 +45,11 @@
+ STATIC_LIBS = libipvs/libipvs.a
+
+ ifeq "${ARCH}" "sparc64"
+- CFLAGS = -Wall -Wunused -Wstrict-prototypes -g -m64 -pipe -mcpu=ultrasparc -mcmodel=medlow
++ CFLAGS := -g -m64 -pipe -mcpu=ultrasparc -mcmodel=medlow
+ else
+- CFLAGS = -Wall -Wunused -Wstrict-prototypes -g
++ CFLAGS := -g
+ endif
+-
++OPTFLAGS += -Wall -Wunused -Wstrict-prototypes
+
+ #####################################
+ # No servicable parts below this line
+@@ -92,10 +92,12 @@
+ all: libs ipvsadm
+
+ libs:
+- make -C libipvs
++ $(MAKE) -C libipvs
++
++$(STATIC_LIBS): libs
+
+ ipvsadm: $(OBJS) $(STATIC_LIBS)
+- $(CC) $(CFLAGS) -o $@ $^ $(LIBS)
++ $(CC) $(OPTFLAGS) $(CFLAGS) -o $@ $^ $(LIBS)
+
+ install: all
+ if [ ! -d $(SBIN) ]; then $(MKDIR) -p $(SBIN); fi
+@@ -115,7 +117,7 @@
+ rm -rf debian/tmp
+ find . -name '*.[ao]' -o -name "*~" -o -name "*.orig" \
+ -o -name "*.rej" -o -name core | xargs rm -f
+- make -C libipvs clean
++ $(MAKE) -C libipvs clean
+
+ distclean: clean
+
+@@ -148,4 +150,4 @@
+ dpkg-buildpackage
+
+ %.o: %.c
+- $(CC) $(CFLAGS) $(INCLUDE) $(DEFINES) -c -o $@ $<
++ $(CC) $(OPTFLAGS) $(CFLAGS) $(INCLUDE) $(DEFINES) -c -o $@ $<
diff --git a/sys-cluster/ipvsadm/ipvsadm-1.25.ebuild b/sys-cluster/ipvsadm/ipvsadm-1.25.ebuild
new file mode 100644
index 000000000000..740a9182eee9
--- /dev/null
+++ b/sys-cluster/ipvsadm/ipvsadm-1.25.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ipvsadm/ipvsadm-1.25.ebuild,v 1.1 2009/10/10 17:39:51 robbat2 Exp $
+
+EAPI=2
+inherit linux-info toolchain-funcs eutils
+
+DESCRIPTION="utility to administer the IP virtual server services offered by the Linux kernel"
+HOMEPAGE="http://linuxvirtualserver.org/"
+SRC_URI="http://www.linuxvirtualserver.org/software/kernel-2.6/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ia64 ~ppc64 ~s390 ~sparc ~x86"
+IUSE=""
+
+RDEPEND=">=sys-libs/ncurses-5.2
+ dev-libs/libnl"
+DEPEND="${RDEPEND}"
+
+pkg_setup() {
+ if kernel_is 2 4; then
+ eerror "${P} supports only 2.6 kernels, please try ${PN}-1.21 for 2.4 kernels"
+ die "wrong kernel version"
+ fi
+}
+
+src_prepare() {
+ epatch "${FILESDIR}"/ipvsadm-1.25-build-fixup.diff
+}
+
+src_compile() {
+ emake \
+ INCLUDE="-I.. -I." \
+ CFLAGS="${CFLAGS}" \
+ CC="$(tc-getCC)" \
+ HAVE_NL=1 \
+ || die "error compiling source"
+}
+
+src_install() {
+ into /
+ dosbin ipvsadm ipvsadm-save ipvsadm-restore || die
+
+ into /usr
+ doman ipvsadm.8 ipvsadm-save.8 ipvsadm-restore.8 || die
+
+ newinitd "${FILESDIR}"/ipvsadm-init ipvsadm
+ keepdir /var/lib/ipvsadm
+
+ diropts -m 755 -o root -g root
+ dodir /usr/$(get_libdir)
+ dodir /usr/include/ipvs
+
+ insopts -m 644 -o root -g root
+ insinto /usr/$(get_libdir)
+ dolib.a libipvs/libipvs.a || die
+ dolib.so libipvs/libipvs.so || die
+
+ insinto /usr/include/ipvs
+ newins libipvs/libipvs.h ipvs.h || die
+}
+
+pkg_postinst() {
+ einfo "You will need a kernel that has ipvs patches to use LVS."
+ einfo "This version is specifically for 2.6 kernels."
+}