commit: fd9a7fbe223e7614ea727f1c44fe03220a4d7297 Author: Hans de Graaff <graaff <AT> gentoo <DOT> org> AuthorDate: Sat Sep 9 07:08:21 2023 +0000 Commit: Hans de Graaff <graaff <AT> gentoo <DOT> org> CommitDate: Sat Sep 9 07:10:35 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fd9a7fbe
dev-ruby/puppet_forge: fix typhoeus detection Signed-off-by: Hans de Graaff <graaff <AT> gentoo.org> .../puppet_forge/files/puppet_forge-5.0.1-typhoeus.patch | 14 ++++++++++++++ ...pet_forge-5.0.1.ebuild => puppet_forge-5.0.1-r1.ebuild} | 5 ++--- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/dev-ruby/puppet_forge/files/puppet_forge-5.0.1-typhoeus.patch b/dev-ruby/puppet_forge/files/puppet_forge-5.0.1-typhoeus.patch new file mode 100644 index 000000000000..3f39e97afe8c --- /dev/null +++ b/dev-ruby/puppet_forge/files/puppet_forge-5.0.1-typhoeus.patch @@ -0,0 +1,14 @@ +Typhoeus support only works then the faraday-typhoeus package is installed. +https://github.com/typhoeus/typhoeus/issues/709 + +--- a/lib/puppet_forge/connection.rb 2023-09-09 09:02:03.981164238 +0200 ++++ b/lib/puppet_forge/connection.rb 2023-09-09 09:03:56.506144279 +0200 +@@ -82,7 +82,7 @@ + + begin + # Use Typhoeus if available. +- Gem::Specification.find_by_name('typhoeus', '~> 1.4') ++ Gem::Specification.find_by_name('typhoeus', '~> 1.4') && Gem::Specification.find_by_name('faraday-typhoeus') + require 'typhoeus/adapters/faraday' + adapter = :typhoeus + rescue Gem::LoadError diff --git a/dev-ruby/puppet_forge/puppet_forge-5.0.1.ebuild b/dev-ruby/puppet_forge/puppet_forge-5.0.1-r1.ebuild similarity index 85% rename from dev-ruby/puppet_forge/puppet_forge-5.0.1.ebuild rename to dev-ruby/puppet_forge/puppet_forge-5.0.1-r1.ebuild index 7a6accc8642f..dc80c18aca40 100644 --- a/dev-ruby/puppet_forge/puppet_forge-5.0.1.ebuild +++ b/dev-ruby/puppet_forge/puppet_forge-5.0.1-r1.ebuild @@ -20,6 +20,8 @@ SLOT="$(ver_cut 1)" KEYWORDS="~amd64" IUSE="" +PATCHES=( "${FILESDIR}/${P}-typhoeus.patch" ) + ruby_add_rdepend " dev-ruby/faraday:2 >=dev-ruby/faraday-follow_redirects-0.3.0:0.3 @@ -32,7 +34,4 @@ all_ruby_prepare() { rm -rf spec/integration spec/unit/forge/v3/user_spec.rb || die sed -i -e 's/git ls-files -z/find * -print0/' ${RUBY_FAKEGEM_GEMSPEC} || die - - # Avoid specs that are broken when typhoeus is installed - rm -f spec/unit/forge/connection_spec.rb spec/unit/forge/v3/{base,release}_spec.rb || die }
