From e10e0680840d7cdc0ca434dd677896395169cabe Mon Sep 17 00:00:00 2001 From: Euan Kemp Date: Mon, 21 Aug 2017 13:49:57 -0700 Subject: [PATCH] dev-db/etcd: add etcdctl useflag This paves the way to including the etcdctl binary from another package. See https://github.com/coreos/bugs/issues/1717 for some context around this. As discussed on that issue, a long term solution here might be torcx. However, I don't think we need to actually wait for torcx to do this since the etcd3 cli is meant to be perfectly backwards compatible. This will also allow our docs around using `etcd-member.service` to be more readable/usable, since right now the docs don't have an easy way to talk to the etcd cluster from a Contaienr Linux machine. --- .../etcd/{etcd-2.3.7-r1.ebuild => etcd-2.3.7-r2.ebuild} | 0 .../coreos-overlay/dev-db/etcd/etcd-9999.ebuild | 8 ++++---- 2 files changed, 4 insertions(+), 4 deletions(-) rename sdk_container/src/third_party/coreos-overlay/dev-db/etcd/{etcd-2.3.7-r1.ebuild => etcd-2.3.7-r2.ebuild} (100%) diff --git a/sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-2.3.7-r1.ebuild b/sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-2.3.7-r2.ebuild similarity index 100% rename from sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-2.3.7-r1.ebuild rename to sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-2.3.7-r2.ebuild diff --git a/sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-9999.ebuild b/sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-9999.ebuild index 9b7033e39d..80d55f2e7e 100644 --- a/sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-9999.ebuild +++ b/sdk_container/src/third_party/coreos-overlay/dev-db/etcd/etcd-9999.ebuild @@ -25,19 +25,19 @@ SRC_URI="" LICENSE="Apache-2.0" SLOT="2" -IUSE="" +IUSE="+etcdctl" RDEPEND="!dev-db/etcd:0 - !dev-db/etcdctl" + etcdctl? ( !dev-db/etcdctl )" src_compile() { GO_LDFLAGS="-X ${COREOS_GO_PACKAGE}/version.GitSHA=${CROS_WORKON_COMMIT:0:7}" go_build "${COREOS_GO_PACKAGE}" - go_build "${COREOS_GO_PACKAGE}/etcdctl" + use etcdctl && go_build "${COREOS_GO_PACKAGE}/etcdctl" } src_install() { - dobin ${WORKDIR}/gopath/bin/etcdctl + use etcdctl && dobin ${WORKDIR}/gopath/bin/etcdctl newbin "${WORKDIR}/gopath/bin/${PN}" "${PN}${SLOT}" systemd_dounit "${FILESDIR}/${PN}${SLOT}.service"