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 (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 5C91E15807A for ; Tue, 8 Oct 2024 15:32:08 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 0324DE29EA; Tue, 8 Oct 2024 15:32:07 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (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 pigeon.gentoo.org (Postfix) with ESMTPS id E19F8E29EA for ; Tue, 8 Oct 2024 15:32:06 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 2B62D3431BA for ; Tue, 8 Oct 2024 15:32:06 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 784E02195 for ; Tue, 8 Oct 2024 15:32:04 +0000 (UTC) From: "David Seifert" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "David Seifert" Message-ID: <1728401491.52f627a5cd18b6dec318d672438b291ebddf94b9.soap@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: eclass/ X-VCS-Repository: repo/gentoo X-VCS-Files: eclass/ruby-fakegem.eclass X-VCS-Directories: eclass/ X-VCS-Committer: soap X-VCS-Committer-Name: David Seifert X-VCS-Revision: 52f627a5cd18b6dec318d672438b291ebddf94b9 X-VCS-Branch: master Date: Tue, 8 Oct 2024 15:32:04 +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-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 9cb8f177-026f-47df-95a0-0d94bc4b8f2c X-Archives-Hash: 876bed1d209cda7ff82f2eb7a67427ee commit: 52f627a5cd18b6dec318d672438b291ebddf94b9 Author: David Seifert gentoo org> AuthorDate: Tue Oct 8 15:31:31 2024 +0000 Commit: David Seifert gentoo org> CommitDate: Tue Oct 8 15:31:31 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=52f627a5 ruby-fakegem.eclass: drop support for EAPI 5 and 6 Signed-off-by: David Seifert gentoo.org> eclass/ruby-fakegem.eclass | 57 ++++++++++++++++------------------------------ 1 file changed, 20 insertions(+), 37 deletions(-) diff --git a/eclass/ruby-fakegem.eclass b/eclass/ruby-fakegem.eclass index 04099a82ef4f..207ba42b9544 100644 --- a/eclass/ruby-fakegem.eclass +++ b/eclass/ruby-fakegem.eclass @@ -8,13 +8,21 @@ # Author: Diego E. Pettenò # Author: Alex Legler # Author: Hans de Graaff -# @SUPPORTED_EAPIS: 5 6 7 8 +# @SUPPORTED_EAPIS: 7 8 # @PROVIDES: ruby-ng # @BLURB: An eclass for installing Ruby packages to behave like RubyGems. # @DESCRIPTION: # This eclass allows to install arbitrary Ruby libraries (including Gems), # providing integration into the RubyGems system even for "regular" packages. +if [[ -z ${_RUBY_FAKEGEM_ECLASS} ]]; then +_RUBY_FAKEGEM_ECLASS=1 + +case ${EAPI} in + 7|8) ;; + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; +esac + inherit ruby-ng # @ECLASS_VARIABLE: RUBY_FAKEGEM_NAME @@ -61,14 +69,7 @@ RUBY_FAKEGEM_TASK_TEST="${RUBY_FAKEGEM_TASK_TEST-test}" # - rdoc (calls `rdoc-2`, adds dev-ruby/rdoc to the dependencies); # - yard (calls `yard`, adds dev-ruby/yard to the dependencies); # - none -case ${EAPI} in - 5|6) - RUBY_FAKEGEM_RECIPE_DOC="${RUBY_FAKEGEM_RECIPE_DOC-rake}" - ;; - *) - RUBY_FAKEGEM_RECIPE_DOC="${RUBY_FAKEGEM_RECIPE_DOC-rdoc}" - ;; -esac +: "${RUBY_FAKEGEM_RECIPE_DOC=rdoc}" # @ECLASS_VARIABLE: RUBY_FAKEGEM_DOCDIR # @DEFAULT_UNSET @@ -138,15 +139,6 @@ RUBY_FAKEGEM_BINDIR="${RUBY_FAKEGEM_BINDIR-bin}" # legacy way to install extensions for a long time. RUBY_FAKEGEM_EXTENSION_LIBDIR="${RUBY_FAKEGEM_EXTENSION_LIBDIR-lib}" -case ${EAPI} in - 6) - ewarn "${CATEGORY}/${PF}: ebuild uses ${ECLASS} with deprecated EAPI ${EAPI}!" - ewarn "${CATEGORY}/${PF}: Support will be removed on 2024-10-08. Please port to newer EAPI." - ;; - 7|8) ;; - *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; -esac - RUBY_FAKEGEM_SUFFIX="${RUBY_FAKEGEM_SUFFIX:-}" @@ -215,13 +207,7 @@ SRC_URI="https://rubygems.org/gems/${RUBY_FAKEGEM_NAME}-${RUBY_FAKEGEM_VERSION}$ ruby_add_bdepend "virtual/rubygems" ruby_add_rdepend virtual/rubygems -case ${EAPI} in - 5|6) - ;; - *) - ruby_add_depend virtual/rubygems - ;; -esac +ruby_add_depend virtual/rubygems # Many (but not all) extensions use pkgconfig in src_configure. if [[ ${#RUBY_FAKEGEM_EXTENSIONS[@]} -gt 0 ]]; then @@ -258,7 +244,7 @@ ruby_fakegem_doins() { ( insinto $(ruby_fakegem_gemsdir)/gems/${RUBY_FAKEGEM_NAME}-${RUBY_FAKEGEM_VERSION} doins "$@" - ) || die "failed $0 $@" + ) } # @FUNCTION: ruby_fakegem_newins @@ -278,7 +264,7 @@ ruby_fakegem_newins() { insinto $(ruby_fakegem_gemsdir)/gems/${RUBY_FAKEGEM_NAME}-${RUBY_FAKEGEM_VERSION}${newdirname} newins "$1" ${newbasename} - ) || die "failed $0 $@" + ) } # @FUNCTION: ruby_fakegem_install_gemspec @@ -303,7 +289,7 @@ ruby_fakegem_install_gemspec() { ruby_fakegem_genspec ${gemspec} fi fi - ) || die "Unable to generate gemspec file." + ) insinto $(ruby_fakegem_gemsdir)/specifications newins ${gemspec} ${RUBY_FAKEGEM_NAME}-${RUBY_FAKEGEM_VERSION}.gemspec || die "Unable to install gemspec file." @@ -349,14 +335,9 @@ ruby_fakegem_metadata_gemspec() { ruby_fakegem_genspec() { debug-print-function ${FUNCNAME} "${@}" - case ${EAPI} in - 5|6) ;; - *) - eqawarn "Generating generic fallback gemspec *without* dependencies" - eqawarn "This will only work when there are no runtime dependencies" - eqawarn "Set RUBY_FAKEGEM_GEMSPEC to generate a proper specifications file" - ;; - esac + eqawarn "Generating generic fallback gemspec *without* dependencies" + eqawarn "This will only work when there are no runtime dependencies" + eqawarn "Set RUBY_FAKEGEM_GEMSPEC to generate a proper specifications file" local required_paths="'lib'" for path in ${RUBY_FAKEGEM_REQUIRE_PATHS}; do @@ -434,7 +415,7 @@ EOF exeinto ${binpath:-/usr/bin} newexe "${T}"/gembin-wrapper-${gembinary} $(basename $newbinary) - ) || die "Unable to create fakegem wrapper" + ) } # @FUNCTION: each_fakegem_configure @@ -701,3 +682,5 @@ all_ruby_install() { all_fakegem_install } + +fi