etcd: add v2.0.4

This commit is contained in:
Alex Crawford 2015-02-10 16:21:13 -08:00 committed by Michael Marineau
parent d9f1dadffb
commit 10f3130d41
4 changed files with 27 additions and 9 deletions

View File

@ -80,8 +80,11 @@ RDEPEND="${RDEPEND}
# If protocol 1 is installed it must be configured to provide the default # If protocol 1 is installed it must be configured to provide the default
# implementation based on whether protocol 2 is enabled or not. # implementation based on whether protocol 2 is enabled or not.
RDEPEND="${RDEPEND} RDEPEND="${RDEPEND}
dev-db/etcdctl etcd_protocols_1? (
etcd_protocols_1? ( dev-db/etcd:1[etcd_protocols_2=] ) dev-db/etcd:1[etcd_protocols_2=]
!etcd_protocols_2? ( dev-db/etcdctl )
)
etcd_protocols_2? ( dev-db/etcd:2 )
" "
RDEPEND="${RDEPEND} RDEPEND="${RDEPEND}

View File

@ -0,0 +1 @@
etcd-9999.ebuild

View File

@ -1,19 +1,20 @@
# #
# Copyright (c) 2014 CoreOS, Inc.. All rights reserved. # Copyright (c) 2015 CoreOS, Inc.. All rights reserved.
# Distributed under the terms of the GNU General Public License v2 # Distributed under the terms of the GNU General Public License v2
# $Header:$ # $Header:$
# #
EAPI=4 EAPI=5
CROS_WORKON_PROJECT="coreos/etcd" CROS_WORKON_PROJECT="coreos/etcd"
CROS_WORKON_LOCALNAME="etcd" CROS_WORKON_LOCALNAME="etcd"
CROS_WORKON_REPO="git://github.com" CROS_WORKON_REPO="git://github.com"
inherit coreos-doc toolchain-funcs cros-workon systemd COREOS_GO_PACKAGE="github.com/coreos/etcd"
inherit coreos-doc coreos-go toolchain-funcs cros-workon systemd
if [[ "${PV}" == 9999 ]]; then if [[ "${PV}" == 9999 ]]; then
KEYWORDS="~amd64" KEYWORDS="~amd64"
else else
CROS_WORKON_COMMIT="d6523fe4638100c72f40cb282cd1232db13f7336" # v0.4.7 CROS_WORKON_COMMIT="1a2c6d3f2fbcb047712bfa3234bff5b9d07bdc57" # v2.0.4
KEYWORDS="amd64" KEYWORDS="amd64"
fi fi
@ -22,17 +23,30 @@ HOMEPAGE="https://github.com/coreos/etcd"
SRC_URI="" SRC_URI=""
LICENSE="Apache-2.0" LICENSE="Apache-2.0"
SLOT="0" SLOT="2"
IUSE="" IUSE=""
DEPEND=">=dev-lang/go-1.2" DEPEND=">=dev-lang/go-1.2"
RDEPEND="!dev-db/etcd:0
!dev-db/etcdctl"
src_compile() { src_compile() {
./build go_build "${COREOS_GO_PACKAGE}"
go_build "${COREOS_GO_PACKAGE}/etcdctl"
go_build "${COREOS_GO_PACKAGE}/tools/etcd-migrate"
go_build "${COREOS_GO_PACKAGE}/tools/etcd-dump-logs"
} }
src_install() { src_install() {
dobin ${S}/bin/${PN} local libexec="libexec/${PN}/internal_versions"
dobin ${WORKDIR}/gopath/bin/etcdctl
dobin ${WORKDIR}/gopath/bin/etcd-migrate
dobin ${WORKDIR}/gopath/bin/etcd-dump-logs
exeinto "/usr/${libexec}"
newexe "${WORKDIR}/gopath/bin/${PN}" ${SLOT}
dosym "../${libexec}/${SLOT}" /usr/bin/${PN}
systemd_dounit "${FILESDIR}"/${PN}.service systemd_dounit "${FILESDIR}"/${PN}.service
systemd_dotmpfilesd "${FILESDIR}"/${PN}.conf systemd_dotmpfilesd "${FILESDIR}"/${PN}.conf