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.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 67DAE158243 for ; Sun, 24 Nov 2024 22:47:38 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E5F9EE09C7 for ; Sun, 24 Nov 2024 22:47:33 +0000 (UTC) Received: from out0.migadu.com (out0.migadu.com [94.23.1.103]) (using TLSv1.2 with cipher ECDHE-RSA-CHACHA20-POLY1305 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id E061FE0CEA for ; Wed, 6 Jul 2022 12:22:00 +0000 (UTC) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=r0bert.dev; s=key1; t=1657110119; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=9Y7VWOai/MLcnNH5sjTqzO8ybh8fXso+wag0BWjed80=; b=b9C2zbK0P3zQ356aLOSy8F4WewPdywn1JtMv3PRvk0e4lWhQbRSEeKKaD9IBT0UhaoibQW U2X7TeQQoc2KjmW1NNCqdJie+FEqHYRkZ7Q/veNHQLydlVIKUWzuFk7WETIA/GjEhuKWs2 49cYTJrDHv/5wjuczjWfKEl65gJ7qj6wiyeKEC1+yDUe5f1EPk59Ssmm6aIWKpOBT/YBLW H5JcmeEo13HapZCfxxLmzFqk39Fiw2YIi986TwCuLBSVx1OI9/RlxDu7AksJPt1Nm1oCq5 SLQRo/b1zPxLGvF9SUlcLJ/k2uOkoRXIP9lbWny635VIvySSnRpF4+gvffwuIA== From: Robert Greener To: gentoo-guru@lists.gentoo.org Cc: Robert Greener , cyber@sysrq.in, lssndrbarbieri@gmail.com Subject: [gentoo-guru] [RFC PATCH v2 3/4] eclass/R-packages: Add CRAN_UPD_DATE and use MRAN. Date: Wed, 6 Jul 2022 13:21:41 +0100 Message-Id: <20220706122142.125975-4-me@r0bert.dev> In-Reply-To: <20220706122142.125975-1-me@r0bert.dev> References: <20220705071539.2463760-1-me@r0bert.dev> <20220706122142.125975-1-me@r0bert.dev> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Discussion on the GURU project and repository X-BeenThere: gentoo-guru@gentoo.org X-BeenThere: gentoo-guru@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: r0bert.dev X-Archives-Salt: d05d2c84-32c3-4351-9e6c-60c7ea5e9f3b X-Archives-Hash: bf6940046aa92ce438999ee42717b043 The current SRC_URI searches all the CRAN mirrors for /src/contrib/${PN}_${PV}.tar.gz. This is problematic. Once a package is updated on CRAN, the package is removed from this path and moved to /src/contrib/Archive/${PN}/${PN}_${PV}.tar.gz. The effect of this is that once a package goes out-of-date on CRAN, the ebuild will no longer build. This significantly increases the maintenance burden of dev-R/* packages, as it requires that they be up-to-date at all times. The proposal here, is to use the snapshots of CRAN provided by Microsoft. This requires an additional variable set in the ebuilds, the update date. This can just be set to the date that the ebuild is updated. By setting this, out of date packages will continue to build. Signed-off-by: Robert Greener --- eclass/R-packages.eclass | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/eclass/R-packages.eclass b/eclass/R-packages.eclass index 1665203d1..74f175540 100644 --- a/eclass/R-packages.eclass +++ b/eclass/R-packages.eclass @@ -24,7 +24,15 @@ EXPORT_FUNCTIONS src_unpack src_prepare src_configure src_compile src_install pk CRAN_PV=${CRAN_PV:-$PV} CRAN_PN=${CRAN_PN:-${PN//_/.}} -SRC_URI="mirror://cran/src/contrib/${CRAN_PN}_${CRAN_PV}.tar.gz" +# Set CRAN_UPD_DATE to the date the ebuild was updated in the ebuild + +if [[ ${CRAN_UPD_DATE} ]]; then + SRC_URI="https://cran.microsoft.com/snapshot/${CRAN_UPD_DATE}" +else + SRC_URI="mirror://cran" +fi +SRC_URI+="/src/contrib/${CRAN_PN}_${CRAN_PV}.tar.gz" + HOMEPAGE="https://cran.r-project.org/package=${CRAN_PN}" SLOT="0" -- 2.35.1