From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id CEA05138334 for ; Sun, 29 Jul 2018 01:43:24 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 70B51E0871; Sun, 29 Jul 2018 01:43:22 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 285FCE0871 for ; Sun, 29 Jul 2018 01:43:22 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id B8668335CA6 for ; Sun, 29 Jul 2018 01:43:18 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 2166B373 for ; Sun, 29 Jul 2018 01:43:16 +0000 (UTC) From: "Andrey Utkin" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andrey Utkin" Message-ID: <1532828449.87056724896f44e4d1843e0e8d17806bdecf11a5.andrey_utkin@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-util/tup/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-util/tup/Manifest dev-util/tup/metadata.xml dev-util/tup/tup-0.7.7.ebuild dev-util/tup/tup-9999.ebuild X-VCS-Directories: dev-util/tup/ X-VCS-Committer: andrey_utkin X-VCS-Committer-Name: Andrey Utkin X-VCS-Revision: 87056724896f44e4d1843e0e8d17806bdecf11a5 X-VCS-Branch: master Date: Sun, 29 Jul 2018 01:43:16 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 339477d4-326b-4ed9-afad-74c42e08443e X-Archives-Hash: 6c08b68507fdfc90930c3e35454a8833 commit: 87056724896f44e4d1843e0e8d17806bdecf11a5 Author: Andrey Utkin gentoo org> AuthorDate: Sat Jul 28 00:09:12 2018 +0000 Commit: Andrey Utkin gentoo org> CommitDate: Sun Jul 29 01:40:49 2018 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=87056724 dev-util/tup: add new package Based on work by Cody P Schafer codyps.com> (jmesmon overlay). Package-Manager: Portage-2.3.40, Repoman-2.3.9 dev-util/tup/Manifest | 1 + dev-util/tup/metadata.xml | 11 +++++ dev-util/tup/tup-0.7.7.ebuild | 98 +++++++++++++++++++++++++++++++++++++++++++ dev-util/tup/tup-9999.ebuild | 98 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 208 insertions(+) diff --git a/dev-util/tup/Manifest b/dev-util/tup/Manifest new file mode 100644 index 00000000000..d9c8a9d735d --- /dev/null +++ b/dev-util/tup/Manifest @@ -0,0 +1 @@ +DIST tup-0.7.7.tar.gz 4033539 BLAKE2B dc4d3fc538c76dac53629991e32de7414f35877af8bb9f2ce4a1f80252317de7b3d2ea1542ab3e58702813b297a42c95610d14122496ac7f23acc1f8f3d62461 SHA512 05407cc923b898d5dcf6652df6395e7618d43fa4e3ace905dda09bcda26f975187761a704d360fceeb38332f29d65cd3d1f9e04c87d93dcffa4e9e2be9b35aad diff --git a/dev-util/tup/metadata.xml b/dev-util/tup/metadata.xml new file mode 100644 index 00000000000..390ab1cc501 --- /dev/null +++ b/dev-util/tup/metadata.xml @@ -0,0 +1,11 @@ + + + + + andrey_utkin@gentoo.org + Andrey Utkin + + + gittup/tup + + diff --git a/dev-util/tup/tup-0.7.7.ebuild b/dev-util/tup/tup-0.7.7.ebuild new file mode 100644 index 00000000000..104dd83a9db --- /dev/null +++ b/dev-util/tup/tup-0.7.7.ebuild @@ -0,0 +1,98 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit toolchain-funcs + +DESCRIPTION="A file-based build system" +HOMEPAGE="http://gittup.org/tup" +# Tup itself is GPLv2, but it bundles differently licensed software: +# - lua: MIT +# - sqlite (unused in this ebuild): public domain +# - inih: 3-clause BSD +# - red-black tree implementation: 2-clause BSD +# - queue implementation: 3-clause BSD +LICENSE="GPL-2 MIT public-domain BSD BSD-2" +SLOT="0" + +if [[ "${PV}" == 9999 ]]; then + EGIT_REPO_URI="https://github.com/gittup/tup.git" + inherit git-r3 +else + SRC_URI="https://github.com/gittup/tup/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi + +DEPEND=" + dev-db/sqlite:= + sys-fs/fuse:= +" +RDEPEND="${DEPEND}" + +src_prepare() { + # Use our toolchain + sed -i Tuprules.tup \ + -e "s:CC = gcc:CC = $(tc-getCC) ${CFLAGS} ${LDFLAGS}:" \ + -e "s:ar crs:$(tc-getAR) crs:" + + if [[ ${PV} != 9999 ]]; then + # Avoid invoking `git` to find version, use ours + sed -i src/tup/link.sh \ + -e 's;`git describe`;v'"${PV};" + fi + + default +} + +src_configure () { + echo "CONFIG_TUP_USE_SYSTEM_SQLITE=y" >> tup.config +} + +src_compile() { + # Disabling namespacing because it leads to accessing /proc//setgroups + # which violates sandboxing. + export TUP_NO_NAMESPACING=1 + ./bootstrap-nofuse.sh || die + unset TUP_NO_NAMESPACING +} + +src_install() { + dobin tup + dolib.a libtup_client.a + doheader tup_client.h + doman tup.1 +} + +src_test() { + # tup uses fuse when tracking dependencies. + addwrite /dev/fuse + + # Disabling namespacing because it leads to accessing /proc//setgroups + # which violates sandboxing. + export TUP_NO_NAMESPACING=1 + + # Skip tests which require namespacing or root privileges. + SKIPPED_TESTS=( + t4062-full-deps.sh + t4063-full-deps2.sh + t4064-full-deps3.sh + t4065-full-deps-proc.sh + t4067-full-deps5.sh + t4069-gcc-coverage.sh + t4072-proc-self.sh + t4074-getpwd.sh + t4131-proc-self-exe.sh + t4132-proc-meminfo.sh + t4171-dev-null.sh + t5083-symlink-fullpath.sh + t5084-symlink-fullpath2.sh + t7048-full-deps.sh + ) + pushd test || die + rm ${SKIPPED_TESTS[@]} || die + ./test.sh || die + popd || die + + unset TUP_NO_NAMESPACING +} diff --git a/dev-util/tup/tup-9999.ebuild b/dev-util/tup/tup-9999.ebuild new file mode 100644 index 00000000000..104dd83a9db --- /dev/null +++ b/dev-util/tup/tup-9999.ebuild @@ -0,0 +1,98 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit toolchain-funcs + +DESCRIPTION="A file-based build system" +HOMEPAGE="http://gittup.org/tup" +# Tup itself is GPLv2, but it bundles differently licensed software: +# - lua: MIT +# - sqlite (unused in this ebuild): public domain +# - inih: 3-clause BSD +# - red-black tree implementation: 2-clause BSD +# - queue implementation: 3-clause BSD +LICENSE="GPL-2 MIT public-domain BSD BSD-2" +SLOT="0" + +if [[ "${PV}" == 9999 ]]; then + EGIT_REPO_URI="https://github.com/gittup/tup.git" + inherit git-r3 +else + SRC_URI="https://github.com/gittup/tup/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi + +DEPEND=" + dev-db/sqlite:= + sys-fs/fuse:= +" +RDEPEND="${DEPEND}" + +src_prepare() { + # Use our toolchain + sed -i Tuprules.tup \ + -e "s:CC = gcc:CC = $(tc-getCC) ${CFLAGS} ${LDFLAGS}:" \ + -e "s:ar crs:$(tc-getAR) crs:" + + if [[ ${PV} != 9999 ]]; then + # Avoid invoking `git` to find version, use ours + sed -i src/tup/link.sh \ + -e 's;`git describe`;v'"${PV};" + fi + + default +} + +src_configure () { + echo "CONFIG_TUP_USE_SYSTEM_SQLITE=y" >> tup.config +} + +src_compile() { + # Disabling namespacing because it leads to accessing /proc//setgroups + # which violates sandboxing. + export TUP_NO_NAMESPACING=1 + ./bootstrap-nofuse.sh || die + unset TUP_NO_NAMESPACING +} + +src_install() { + dobin tup + dolib.a libtup_client.a + doheader tup_client.h + doman tup.1 +} + +src_test() { + # tup uses fuse when tracking dependencies. + addwrite /dev/fuse + + # Disabling namespacing because it leads to accessing /proc//setgroups + # which violates sandboxing. + export TUP_NO_NAMESPACING=1 + + # Skip tests which require namespacing or root privileges. + SKIPPED_TESTS=( + t4062-full-deps.sh + t4063-full-deps2.sh + t4064-full-deps3.sh + t4065-full-deps-proc.sh + t4067-full-deps5.sh + t4069-gcc-coverage.sh + t4072-proc-self.sh + t4074-getpwd.sh + t4131-proc-self-exe.sh + t4132-proc-meminfo.sh + t4171-dev-null.sh + t5083-symlink-fullpath.sh + t5084-symlink-fullpath2.sh + t7048-full-deps.sh + ) + pushd test || die + rm ${SKIPPED_TESTS[@]} || die + ./test.sh || die + popd || die + + unset TUP_NO_NAMESPACING +}