diff options
author | Diego Elio Pettenò <flameeyes@gentoo.org> | 2010-09-16 19:43:07 +0000 |
---|---|---|
committer | Diego Elio Pettenò <flameeyes@gentoo.org> | 2010-09-16 19:43:07 +0000 |
commit | 0f0e808e8643720b933a3a6e9d597af10bdd4571 (patch) | |
tree | 00cca18dc209935417b7799b5fef55c4d8d70132 /sys-cluster/gearmand | |
parent | Respects LDFLAGS now, see bug #337653. (diff) | |
download | gentoo-2-0f0e808e8643720b933a3a6e9d597af10bdd4571.tar.gz gentoo-2-0f0e808e8643720b933a3a6e9d597af10bdd4571.tar.bz2 gentoo-2-0f0e808e8643720b933a3a6e9d597af10bdd4571.zip |
Version bump; also update init script to (re-)create run and log directories if missing, with the proper permissions.
(Portage version: 2.2_rc82/cvs/Linux x86_64)
Diffstat (limited to 'sys-cluster/gearmand')
-rw-r--r-- | sys-cluster/gearmand/ChangeLog | 9 | ||||
-rw-r--r-- | sys-cluster/gearmand/files/gearmand.init.d | 15 | ||||
-rw-r--r-- | sys-cluster/gearmand/gearmand-0.14.ebuild | 94 |
3 files changed, 116 insertions, 2 deletions
diff --git a/sys-cluster/gearmand/ChangeLog b/sys-cluster/gearmand/ChangeLog index 40cf499b7161..5b5d181b989d 100644 --- a/sys-cluster/gearmand/ChangeLog +++ b/sys-cluster/gearmand/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for sys-cluster/gearmand # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-cluster/gearmand/ChangeLog,v 1.8 2010/09/06 20:23:04 flameeyes Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-cluster/gearmand/ChangeLog,v 1.9 2010/09/16 19:43:07 flameeyes Exp $ + +*gearmand-0.14 (16 Sep 2010) + + 16 Sep 2010; Diego E. Pettenò <flameeyes@gentoo.org> + +gearmand-0.14.ebuild, files/gearmand.init.d: + Version bump; also update init script to (re-)create run and log + directories if missing, with the proper permissions. 06 Sep 2010; Diego E. Pettenò <flameeyes@gentoo.org> -gearmand-0.11-r2.ebuild, gearmand-0.12.ebuild: diff --git a/sys-cluster/gearmand/files/gearmand.init.d b/sys-cluster/gearmand/files/gearmand.init.d index 10ec883f8a35..50414a77d45b 100644 --- a/sys-cluster/gearmand/files/gearmand.init.d +++ b/sys-cluster/gearmand/files/gearmand.init.d @@ -1,5 +1,5 @@ #!/sbin/runscript -# Copyright 2009 Pavel Stratil, senbonzakura.eu +# Copyright 2009-2010 Pavel Stratil, senbonzakura.eu # Distributed under the terms of the GNU General Public License v2 depend() { @@ -63,6 +63,19 @@ start() { ;; esac + + if [ ! -d /var/run/gearmand ] ; then + mkdir -p /var/run/gearmand + chown gearmand:nogroup /var/run/gearmand + chmod 0755 /var/run/gearmand + fi + + if [ ! -d /var/log/gearmand ] ; then + mkdir -p /var/log/gearmand + chown gearmand:nogroup /var/log/gearmand + chmod 0755 /var/log/gearmand + fi + ebegin "Starting ${SVCNAME}" start-stop-daemon --pidfile /var/run/gearmand/gearmand.pid --start \ --exec /usr/sbin/gearmand -- --pid-file=/var/run/gearmand/gearmand.pid \ diff --git a/sys-cluster/gearmand/gearmand-0.14.ebuild b/sys-cluster/gearmand/gearmand-0.14.ebuild new file mode 100644 index 000000000000..000a567d0221 --- /dev/null +++ b/sys-cluster/gearmand/gearmand-0.14.ebuild @@ -0,0 +1,94 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $ + +EAPI=2 + +inherit flag-o-matic libtool + +DESCRIPTION="Generic framework to farm out work to other machines" +HOMEPAGE="http://www.gearman.org/" +SRC_URI="http://launchpad.net/gearmand/trunk/${PV}/+download/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="debug tcmalloc +memcache drizzle sqlite tokyocabinet" # postgres +# postgresql support is broken right now so keep it disabled +RESTRICT="test" +# restricting tests because of failures, package runs fine + +RDEPEND="dev-libs/libevent + || ( >=sys-apps/util-linux-2.16 <sys-libs/e2fsprogs-libs-1.41.8 ) + tcmalloc? ( dev-util/google-perftools ) + memcache? ( dev-libs/libmemcached ) + drizzle? ( >=dev-db/drizzle-2010.08.1742 ) + sqlite? ( dev-db/sqlite:3 ) + tokyocabinet? ( dev-db/tokyocabinet )" + #postgres? ( dev-db/postgresql-base )" +DEPEND="${RDEPEND}" + +pkg_setup() { + enewuser gearmand -1 -1 /dev/null nogroup +} + +src_prepare() { + elibtoolize +} + +src_configure() { + # Don't ever use --enable-assert since configure.ac is broken, and + # only does --disable-assert correctly. + if use debug; then + # Since --with-debug would turn off optimisations as well as + # enabling debug, we just enable debug through the + # preprocessor then. + append-flags -DDEBUG + + else + myconf="${myconf} --disable-assert" + fi + + #$(use_enable postgres libpq) + econf \ + --disable-static \ + --disable-dependency-tracking \ + --disable-mtmalloc \ + --disable-libpq \ + $(use_enable tcmalloc) \ + $(use_enable memcache libmemcached) \ + $(use_enable drizzle libdrizzle) \ + $(use_enable sqlite libsqlite3) \ + $(use_enable tokyocabinet libtokyocabinet) +} + +src_test() { + # Since libtool is stupid and doesn't discard /usr/lib64 from the + # load path, we'd end up testing against the installed copy of + # gearmand (bad). + # + # We thus cheat and "fix" the scripts by hand. + sed -i -e '/LD_LIBRARY_PATH=/s|/usr/lib64:||' "${S}"/tests/*_test \ + || die "test fixing failed" + + emake check || die "tests failed" +} + +src_install() { + emake DESTDIR="${D}" install || die "install failed" + + dodoc README AUTHORS ChangeLog || die "dodoc failed" + + newinitd "${FILESDIR}"/gearmand.init.d gearmand || die + newconfd "${FILESDIR}"/gearmand.conf.d gearmand || die + + find "${D}" -name '*.la' -delete || die +} + +pkg_postinst() { + elog "" + elog "Unless you set the PERSISTENT_TABLE option in" + elog "/etc/conf.d/gearmand, Gearmand will use table 'queue'." + elog "If such table doesn't exist, Gearmand will create it for you" + elog "" +} |