1 |
commit: e2eabca0c1c53268bd576ab6ea2d3c6ad05cb2fc |
2 |
Author: Hans de Graaff <graaff <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Jul 1 05:40:31 2020 +0000 |
4 |
Commit: Hans de Graaff <graaff <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Jul 1 05:40:31 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e2eabca0 |
7 |
|
8 |
dev-ruby/json: add 2.3.1 |
9 |
|
10 |
Package-Manager: Portage-2.3.99, Repoman-2.3.23 |
11 |
Signed-off-by: Hans de Graaff <graaff <AT> gentoo.org> |
12 |
|
13 |
dev-ruby/json/Manifest | 1 + |
14 |
dev-ruby/json/json-2.3.1.ebuild | 73 +++++++++++++++++++++++++++++++++++++++++ |
15 |
2 files changed, 74 insertions(+) |
16 |
|
17 |
diff --git a/dev-ruby/json/Manifest b/dev-ruby/json/Manifest |
18 |
index 6ef49e66810..1744891ca90 100644 |
19 |
--- a/dev-ruby/json/Manifest |
20 |
+++ b/dev-ruby/json/Manifest |
21 |
@@ -1,2 +1,3 @@ |
22 |
DIST json-1.8.6.gem 144384 BLAKE2B db9e407be4ac7e0cb2e09369637b88f70cdac7a659c600dc83a5390746dfd21b0a5243af62afaeeff013b5a4116a3b22c65a481cad89f1ca9be8904af87d0345 SHA512 8f393da080293965389df4a606e0604c500b4b267897b3c1b9007b7700dde8156f6598c25790e84fa20a7e03c7ae359a0b267c7b84e52dfe2a1ac83cf652ad9b |
23 |
DIST json-2.3.0.gem 114176 BLAKE2B 329f1305a0cae3d44c74cc7475c7340e86b8447d5e4ffdd5854620669ee4ef5bba0ed7dbc617b0beffb7bfd8b3d79d46ce26feef37685413a4a5a9c230d0ce0c SHA512 9086a64b664f2d774439c0c9f10c2c1cd897684050eb60f8e3ad9256e0b9541deec3bd22fab0bdcf66e3d5bc795720c6923d514b6edb824c9962fc22f162b332 |
24 |
+DIST json-2.3.1.gem 118784 BLAKE2B 6852f5d1733fd5d596b44d095c37d11a129b02fc61dc81afa90aef3623eefdb5515f6755dce42f055954baf2ac45e87620940ccd7c2c839501945923dbe62d18 SHA512 a9a0c54ac1faacc412ad708b630c8bad8c6f99db6862e8fc80c46207f0f0972433fbfe51d0c93a5d91b91c59b1fef5ad8e64e36cc49e32b3e51ff390a380a2a9 |
25 |
|
26 |
diff --git a/dev-ruby/json/json-2.3.1.ebuild b/dev-ruby/json/json-2.3.1.ebuild |
27 |
new file mode 100644 |
28 |
index 00000000000..c7cfd6fdef9 |
29 |
--- /dev/null |
30 |
+++ b/dev-ruby/json/json-2.3.1.ebuild |
31 |
@@ -0,0 +1,73 @@ |
32 |
+# Copyright 1999-2020 Gentoo Authors |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+ |
35 |
+EAPI=7 |
36 |
+USE_RUBY="ruby25 ruby26 ruby27" |
37 |
+ |
38 |
+RUBY_FAKEGEM_EXTRADOC="CHANGES.md README.md" |
39 |
+RUBY_FAKEGEM_DOCDIR="doc" |
40 |
+ |
41 |
+RUBY_FAKEGEM_GEMSPEC="json.gemspec" |
42 |
+ |
43 |
+inherit multilib ruby-fakegem |
44 |
+ |
45 |
+DESCRIPTION="A JSON implementation as a Ruby extension" |
46 |
+HOMEPAGE="https://github.com/flori/json" |
47 |
+LICENSE="Ruby" |
48 |
+ |
49 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
50 |
+SLOT="2" |
51 |
+IUSE="" |
52 |
+ |
53 |
+RDEPEND="${RDEPEND}" |
54 |
+DEPEND="${DEPEND} |
55 |
+ dev-util/ragel" |
56 |
+ |
57 |
+ruby_add_bdepend "dev-ruby/rake |
58 |
+ doc? ( dev-ruby/rdoc ) |
59 |
+ test? ( dev-ruby/test-unit:2 )" |
60 |
+ |
61 |
+all_ruby_prepare() { |
62 |
+ # Avoid building the extension twice! |
63 |
+ # And use rdoc instead of sdoc which we don't have packaged |
64 |
+ # And don't call git to list files. We're using the pregenerated spec anyway. |
65 |
+ sed -i \ |
66 |
+ -e '/task :test/ s|:compile,||' \ |
67 |
+ -e 's| => :clean||' \ |
68 |
+ -e 's|sdoc|rdoc|' \ |
69 |
+ -e 's|`git ls-files`|""|' \ |
70 |
+ Rakefile || die "rakefile fix failed" |
71 |
+ |
72 |
+ # Remove hardcoded and broken -O setting. |
73 |
+ sed -i -e '/^ \(if\|unless\)/,/^ end/ s:^:#:' \ |
74 |
+ -e '/^unless/,/^end/ s:^:#:' ext/json/ext/*/extconf.rb || die |
75 |
+ |
76 |
+ # Avoid setting gem since it will not be available yet when installing |
77 |
+ sed -i -e '/gem/ s:^:#:' tests/test_helper.rb || die |
78 |
+} |
79 |
+ |
80 |
+each_ruby_configure() { |
81 |
+ for ext in parser generator ; do |
82 |
+ ${RUBY} -Cext/json/ext/${ext} extconf.rb || die |
83 |
+ done |
84 |
+} |
85 |
+ |
86 |
+each_ruby_compile() { |
87 |
+ for ext in parser generator ; do |
88 |
+ emake V=1 -Cext/json/ext/${ext} |
89 |
+ cp ext/json/ext/${ext}/${ext}$(get_modname) ext/json/ext/ || die |
90 |
+ done |
91 |
+} |
92 |
+ |
93 |
+each_ruby_test() { |
94 |
+ for t in pure ext ; do |
95 |
+ JSON=${T} ${RUBY} -S rake do_test_${t} || die |
96 |
+ done |
97 |
+} |
98 |
+ |
99 |
+each_ruby_install() { |
100 |
+ each_fakegem_install |
101 |
+ |
102 |
+ ruby_fakegem_newins ext/json/ext/generator$(get_modname) lib/json/ext/generator$(get_modname) |
103 |
+ ruby_fakegem_newins ext/json/ext/parser$(get_modname) lib/json/ext/parser$(get_modname) |
104 |
+} |