summaryrefslogtreecommitdiff
path: root/dev-db/cockroach
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-db/cockroach
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-db/cockroach')
-rw-r--r--dev-db/cockroach/Manifest22
-rw-r--r--dev-db/cockroach/cockroach-1.0-r1.ebuild61
-rw-r--r--dev-db/cockroach/cockroach-1.0.1.ebuild61
-rw-r--r--dev-db/cockroach/cockroach-1.0.3.ebuild61
-rw-r--r--dev-db/cockroach/cockroach-1.0.ebuild61
-rw-r--r--dev-db/cockroach/cockroach-1.0_rc1.ebuild59
-rw-r--r--dev-db/cockroach/cockroach-1.1.2.ebuild61
-rw-r--r--dev-db/cockroach/cockroach-1.1.3.ebuild63
-rw-r--r--dev-db/cockroach/cockroach-2.0.1.ebuild65
-rw-r--r--dev-db/cockroach/files/cockroach-limits.conf4
-rw-r--r--dev-db/cockroach/files/cockroach.confd14
-rw-r--r--dev-db/cockroach/files/cockroach.confd-1.045
-rw-r--r--dev-db/cockroach/files/cockroach.initd23
-rw-r--r--dev-db/cockroach/files/cockroach.initd-1.060
-rw-r--r--dev-db/cockroach/files/cockroach.initd-1.0.170
-rw-r--r--dev-db/cockroach/metadata.xml12
16 files changed, 742 insertions, 0 deletions
diff --git a/dev-db/cockroach/Manifest b/dev-db/cockroach/Manifest
new file mode 100644
index 000000000000..d754aca3fc5a
--- /dev/null
+++ b/dev-db/cockroach/Manifest
@@ -0,0 +1,22 @@
+AUX cockroach-limits.conf 136 BLAKE2B 78020250f472fd810a27bd22f9f76e531c09d6748db9d808e5c7fe731bd8d8f4db983eb374220fa1a6224866f116f9c0e7e53023078b94b7b880bd70d8b32b0b SHA512 c8c68263967f0d25eaf29dc3023046edeaf9e36f23f6f296d7e1dd7b2126a0b4f431af60e34fcb5c075855260f19d7ffc0516d6ef68ff852b3c95a2632cdd6ae
+AUX cockroach.confd 521 BLAKE2B 58fbe1b859cfd2c988c55a2f3aa067bab60ca30da67e85dbf99ae603c08abb646045285dd1931651945bf45100d46e61a6da5bc5ff424366dbf8e492c871283a SHA512 81efbc65e1e6dbcc4f98ab0f9ca201c9dd299140ee31cc04bfab82c7d33215a69cad15b3c190c23eb0e4a11b9050bc588b5d1097630bf2ebee4f3f14d53f3183
+AUX cockroach.confd-1.0 1324 BLAKE2B 8a906ce78a86b2b95c2b6d5777ea116462e5d6ad47b3ba72e88637e227d34f0d411af557dc8e049706740d62d9fc724b432d99d5bab1502b5e05b0af1d860eb3 SHA512 538042bb5484acfdb31c5a750be73d5e6efeb03a3b243d5bc204db9266a7b02daf7ea9d4687fd3a5223dc6d493a1672c1b581e4527599cb3e7c31e11ec2742fd
+AUX cockroach.initd 542 BLAKE2B c59d584d90442ee97bd6b2e4a564bd348073680efc09e22cde650e365487de91025413cdd0feaac2f42e752aa4debba2da9bda15634e7464cf53cf5550e74fba SHA512 86684b238413812b6787bf0841dc34302f80b9ad2c25a47a349100503b37f61ec8851870c29bb4fe697216443a39ad5e2decbcedea90664adb3b7316c440e345
+AUX cockroach.initd-1.0 1676 BLAKE2B f74872fe73a571ad29e4c85193c35f1c139ce316b951dd25b695f220269f582597635216feac04e7d5d00aab6d8ed459e93c543fe7ee86fe804e9ce33dce7280 SHA512 5f0b6ade2b25372cfc7d810d9dbe10e9732e79527c0ad73eec0cdbbad894a773bfd4aaffb958d3c0e0e7ecb636a07214be494cfdd5e69f4faacc30849f7e3eb9
+AUX cockroach.initd-1.0.1 1820 BLAKE2B f3080961c251e23a01c1e5664a0112d5cab809278bfb4d1d2dbb388bb483c519e08f87e528c2c3b35519b3781890815a574442828b93913de80c5459a79454e6 SHA512 df0c06bb6ee97c3f531250486ca1fe3d2333c1e280e2d0acb24c9aa061bd6ba35358504e29bf934a382e0a677c812e6dd474e78fcab1cd5188e93e8082748e04
+DIST cockroach-v1.0-rc.1.src.tgz 68784067 BLAKE2B 5f5ed18ee535d30e004f2170b20ac96ed801e5fa9dee55ddbda7543e24d35ed940711d2e7b307b5a76383637f9e113eec3ac1fa28eb08751068cf94627c08f3b SHA512 c68fc712068cbfce167d98008cdcb46270a8fa772624281da23a70d0492c7990c9ce8513334fedc31d7dde5176087fa6211a4e90d77741ed0079f9568c71e0ff
+DIST cockroach-v1.0.1.src.tgz 69116931 BLAKE2B a1abc0353fc815eb5432a327969d48d4ea893484d5488161972ce84fa24aaa06203481cc381ba3918cdf87ad6ebe846e407918bc0b3e5e4abd6a6d4c3ac5014a SHA512 d388d84c09f1318420f859c964c46b78e5237685fbc2b1a8d55fad2ce1dabc89461ad5eaa6d95283dda4551542f33e5df2feda4afd7129e1f850e469e0d17e69
+DIST cockroach-v1.0.3.src.tgz 69127502 BLAKE2B 803f88e19a6128f18024748610c1af3e912f6f4fbc8af9216b212aacf58422382d5c5b5f61453b7373bc680e7894d6b57f4f47040581f9981002be7cbce42975 SHA512 2bae99faba0f56774ab964d920f8628afc6af61ce53bc3e99f1b360c0606e0777b90dd93cbd6844109c3224867fc4180fb42e6dacc75e4eb4db8a4f93f586577
+DIST cockroach-v1.0.src.tgz 68753479 BLAKE2B 6377614e9fee896a0115909b02d8a191a7aabe8da341c98547c0ac496d2e8fcce801e35f93a8a126c9d65c1106e0217359b161825a11597da1db113ca6a51216 SHA512 d74ad9546908535f9a7ad4172a04a5f86f5ed22698bbb005aec7478a52632e0497a966b859fd68b40894eb7ee68bfa80dc4188d198f2f23725b9cadd50a55191
+DIST cockroach-v1.1.2.src.tgz 79607942 BLAKE2B 39ce9db2ada1c9a5727431438d4d8fe0d5a31af3161816ee7af672c69909aa6b4681edabdfabc332c00ba3b0a142ea7d700851c8833b80947fdbcc88b7fa2c7e SHA512 385e33ec30c23d84403938420a2fcd66edff02a5c4b9d6220ce3683d833f065010953fd78ee57120c24f2947509b2fd29eeee2a45fd3ad47c16a6c8d779534d2
+DIST cockroach-v1.1.3.src.tgz 79615899 BLAKE2B 86d9a63a5e5e8f21114dda500f30a007bf64769b76322fae282d06fa9eb63eb8a965bf990378c624ccac66124efadf1a0dfdebbc8dc8c6f04173e20334341e89 SHA512 f6dc4178e91fd47aec1fce658c9d621183f0bdcdc6101b87f8187757ab9b965c27e48d0d628dd9c10a386bc1a2f184d9d03270243baf0ec4758c812caac5fda1
+DIST cockroach-v2.0.1.src.tgz 45511681 BLAKE2B 9d0828e5e6bd41bb5590e58f0e18b8a07169335b9ff1284daf89b48dae6eea3cdb683bf8af703b5bac46978e8c37b4a092c53a3d7e18de626acc2095a7daf2a2 SHA512 ad7c64dc70cde6bbd10cabafe595ce35deeda9284880bebde75e41a4b1355aa85f01fb8c6b6ff0bae498b4b04a8d7d60bafc986c49875cff9ccf0ead0bc481a7
+EBUILD cockroach-1.0-r1.ebuild 1703 BLAKE2B 263b32177c96e6c5f4512c6eb60cbef7310fdbac297f5219f3e3d8ba708befe6ccc7a0eb43467c6dbc4c01542e5eddd899b01d61b0b6aa67fa3950d38b879767 SHA512 f9d54c7b9395e8ef6552211535641b9241df50d922f6c2e8c74c1782538ea25953c8c15fd89bf6ab17c6264b75bcfd23b5fd27ea9b4054f6579a2753b81c9eb3
+EBUILD cockroach-1.0.1.ebuild 1701 BLAKE2B e011a698cd2493fe26d24112a8ae8b9184ff66c7a1bcf25f6933c19374f036781ff093f7d84048c4df219aa93b66b4f3879af68b6835f9c02e62c503d8597841 SHA512 61ded57cbd28008a27b3b8a2e048a89a70be76317d350c29554ac0450de8932c275aedb63f6d032997013abb63b8a29aff4dae107bccf7876d7afe7ed14149df
+EBUILD cockroach-1.0.3.ebuild 1701 BLAKE2B f9e7fb748c2495586fc600dec992a0272cb89a39a48131ae687a469d1ffcda0b6fe5bad83751b514d8f3906c9f6defdfadb3175db34dbf0c9317143865c7cdbb SHA512 b1a0a2adb8555a227bdb9caff6a91efba4c010a82372b5ad446ab2feb9b68a98456b5b60c14513e5aeebae290a56fd936a8c17194821d12f2b910e8e0f3d1979
+EBUILD cockroach-1.0.ebuild 1689 BLAKE2B 1a9afdfb31ac9142f4a21cda3274eea404593ec8f529d01828da009a1c93f2dfe52fd5a467971dbb6f132b9e79aaf54d53720cdee3dd4b25c9768a12fafbd8ad SHA512 66a6c94d7804cdb62eaa66083961d40b2e2fb8d4bde08a084fedf4b57ac67eadb28d97dfd0087b3e5cefd6ab9d1ddf4ec7a05b5e7413d803a5cfbcc2ba0a733b
+EBUILD cockroach-1.0_rc1.ebuild 1593 BLAKE2B 511ff8271f507e055d792d98f12f1adce3eba73b15d198e4adf33d7ac1ba61eefa5c9a436ae8b1b474aac802e961205a49195187067f53320ffe038308a8df13 SHA512 6f273468fd5b869144d474027dd644a9031c18f1b18525c89775c9d8eacdeb59d64b195216189ebe6a2251973abc500b2f3047fc88af7d97aa9798c0db8fa16a
+EBUILD cockroach-1.1.2.ebuild 1701 BLAKE2B f9e7fb748c2495586fc600dec992a0272cb89a39a48131ae687a469d1ffcda0b6fe5bad83751b514d8f3906c9f6defdfadb3175db34dbf0c9317143865c7cdbb SHA512 b1a0a2adb8555a227bdb9caff6a91efba4c010a82372b5ad446ab2feb9b68a98456b5b60c14513e5aeebae290a56fd936a8c17194821d12f2b910e8e0f3d1979
+EBUILD cockroach-1.1.3.ebuild 1784 BLAKE2B a23a4d6971c40d68bd280917159ef280c534da3339a48ff1d60351ed63f78be331e323a2d311b3a051db072f4dac88dadf7cc460cd2a2f7f59d19dbc7656176d SHA512 48e34da012ea4ffe51278e2d921a6a93e444b9e4a07855664e468d966f867c341c478afa9ea1f41fb31fcb8f6f94e373811e6bea879a4042a3d23f05d24d220b
+EBUILD cockroach-2.0.1.ebuild 1820 BLAKE2B b16dd86cb9bb805db65d47c36bcab1942443942473b96c74c95a53ee55a1878e61247dc58945119bd6a09a1a0ac3bdc5cb9f9ec6fd28db2ab8acdea55b540ca2 SHA512 e8d4fac1f1463ea4643630662d92d187207fcd299bce5c92532ca184fdbf73981e98f07ce5ea56044f255f70a579a46bbfcd202f35a5b1563c0c7b842fddaca2
+MISC metadata.xml 409 BLAKE2B 0fa2933efa8102fa19917f3268b4424257f26efdd94698d22253ed62b562dddc53e09a9312069a9bcf817ccd3f6a0b4423c04c8d8dcbe387e7b30d727e8bdd0c SHA512 e4494324632e55e32fdfe7c1d1b25301b8f7cff3f7475efaf7c6c59d435777eab7245bb200b39b90121babce4e1573038fb0f42e586854a820e1489c1afddd19
diff --git a/dev-db/cockroach/cockroach-1.0-r1.ebuild b/dev-db/cockroach/cockroach-1.0-r1.ebuild
new file mode 100644
index 000000000000..4b19589a461b
--- /dev/null
+++ b/dev-db/cockroach/cockroach-1.0-r1.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v${PV}
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=app-arch/xz-utils-5.2.3
+ >=dev-lang/go-1.8.1
+ >=dev-util/cmake-3.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ emake GOPATH="${S}" build
+}
+
+src_install() {
+ dobin src/github.com/cockroachdb/cockroach/cockroach
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newconfd "${FILESDIR}"/cockroach.confd-${PV} cockroach
+newinitd "${FILESDIR}"/cockroach.initd-${PV} cockroach
+dodir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ ewarn
+ ewarn "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/cockroach-1.0.1.ebuild b/dev-db/cockroach/cockroach-1.0.1.ebuild
new file mode 100644
index 000000000000..212bede14658
--- /dev/null
+++ b/dev-db/cockroach/cockroach-1.0.1.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v${PV}
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=app-arch/xz-utils-5.2.3
+ >=dev-lang/go-1.8.1
+ >=dev-util/cmake-3.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ emake GOPATH="${S}" build
+}
+
+src_install() {
+ dobin src/github.com/cockroachdb/cockroach/cockroach
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newconfd "${FILESDIR}"/cockroach.confd-1.0 cockroach
+newinitd "${FILESDIR}"/cockroach.initd-${PV} cockroach
+dodir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ ewarn
+ ewarn "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/cockroach-1.0.3.ebuild b/dev-db/cockroach/cockroach-1.0.3.ebuild
new file mode 100644
index 000000000000..0b0e1d9f89d0
--- /dev/null
+++ b/dev-db/cockroach/cockroach-1.0.3.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v${PV}
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=app-arch/xz-utils-5.2.3
+ >=dev-lang/go-1.8.3
+ >=dev-util/cmake-3.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ emake GOPATH="${S}" build
+}
+
+src_install() {
+ dobin src/github.com/cockroachdb/cockroach/cockroach
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newconfd "${FILESDIR}"/cockroach.confd-1.0 cockroach
+newinitd "${FILESDIR}"/cockroach.initd-1.0.1 cockroach
+dodir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ ewarn
+ ewarn "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/cockroach-1.0.ebuild b/dev-db/cockroach/cockroach-1.0.ebuild
new file mode 100644
index 000000000000..c7253935686f
--- /dev/null
+++ b/dev-db/cockroach/cockroach-1.0.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v${PV}
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=app-arch/xz-utils-5.2.3
+ >=dev-lang/go-1.8.1
+ >=dev-util/cmake-3.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ emake GOPATH="${S}" build
+}
+
+src_install() {
+ dobin src/github.com/cockroachdb/cockroach/cockroach
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newconfd "${FILESDIR}"/cockroach.confd cockroach
+newinitd "${FILESDIR}"/cockroach.initd cockroach
+dodir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ elog
+ elog "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/cockroach-1.0_rc1.ebuild b/dev-db/cockroach/cockroach-1.0_rc1.ebuild
new file mode 100644
index 000000000000..7ce069fb3180
--- /dev/null
+++ b/dev-db/cockroach/cockroach-1.0_rc1.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v1.0-rc.1
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=dev-lang/go-1.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ emake GOPATH="${S}" build || die
+}
+
+src_install() {
+ emake GOPATH="${S}" install || die
+dobin bin/*
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newinitd "${FILESDIR}"/cockroach.initd cockroach
+dodir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ elog
+ elog "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/cockroach-1.1.2.ebuild b/dev-db/cockroach/cockroach-1.1.2.ebuild
new file mode 100644
index 000000000000..0b0e1d9f89d0
--- /dev/null
+++ b/dev-db/cockroach/cockroach-1.1.2.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v${PV}
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=app-arch/xz-utils-5.2.3
+ >=dev-lang/go-1.8.3
+ >=dev-util/cmake-3.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ emake GOPATH="${S}" build
+}
+
+src_install() {
+ dobin src/github.com/cockroachdb/cockroach/cockroach
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newconfd "${FILESDIR}"/cockroach.confd-1.0 cockroach
+newinitd "${FILESDIR}"/cockroach.initd-1.0.1 cockroach
+dodir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ ewarn
+ ewarn "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/cockroach-1.1.3.ebuild b/dev-db/cockroach/cockroach-1.1.3.ebuild
new file mode 100644
index 000000000000..f2e69031d86f
--- /dev/null
+++ b/dev-db/cockroach/cockroach-1.1.3.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v${PV}
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=app-arch/xz-utils-5.2.3
+ >=dev-lang/go-1.8.3
+ >=dev-util/cmake-3.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ # workaround for https://github.com/cockroachdb/cockroach/issues/20596
+ unset CMAKE_MODULE_PATH
+ emake build
+}
+
+src_install() {
+ dobin src/github.com/cockroachdb/cockroach/cockroach
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newconfd "${FILESDIR}"/cockroach.confd-1.0 cockroach
+newinitd "${FILESDIR}"/cockroach.initd-1.0.1 cockroach
+dodir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ ewarn
+ ewarn "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/cockroach-2.0.1.ebuild b/dev-db/cockroach/cockroach-2.0.1.ebuild
new file mode 100644
index 000000000000..6549c0aea3b0
--- /dev/null
+++ b/dev-db/cockroach/cockroach-2.0.1.ebuild
@@ -0,0 +1,65 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+MY_PV=v${PV}
+CHECKREQS_MEMORY="2G"
+
+inherit check-reqs toolchain-funcs user
+
+DESCRIPTION="open source database for building cloud services"
+HOMEPAGE="https://www.cockroachlabs.com"
+SRC_URI="https://binaries.cockroachdb.com/cockroach-${MY_PV}.src.tgz"
+
+LICENSE="Cockroach Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND=">=app-arch/xz-utils-5.2.3
+ >=dev-lang/go-1.8.3
+ >=dev-util/cmake-3.8.1"
+
+S="${WORKDIR}/cockroach-${MY_PV}"
+
+QA_EXECSTACK="usr/bin/cockroach"
+
+pkg_pretend() {
+ check-reqs_pkg_pretend
+ if [[ ${MERGE_TYPE} != binary && $(gcc-major-version) -lt 6 ]]; then
+ eerror "Cockroach cannot be built with this version of gcc."
+ eerror "You need at least gcc-6.0"
+ die "Your C compiler is too old for this package."
+ fi
+}
+
+pkg_setup() {
+ check-reqs_pkg_setup
+ enewgroup cockroach
+ enewuser cockroach -1 /bin/sh /var/lib/cockroach cockroach
+}
+
+src_compile() {
+ # workaround for https://github.com/cockroachdb/cockroach/issues/20596
+ unset CMAKE_MODULE_PATH
+ emake build
+}
+
+src_install() {
+ dobin src/github.com/cockroachdb/cockroach/cockroach
+insinto /etc/security/limits.d
+newins "${FILESDIR}"/cockroach-limits.conf cockroach.conf
+newconfd "${FILESDIR}"/cockroach.confd-1.0 cockroach
+newinitd "${FILESDIR}"/cockroach.initd-1.0.1 cockroach
+keepdir /var/log/cockroach
+fowners cockroach:cockroach /var/log/cockroach
+if [[ -z ${REPLACING_VERSIONS} ]]; then
+ ewarn "The default setup is for the first node of an insecure"
+ ewarn "cluster that only listens on localhost."
+ ewarn "Please read the cockroach manual at the following url"
+ ewarn "and configure /etc/conf.d/cockroach correctly if you"
+ ewarn "plan to use it in production."
+ ewarn
+ ewarn "http://cockroachlabs.com/docs"
+ fi
+}
diff --git a/dev-db/cockroach/files/cockroach-limits.conf b/dev-db/cockroach/files/cockroach-limits.conf
new file mode 100644
index 000000000000..2014a5d508cb
--- /dev/null
+++ b/dev-db/cockroach/files/cockroach-limits.conf
@@ -0,0 +1,4 @@
+# This is needed because cockroach can open a high number of file
+# descriptors
+cockroach soft nofile 35000
+cockroach hard nofile 35000
diff --git a/dev-db/cockroach/files/cockroach.confd b/dev-db/cockroach/files/cockroach.confd
new file mode 100644
index 000000000000..37593e217c71
--- /dev/null
+++ b/dev-db/cockroach/files/cockroach.confd
@@ -0,0 +1,14 @@
+# The default setup is for the first node of an insecure cluster that only
+# listens on localhost.
+# Please read the cockroach manual at the following url and configure
+# the start_args and stop_args correctly if you plan to use cockroach in
+# production.
+#
+# http://cockroachlabs.com/docs
+#
+# arguments to use when starting the database
+start_args="--http-host=localhost --host=localhost --insecure
+--store=/var/lib/cockroach/data"
+#
+# arguments to use when stopping the database
+stop_args="--host localhost --insecure"
diff --git a/dev-db/cockroach/files/cockroach.confd-1.0 b/dev-db/cockroach/files/cockroach.confd-1.0
new file mode 100644
index 000000000000..7874cc1cab23
--- /dev/null
+++ b/dev-db/cockroach/files/cockroach.confd-1.0
@@ -0,0 +1,45 @@
+# The default setup is for the first node of an insecure cluster that only
+# listens on localhost.
+#
+# Please read the cockroach manual at the following url and configure
+# this file correctly if you plan to use cockroach in production.
+#
+# http://cockroachlabs.com/docs
+#
+#For more information about what the arguments mean, run
+#"cockroach start --help" or "cockroach quit --help".
+#
+#These values are passed to the appropriate arguments when starting or
+#stopping the cockroach database.
+#Leaving these commented accepts the cockroach defaults with the
+#exceptions of host, http_host, insecure and log_path.
+#
+#The default for host and http_host is localhost instead of the catch-all
+#address. If you want to use the catch-all address for either of these,
+#please use
+# "all" for the setting. #
+#
+# The default for insecure is yes which passes the --insecure argument to
+# cockroach. If you want a secure connection, set insecure=no and set
+# certs_path to the location of your certificates.
+#
+#log_path defaults to /var/log/${RC_SVCNAME}.
+#
+#attrs=""
+#cache=""
+#certs_path=""
+#host=""
+#http_host=""
+#http_port=""
+#insecure=""
+#join=""
+#locality=""
+#log_path=""
+#port=""
+#store=""
+#
+# extra arguments to use when starting the database
+# start_args=""
+#
+# extra arguments to use when stopping the database
+# stop_args=""
diff --git a/dev-db/cockroach/files/cockroach.initd b/dev-db/cockroach/files/cockroach.initd
new file mode 100644
index 000000000000..3629cb6605fa
--- /dev/null
+++ b/dev-db/cockroach/files/cockroach.initd
@@ -0,0 +1,23 @@
+#!/sbin/openrc-run
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+command="/usr/bin/cockroach"
+pidfile=/run/cockroach/cockroach.pid
+command_args="start --background --log-dir=/var/log/cockroach
+ --pid-file=\"${pidfile}\" ${start_args}"
+start_stop_daemon_args="--quiet --user cockroach"
+
+depend() {
+ use net
+}
+
+start_pre() {
+ checkpath -d -m 0755 -o cockroach:cockroach $(dirname ${pidfile})
+}
+
+stop() {
+ebegin "bringing down ${RC_SVCNAME}"
+"${command}" quit ${stop_args}
+eend $?
+}
diff --git a/dev-db/cockroach/files/cockroach.initd-1.0 b/dev-db/cockroach/files/cockroach.initd-1.0
new file mode 100644
index 000000000000..b2b4f6a0884f
--- /dev/null
+++ b/dev-db/cockroach/files/cockroach.initd-1.0
@@ -0,0 +1,60 @@
+#!/sbin/openrc-run
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+command=/usr/bin/cockroach
+pidfile=/run/${RC_SVCNAME}/cockroach.pid
+start_stop_daemon_args="--quiet --user cockroach"
+[ -n "${attrs}" ] && attrs_arg="--attrs=${attrs}"
+[ -n "${cache}" ] && cache_arg="--cache=${cache}"
+[ -n "${certs_path}" ] && certs_dir_arg="--certs-dir=${certs_path}"
+[ "${host}" != all ] && host_arg="--host=${host:-localhost}"
+[ "$http_host" != all ] && http_host_arg="--http-host=${http_host:-localhost}"
+[ -n "${http_port}" ] && http_port_arg="--http-port=${http_port}"
+yesno "${insecure:-yes}" && insecure_arg="--insecure"
+[ -n "${join}" ] && join_arg="--join=${join}"
+[ -n "${locality}" ] && locality_arg="--locality=\"${locality}\""
+log_path="${log_path:-/var/log/${RC_SVCNAME}}"
+[ -n "${log_path}" ] && log_dir_arg="--log-dir=${log_path}"
+ pidfile_arg="--pid-file=${pidfile}"
+[ -n "${port}" ] && port_arg="--port=${port}"
+store_arg="--store=${store:-/var/lib/cockroach/data}"
+command_args="start --background
+ ${attrs_arg}
+ ${cache_arg}
+ ${certs_dir_arg}
+ ${host_arg}
+ ${http_host_arg}
+ ${http_port_arg}
+ ${insecure_arg}
+ ${join_arg}
+ ${locality_arg}
+ ${log_dir_arg}
+ ${pidfile_arg}
+ ${port_arg}
+ ${store_arg}
+ ${start_args}"
+quit_args="
+ ${certs_dir_arg}
+ ${host_arg}
+ ${insecure_arg}
+ ${port_arg}
+ "
+
+depend() {
+ use net
+}
+
+start_pre() {
+ if [ -n "${log_path}" ]; then
+ checkpath -d -m 0755 -o cockroach:cockroach "${log_path}" ||
+ return 1
+ fi
+ checkpath -d -m 0755 -o cockroach:cockroach "$(dirname ${pidfile})"
+}
+
+stop() {
+ebegin "bringing down ${RC_SVCNAME}"
+eval ${command} quit ${quit_args} ${stop_args}
+eend $?
+}
diff --git a/dev-db/cockroach/files/cockroach.initd-1.0.1 b/dev-db/cockroach/files/cockroach.initd-1.0.1
new file mode 100644
index 000000000000..252fc6bf7bb8
--- /dev/null
+++ b/dev-db/cockroach/files/cockroach.initd-1.0.1
@@ -0,0 +1,70 @@
+#!/sbin/openrc-run
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+command=/usr/bin/cockroach
+pidfile=/run/${RC_SVCNAME}/cockroach.pid
+start_stop_daemon_args="--quiet --user cockroach"
+[ -n "${attrs}" ] && attrs_arg="--attrs=${attrs}"
+[ -n "${cache}" ] && cache_arg="--cache=${cache}"
+[ -n "${certs_path}" ] && certs_dir_arg="--certs-dir=${certs_path}"
+[ "${host}" != all ] && host_arg="--host=${host:-localhost}"
+[ "$http_host" != all ] && http_host_arg="--http-host=${http_host:-localhost}"
+[ -n "${http_port}" ] && http_port_arg="--http-port=${http_port}"
+yesno "${insecure:-yes}" && insecure_arg="--insecure"
+[ -n "${join}" ] && join_arg="--join=${join}"
+[ -n "${locality}" ] && locality_arg="--locality=\"${locality}\""
+log_path="${log_path:-/var/log/${RC_SVCNAME}}"
+[ -n "${log_path}" ] && log_dir_arg="--log-dir=${log_path}"
+ pidfile_arg="--pid-file=${pidfile}"
+[ -n "${port}" ] && port_arg="--port=${port}"
+store_arg="--store=${store:-/var/lib/cockroach/data}"
+command_args="start --background
+ ${attrs_arg}
+ ${cache_arg}
+ ${certs_dir_arg}
+ ${host_arg}
+ ${http_host_arg}
+ ${http_port_arg}
+ ${insecure_arg}
+ ${join_arg}
+ ${locality_arg}
+ ${log_dir_arg}
+ ${pidfile_arg}
+ ${port_arg}
+ ${store_arg}
+ ${start_args}"
+quit_args="
+ ${certs_dir_arg}
+ ${host_arg}
+ ${insecure_arg}
+ ${port_arg}
+ "
+
+depend() {
+ use net
+}
+
+start_pre() {
+ if [ -n "${log_path}" ]; then
+ checkpath -d -m 0755 -o cockroach:cockroach "${log_path}" ||
+ return 1
+ fi
+ checkpath -d -m 0755 -o cockroach:cockroach "$(dirname ${pidfile})"
+}
+
+stop() {
+ebegin "bringing down ${RC_SVCNAME}"
+eval ${command} quit ${quit_args} ${stop_args}
+eend $?
+}
+
+stop_post() {
+ local cr_pid
+ read -r cr_pid < "${pidfile}"
+ while [ -d /proc/"${cr_pid}" ]; do
+ sleep 1
+ done
+ rm -f "${pidfile}"
+ return 0
+}
diff --git a/dev-db/cockroach/metadata.xml b/dev-db/cockroach/metadata.xml
new file mode 100644
index 000000000000..b02140041af5
--- /dev/null
+++ b/dev-db/cockroach/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>williamh@gentoo.org</email>
+ <name>William Hubbs</name>
+ </maintainer>
+ <longdescription lang="en">
+ CockroachDB is an open source database for building global, scalable
+ cloud services that survive disasters.
+ </longdescription>
+</pkgmetadata>