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 C004F139345 for ; Wed, 30 Jun 2021 06:56:50 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A2F9BE083E; Wed, 30 Jun 2021 06:56:49 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (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 89F6DE083E for ; Wed, 30 Jun 2021 06:56:49 +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 AA043335DC6 for ; Wed, 30 Jun 2021 06:56:48 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id C8DA67C5 for ; Wed, 30 Jun 2021 06:56:45 +0000 (UTC) From: "Hans de Graaff" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Hans de Graaff" Message-ID: <1625036188.6af21437ec5607e3ebc61f7a7d9c473973f6b6dd.graaff@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ruby/hpricot/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-ruby/hpricot/hpricot-0.8.6-r6.ebuild X-VCS-Directories: dev-ruby/hpricot/ X-VCS-Committer: graaff X-VCS-Committer-Name: Hans de Graaff X-VCS-Revision: 6af21437ec5607e3ebc61f7a7d9c473973f6b6dd X-VCS-Branch: master Date: Wed, 30 Jun 2021 06:56:45 +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: 55a027f6-835e-463c-8dd1-31d6cccd7110 X-Archives-Hash: 8c5f9711f8a8a726ccc11179e5da35f9 commit: 6af21437ec5607e3ebc61f7a7d9c473973f6b6dd Author: Hans de Graaff gentoo org> AuthorDate: Sun Jun 27 08:18:26 2021 +0000 Commit: Hans de Graaff gentoo org> CommitDate: Wed Jun 30 06:56:28 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6af21437 dev-ruby/hpricot: fix extension install; ruby30 Package-Manager: Portage-3.0.20, Repoman-3.0.2 Signed-off-by: Hans de Graaff gentoo.org> dev-ruby/hpricot/hpricot-0.8.6-r6.ebuild | 57 ++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/dev-ruby/hpricot/hpricot-0.8.6-r6.ebuild b/dev-ruby/hpricot/hpricot-0.8.6-r6.ebuild new file mode 100644 index 00000000000..4af8d4a90b3 --- /dev/null +++ b/dev-ruby/hpricot/hpricot-0.8.6-r6.ebuild @@ -0,0 +1,57 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +USE_RUBY="ruby25 ruby26 ruby27 ruby30" + +RUBY_FAKEGEM_DOCDIR="doc" +RUBY_FAKEGEM_EXTRADOC="CHANGELOG README.md" + +RUBY_FAKEGEM_EXTENSIONS=(ext/hpricot_scan/extconf.rb) + +inherit ruby-fakegem + +DESCRIPTION="A fast and liberal HTML parser for Ruby" +HOMEPAGE="https://wiki.github.com/hpricot/hpricot" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris ~x86-solaris" +IUSE="" + +ruby_add_bdepend "dev-ruby/rake + dev-ruby/rdoc + dev-ruby/rake-compiler" + +ruby_add_rdepend "dev-ruby/fast_xs" + +# Probably needs the same jdk as JRuby but I'm not sure how to express +# that just yet. +DEPEND+=" dev-util/ragel" + +all_ruby_prepare() { + sed -i -e '/[Bb]undler/ s:^:#:' Rakefile || die + + # Fix encoding assumption of environment for Ruby 1.9. + # https://github.com/hpricot/hpricot/issues/52 + # sed -i -e '1 iEncoding.default_external=Encoding::UTF_8 if RUBY_VERSION =~ /1.9/' test/load_files.rb || die + + # Avoid unneeded dependency on git. + sed -i -e '/^REV/ s/.*/REV = "6"/' Rakefile || die + + # Fix int size warning + sed -i -e 's/te - ts/(int)(te - ts)/' ext/hpricot_scan/hpricot_css.rl || die +} + +each_ruby_prepare() { + pushd .. &>/dev/null + eapply "${FILESDIR}"/${P}-fast_xs.patch + popd .. &>/dev/null +} + +each_ruby_compile() { + ${RUBY} -S rake ragel || die + + each_fakegem_compile +}