Gentoo Archives: gentoo-commits

From: Hans de Graaff <graaff@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ruby/nokogiri/
Date: Mon, 12 Aug 2019 07:02:48
Message-Id: 1565593355.caf197d03fb9a2e355844d12defdfa60db61ccc7.graaff@gentoo
1 commit: caf197d03fb9a2e355844d12defdfa60db61ccc7
2 Author: Hans de Graaff <graaff <AT> gentoo <DOT> org>
3 AuthorDate: Mon Aug 12 07:02:20 2019 +0000
4 Commit: Hans de Graaff <graaff <AT> gentoo <DOT> org>
5 CommitDate: Mon Aug 12 07:02:35 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=caf197d0
7
8 dev-ruby/nokogiri: add 1.10.4
9
10 Bug: https://bugs.gentoo.org/691974
11 Package-Manager: Portage-2.3.69, Repoman-2.3.16
12 Signed-off-by: Hans de Graaff <graaff <AT> gentoo.org>
13
14 dev-ruby/nokogiri/Manifest | 1 +
15 dev-ruby/nokogiri/nokogiri-1.10.4.ebuild | 91 ++++++++++++++++++++++++++++++++
16 2 files changed, 92 insertions(+)
17
18 diff --git a/dev-ruby/nokogiri/Manifest b/dev-ruby/nokogiri/Manifest
19 index 4452e37ab97..369fa6def7f 100644
20 --- a/dev-ruby/nokogiri/Manifest
21 +++ b/dev-ruby/nokogiri/Manifest
22 @@ -1,3 +1,4 @@
23 DIST nokogiri-1.10.3-git.tgz 5792280 BLAKE2B e902a773d925bff9414e2aa5c561b2e315144f9ee56f6186a0585a390af8db52725a960c747acd71e174d896d60d555568bd85a314735de72c75b74f76a40c30 SHA512 88c408cb25cc7e4fff9cf74ec8d3a15aeaeef8754c1172fb2cb4c0cb8b8b7419a47e6a2ec54ff9b1faa2bfdf0b287f05d429d8dfc9d2054125c488ca234b80cc
24 +DIST nokogiri-1.10.4-git.tgz 5792963 BLAKE2B 80223c7bda39c56ced8e98d1d9f6858907f2814eb2d9f28d13c9f26fe29ae7f057e5a19765a3b304ffc4f9edd3dd0f77b99d5a673923ce95a8f02135aa9882ca SHA512 c27877297d432b9a9baf3e0639600d6ca5b382a87ff0dc1efb5d9bb3c79aaa31a589a4491f938283e4f9d35e8d29b6f88a60e27a5d4c81e7b491e100f8d06a9d
25 DIST nokogiri-1.8.4-git.tgz 5754921 BLAKE2B 189dc8ffe4df67b04fa8436799bd6d64e4f8c1f93206b619bda8e153afffb3091fdfab9a3a4da28fcaa2650711aad6e37232e4e948a74c217f7fdc8b061dd4cd SHA512 ed409daeb4e13f93e13bc6901ee27bf5d1155e24fb306b5b9e8ba462517d26d4514413b9728d4a8f2514015c54436b9689a11449030c7bb5826d2ca7bf7eb97a
26 DIST nokogiri-1.9.1-git.tgz 5784212 BLAKE2B 9055a954a52deb10e2a937267d7b382dd235885a44afe126c2770b415d4f6c26b851396a2f03898c335987eba7baf8b5aa1f5fb8ae1063b64c0a620b9ce7969e SHA512 8d0dc667c68b612ba481692a02cf32860f9cb180a831942789c56568e3b4c1bc89a21ac284cd4d406b183600c6aaf56cf7a3a104594bdbba22fa53f9af6525da
27
28 diff --git a/dev-ruby/nokogiri/nokogiri-1.10.4.ebuild b/dev-ruby/nokogiri/nokogiri-1.10.4.ebuild
29 new file mode 100644
30 index 00000000000..b6ce5a3ce93
31 --- /dev/null
32 +++ b/dev-ruby/nokogiri/nokogiri-1.10.4.ebuild
33 @@ -0,0 +1,91 @@
34 +# Copyright 1999-2019 Gentoo Authors
35 +# Distributed under the terms of the GNU General Public License v2
36 +
37 +EAPI=7
38 +
39 +USE_RUBY="ruby24 ruby25 ruby26"
40 +
41 +RUBY_FAKEGEM_EXTRADOC="CHANGELOG.md README.md ROADMAP.md STANDARD_RESPONSES.md"
42 +
43 +RUBY_FAKEGEM_EXTRAINSTALL="ext"
44 +
45 +inherit ruby-fakegem eutils multilib
46 +
47 +DESCRIPTION="Nokogiri is an HTML, XML, SAX, and Reader parser"
48 +HOMEPAGE="https://www.nokogiri.org/"
49 +LICENSE="MIT"
50 +SRC_URI="https://github.com/sparklemotion/nokogiri/archive/v${PV}.tar.gz -> ${P}-git.tgz"
51 +
52 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
53 +SLOT="0"
54 +IUSE=""
55 +
56 +RDEPEND="${RDEPEND}
57 + >=dev-libs/libxml2-2.9.9:=
58 + >=dev-libs/libxslt-1.1.33
59 + virtual/libiconv"
60 +DEPEND="${DEPEND}
61 + >=dev-libs/libxml2-2.9.9
62 + >=dev-libs/libxslt-1.1.33
63 + virtual/libiconv"
64 +
65 +ruby_add_bdepend "
66 + >=dev-ruby/pkg-config-1.1.7
67 + >=dev-ruby/rexical-1.0.7
68 + dev-ruby/rdoc
69 + dev-ruby/racc
70 + test? ( dev-ruby/minitest )"
71 +
72 +all_ruby_prepare() {
73 + sed -i \
74 + -e '/tasks\/cross_compile/s:^:#:' \
75 + -e '/:test.*prerequisites/s:^:#:' \
76 + -e '/license/ s:^:#:' \
77 + Rakefile || die
78 + # Remove the cross compilation options since they interfere with
79 + # native building.
80 + sed -i -e 's/cross_compile = true/cross_compile = false/' Rakefile || die
81 + sed -i -e '/cross_config_options/d' Rakefile || die
82 +}
83 +
84 +each_ruby_configure() {
85 + NOKOGIRI_USE_SYSTEM_LIBRARIES=true \
86 + ${RUBY} -Cext/${PN} extconf.rb \
87 + --with-zlib-include="${EPREFIX}"/usr/include \
88 + --with-zlib-lib="${EPREFIX}"/$(get_libdir) \
89 + --with-iconv-include="${EPREFIX}"/usr/include \
90 + --with-iconv-lib="${EPREFIX}"/$(get_libdir) \
91 + --with-xml2-include="${EPREFIX}"/usr/include/libxml2 \
92 + --with-xml2-lib="${EPREFIX}"/usr/$(get_libdir) \
93 + --with-xslt-dir="${EPREFIX}"/usr \
94 + --with-iconvlib=iconv \
95 + || die "extconf.rb failed"
96 +}
97 +
98 +each_ruby_compile() {
99 + if ! [[ -f lib/nokogiri/css/tokenizer.rb ]]; then
100 + ${RUBY} -S rake lib/nokogiri/css/tokenizer.rb || die "rexical failed"
101 + fi
102 +
103 + if ! [[ -f lib/nokogiri/css/parser.rb ]]; then
104 + ${RUBY} -S rake lib/nokogiri/css/parser.rb || die "racc failed"
105 + fi
106 +
107 + emake -Cext/${PN} \
108 + V=1 \
109 + CFLAGS="${CFLAGS} -fPIC" \
110 + archflag="${LDFLAGS}" || die "make extension failed"
111 + cp -l ext/${PN}/${PN}$(get_modname) lib/${PN}/ || die
112 +}
113 +
114 +each_ruby_test() {
115 + ${RUBY} -Ilib:.:test -e 'Dir["test/**/test_*.rb"].each {|f| require f}' || die
116 +}
117 +
118 +each_ruby_install() {
119 + # Clean up "ext" directory before installing it. nokogumbo expects
120 + # the header files and shared object to be in ext.
121 + rm -rf ext/java ext/nokogiri/*.o ext/nokogiri/{mkmf.log,Makefile} || die
122 +
123 + each_fakegem_install
124 +}