summaryrefslogtreecommitdiff
path: root/dev-db
diff options
context:
space:
mode:
authorTiziano Müller <dev-zero@gentoo.org>2010-04-05 06:14:53 +0000
committerTiziano Müller <dev-zero@gentoo.org>2010-04-05 06:14:53 +0000
commit08abe0523963a390b73bff37311e5f3796ca005c (patch)
treee7fbe5ef5656419cddf094b7e2f32c16f1cd8f14 /dev-db
parentVersion bump to be in sync with the rest; no code changes (diff)
downloadgentoo-2-08abe0523963a390b73bff37311e5f3796ca005c.tar.gz
gentoo-2-08abe0523963a390b73bff37311e5f3796ca005c.tar.bz2
gentoo-2-08abe0523963a390b73bff37311e5f3796ca005c.zip
Version bump (needed for samba-3.5.x, one patch not needed anymore, other patch ported), fixed tests (bug #278141).
(Portage version: 2.2_rc67/cvs/Linux x86_64)
Diffstat (limited to 'dev-db')
-rw-r--r--dev-db/ctdb/ChangeLog11
-rw-r--r--dev-db/ctdb/ctdb-1.0.114_p1.ebuild62
-rw-r--r--dev-db/ctdb/files/ctdb-1.0.114_p1-functions.patch77
3 files changed, 148 insertions, 2 deletions
diff --git a/dev-db/ctdb/ChangeLog b/dev-db/ctdb/ChangeLog
index 237f4ca078d3..6c0b8cfcbae8 100644
--- a/dev-db/ctdb/ChangeLog
+++ b/dev-db/ctdb/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for dev-db/ctdb
-# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/ctdb/ChangeLog,v 1.11 2009/11/30 16:02:46 armin76 Exp $
+# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-db/ctdb/ChangeLog,v 1.12 2010/04/05 06:14:52 dev-zero Exp $
+
+*ctdb-1.0.114_p1 (05 Apr 2010)
+
+ 05 Apr 2010; Tiziano Müller <dev-zero@gentoo.org>
+ +ctdb-1.0.114_p1.ebuild, +files/ctdb-1.0.114_p1-functions.patch:
+ Version bump (needed for samba-3.5.x, one patch not needed anymore, other
+ patch ported), fixed tests (bug #278141).
30 Nov 2009; Raúl Porcel <armin76@gentoo.org> ctdb-1.0.88.ebuild:
Add ~arm/~ia64/~s390/~sh/~sparc wrt #285952
diff --git a/dev-db/ctdb/ctdb-1.0.114_p1.ebuild b/dev-db/ctdb/ctdb-1.0.114_p1.ebuild
new file mode 100644
index 000000000000..ed685dae5162
--- /dev/null
+++ b/dev-db/ctdb/ctdb-1.0.114_p1.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-db/ctdb/ctdb-1.0.114_p1.ebuild,v 1.1 2010/04/05 06:14:52 dev-zero Exp $
+
+EAPI="2"
+
+inherit autotools rpm
+
+DESCRIPTION="A cluster implementation of the TDB database used by Samba and other projects to store temporary data."
+HOMEPAGE="http://ctdb.samba.org/"
+SRC_URI="http://ctdb.samba.org/packages/redhat/RHEL5/${P/_p/-}.src.rpm
+ http://ctdb.samba.org/packages/redhat/RHEL5/old/${P/_p/-}.src.rpm"
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
+IUSE="test"
+
+RDEPEND="dev-libs/popt"
+DEPEND="${RDEPEND}
+ test? ( sys-apps/iproute2
+ sys-process/procps )"
+
+S="${WORKDIR}/${P/_p*}"
+
+src_prepare() {
+ AT_M4DIR="-I ${S}/lib/replace -I ${S}/lib/talloc -I ${S}/lib/tdb -I ${S}/lib/popt -I ${S}/lib/events"
+ autotools_run_tool autoheader ${AT_M4DIR} || die "running autoheader failed"
+ eautoconf ${AT_M4DIR}
+
+ # fix tests
+ sed -i \
+ -e "s|/tmp|${T}|" \
+ tests/simple/54_ctdb_transaction_recovery.sh || die "sed failed"
+
+ # the following tests assume that the setup was indeed able to add new ip
+ # addresses to the lo device (11,16), resp make assumptions about the
+ # performance (52)
+ rm \
+ tests/simple/{11,16,52}_*.sh || die "removing failing tests failed"
+
+ epatch \
+ "${FILESDIR}/${PN}-50.samba_gentoo.patch" \
+ "${FILESDIR}/${P}-functions.patch"
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die "emake install failed"
+
+ dodoc "${D}/usr/share/doc/ctdb/README.eventscripts"
+ rm -rf "${D}/usr/share/doc/ctdb"
+
+ dohtml web/* doc/*.html
+
+ newinitd "${FILESDIR}/${PN}.initd" ctdb || die "newinitd failed"
+ newconfd "${S}/config/ctdb.sysconfig" ctdb || die "newconfd failed"
+}
+
+src_test() {
+ emake test || { pkill ctdb ; die "running tests failed" ; }
+ pkill ctdb
+}
+
diff --git a/dev-db/ctdb/files/ctdb-1.0.114_p1-functions.patch b/dev-db/ctdb/files/ctdb-1.0.114_p1-functions.patch
new file mode 100644
index 000000000000..c70350c110ab
--- /dev/null
+++ b/dev-db/ctdb/files/ctdb-1.0.114_p1-functions.patch
@@ -0,0 +1,77 @@
+diff -Naur ctdb-1.0.114.orig/config/functions ctdb-1.0.114/config/functions
+--- ctdb-1.0.114.orig/config/functions 2010-04-04 18:01:18.278707515 +0200
++++ ctdb-1.0.114/config/functions 2010-04-04 18:08:05.792447032 +0200
+@@ -22,6 +22,8 @@
+ . /etc/default/$1
+ elif [ -f $CTDB_BASE/sysconfig/$1 ]; then
+ . $CTDB_BASE/sysconfig/$1
++ elif [ -f /etc/config.d/$1 ]; then
++ . /etc/config.d/$name
+ fi
+ }
+
+@@ -33,6 +35,8 @@
+
+ if [ -x /sbin/startproc ]; then
+ CTDB_INIT_STYLE="suse"
++ elif [ -x /bin/rc-status ] ; then
++ CTDB_INIT_STYLE="gentoo"
+ elif [ -x /sbin/start-stop-daemon ]; then
+ CTDB_INIT_STYLE="debian"
+ else
+@@ -356,6 +360,9 @@
+ [ -x /etc/init.d/nfslock ] && {
+ PLATFORM="rhel"
+ }
++ [ -x etc/init.d/nfs ] && {
++ PLATFORM="gentoo"
++ }
+
+ case $PLATFORM in
+ sles)
+@@ -380,6 +387,16 @@
+ ;;
+ esac
+ ;;
++ gentoo)
++ case $1 in
++ start)
++ service nfs start
++ ;;
++ stop)
++ service nfs stop > /dev/null 2>&1
++ ;;
++ esac
++ ;;
+ *)
+ echo "Unknown platform. NFS is not supported with ctdb"
+ exit 1
+@@ -398,6 +415,9 @@
+ [ -x /etc/init.d/nfslock ] && {
+ PLATFORM="rhel"
+ }
++ [ -x etc/init.d/nfs ] && {
++ PLATFORM="gentoo"
++ }
+
+ case $PLATFORM in
+ sles)
+@@ -422,6 +442,18 @@
+ ;;
+ esac
+ ;;
++ gentoo)
++ # for gentoo there is no service for lockmanager
++ # so we instead just shutdown/restart nfs
++ case $1 in
++ start)
++ service nfs start
++ ;;
++ stop)
++ service nfs stop > /dev/null 2>&1
++ ;;
++ esac
++ ;;
+ *)
+ echo "Unknown platform. NFS locking is not supported with ctdb"
+ exit 1