summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Trofimovich <slyfox@gentoo.org>2021-02-05 09:54:48 +0000
committerSergei Trofimovich <slyfox@gentoo.org>2021-02-05 10:13:15 +0000
commitd11f1ff4371b2e299e7ff099b1a376ddb7a7fa08 (patch)
tree20e84a4561b189de799133dbda2156fc9f2fb6d9 /dev-util/ccache
parentkde-plasma/plasma-workspace: Fix krunner regression to use cwd "~" (diff)
downloadgentoo-d11f1ff4371b2e299e7ff099b1a376ddb7a7fa08.tar.gz
gentoo-d11f1ff4371b2e299e7ff099b1a376ddb7a7fa08.tar.bz2
gentoo-d11f1ff4371b2e299e7ff099b1a376ddb7a7fa08.zip
dev-util/ccache: bump up to 4.2
Package-Manager: Portage-3.0.14, Repoman-3.0.2 Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
Diffstat (limited to 'dev-util/ccache')
-rw-r--r--dev-util/ccache/Manifest1
-rw-r--r--dev-util/ccache/ccache-4.2.ebuild71
2 files changed, 72 insertions, 0 deletions
diff --git a/dev-util/ccache/Manifest b/dev-util/ccache/Manifest
index 4437be2c6bc4..d9ff80d7e92e 100644
--- a/dev-util/ccache/Manifest
+++ b/dev-util/ccache/Manifest
@@ -1,2 +1,3 @@
DIST ccache-3.7.12.tar.xz 354684 BLAKE2B b0b1028ede8206622c4b563cdc1351bdbe49ac11aa92d405c778af91db5bac029f7331371ef0a55bc3b1c7a0b60fbc5711277e048481bf0f4ad4b1be8acd3495 SHA512 0eb47869f86d36b3e5fad0d5073973f0444f3efe23fd14469a9e05154ea219228443098b1c5e4a8a0c5c78b4bfa7623735b50ebd6b8b4d0626766061850d6a62
DIST ccache-4.1.tar.xz 389240 BLAKE2B 265ed6cd9602a04db0fadf63266d0fe1e78a74c69a27f05854a287e4048934d6afd63e71987bc525217782075c1a158601c400f3418caa0eb9730f34275bd08c SHA512 e80075eeea3fef8215de0a793e02381bfb59d7e74237fa34a49306047c60f0de0e678396ad3a9e5d86d3ad2aa21bbe29c7f0055f06b3ba2470f6895ce2eedd7b
+DIST ccache-4.2.tar.xz 422688 BLAKE2B 932db2e4f6ef9d98359fe44f931d083acb9fd32661d9baec5a2d0cfffc9301a999b04e4628d31513ec809bf43e3e94d71f9b92a1c83bcebbaf5e35e219596704 SHA512 b7e5823a0705b9a1100c959281170dcd682228b585c329821337ef57d5b5cf47d6f3d644a6d5a3675a32a02730559f8fe6d84d11f01847f47b77c0893d1d1fbe
diff --git a/dev-util/ccache/ccache-4.2.ebuild b/dev-util/ccache/ccache-4.2.ebuild
new file mode 100644
index 000000000000..6988793a4790
--- /dev/null
+++ b/dev-util/ccache/ccache-4.2.ebuild
@@ -0,0 +1,71 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake toolchain-funcs
+
+DESCRIPTION="fast compiler cache"
+HOMEPAGE="https://ccache.dev/"
+SRC_URI="https://github.com/ccache/ccache/releases/download/v${PV}/ccache-${PV}.tar.xz"
+
+LICENSE="GPL-3 LGPL-3"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+IUSE="test"
+
+DEPEND=""
+RDEPEND="${DEPEND}
+ app-arch/zstd:0=
+ dev-util/shadowman
+ sys-apps/gentoo-functions
+"
+# clang-specific tests use dev-libs/elfutils to compare objects for equality.
+# Let's pull in the dependency unconditionally.
+DEPEND+="
+ test? ( dev-libs/elfutils )
+"
+BDEPEND="
+ app-text/asciidoc
+"
+
+RESTRICT="!test? ( test )"
+
+DOCS=( doc/{AUTHORS,MANUAL,NEWS}.adoc CONTRIBUTING.md README.md )
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-3.5-nvcc-test.patch
+ "${FILESDIR}"/${PN}-4.0-objdump.patch
+ "${FILESDIR}"/${PN}-4.1-avoid-run-user.patch
+)
+
+src_prepare() {
+ cmake_src_prepare
+
+ sed \
+ -e "/^EPREFIX=/s:'':'${EPREFIX}':" \
+ "${FILESDIR}"/ccache-config-3 > ccache-config || die
+
+ # mainly used in tests
+ tc-export CC OBJDUMP
+}
+
+src_install() {
+ cmake_src_install
+
+ dobin ccache-config
+ insinto /usr/share/shadowman/tools
+ newins - ccache <<<"${EPREFIX}/usr/lib/ccache/bin"
+}
+
+pkg_prerm() {
+ if [[ -z ${REPLACED_BY_VERSION} && ${ROOT:-/} == / ]] ; then
+ eselect compiler-shadow remove ccache
+ fi
+}
+
+pkg_postinst() {
+ if [[ ${ROOT:-/} == / ]]; then
+ eselect compiler-shadow update ccache
+ fi
+}