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/rmagick/
Date: Sat, 01 Oct 2022 07:06:42
Message-Id: 1664607993.82cdfa22f502ff0832955fcbb213efbd714469f9.graaff@gentoo
1 commit: 82cdfa22f502ff0832955fcbb213efbd714469f9
2 Author: Hans de Graaff <graaff <AT> gentoo <DOT> org>
3 AuthorDate: Sat Oct 1 07:03:03 2022 +0000
4 Commit: Hans de Graaff <graaff <AT> gentoo <DOT> org>
5 CommitDate: Sat Oct 1 07:06:33 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=82cdfa22
7
8 dev-ruby/rmagick: add 4.3.0
9
10 Signed-off-by: Hans de Graaff <graaff <AT> gentoo.org>
11
12 dev-ruby/rmagick/Manifest | 1 +
13 dev-ruby/rmagick/rmagick-4.3.0.ebuild | 82 +++++++++++++++++++++++++++++++++++
14 2 files changed, 83 insertions(+)
15
16 diff --git a/dev-ruby/rmagick/Manifest b/dev-ruby/rmagick/Manifest
17 index ad001520a477..0258bfebe95f 100644
18 --- a/dev-ruby/rmagick/Manifest
19 +++ b/dev-ruby/rmagick/Manifest
20 @@ -1,3 +1,4 @@
21 DIST rmagick-4.2.2.tar.gz 1984143 BLAKE2B 8b8119a0002c48f3a289f72d4bbea6ac86cbecb287b34ddc14ca126fd2d951a34aefa39d68603dc4c9de674d346e47ef9e3b2c8ed96a5bc081373a4184a3ec40 SHA512 0a6a30a631786ea310d2c8add297abd527588be755d021143d6c64fbb597006aefef859c374604f8d26b0f8b1f6cd8a5f1cdd6489772ee713c71681f3980c7fd
22 DIST rmagick-4.2.5.tar.gz 1984865 BLAKE2B 5a96967da0583ca6d16252fd3e93162cc31b4b125875e16334436c2ec54cb9b739d4a0e0e08547a6218312ce844b3b78cca5f63cf4b81ae3f15abbf9816ceac8 SHA512 55835e43bf583c6c53431849caa54900902d0d63f21c7f70b0bdbcfbe69d16a71d433d1d9b949bf68ed36f6fc7f18ae512f0e96c26ff1c63a68bbc83446b52d8
23 DIST rmagick-4.2.6.tar.gz 1986381 BLAKE2B 7923d2fcb72de60566ca827a1d82987af26a2d952eefee58156b64922bb015188147c83d82983f19072f65bcb8fa8589e7011b8d7dcf1365716301929584f453 SHA512 0e80c9df540d95ecdabedf2d556165e7b1b51bcc2a3becdca9b9a0a229f051671343fc1481a7ca46090ce24c220cbdb02cd3e895bb024a6426cef73de333bd4d
24 +DIST rmagick-4.3.0.tar.gz 1986554 BLAKE2B bf6afb0b19a98f45dd9f3a8261b67ad05ed774784e9fb19009a83c266c16362b4938acd8b0af6a07d3a37fb255fb5bee7a33b7f26c2c49460d546665a98a7871 SHA512 1b108d61b836bf382c9776badc45614ff88ca74176595765c3caba00cc6af0f955dd6f7649a9f97698832193d85292bc22ff0bf290d0bfbf9e8faa58b99b0b1c
25
26 diff --git a/dev-ruby/rmagick/rmagick-4.3.0.ebuild b/dev-ruby/rmagick/rmagick-4.3.0.ebuild
27 new file mode 100644
28 index 000000000000..bfe3758668ab
29 --- /dev/null
30 +++ b/dev-ruby/rmagick/rmagick-4.3.0.ebuild
31 @@ -0,0 +1,82 @@
32 +# Copyright 1999-2022 Gentoo Authors
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI=8
36 +USE_RUBY="ruby27 ruby30 ruby31"
37 +
38 +RUBY_FAKEGEM_RECIPE_TEST="rspec3"
39 +
40 +RUBY_FAKEGEM_TASK_DOC=""
41 +
42 +RUBY_FAKEGEM_EXTRADOC="CHANGELOG.md README.md"
43 +
44 +RUBY_FAKEGEM_GEMSPEC="rmagick.gemspec"
45 +
46 +RUBY_FAKEGEM_EXTENSIONS=(ext/RMagick/extconf.rb)
47 +
48 +MY_PV=RMagick_${PV//\./-}
49 +
50 +inherit ruby-fakegem
51 +
52 +DESCRIPTION="An interface between Ruby and the ImageMagick(TM) image processing library"
53 +HOMEPAGE="https://github.com/rmagick/rmagick"
54 +SRC_URI="https://github.com/rmagick/rmagick/archive/${MY_PV}.tar.gz -> ${P}.tar.gz"
55 +RUBY_S="rmagick-${MY_PV}"
56 +
57 +LICENSE="Artistic"
58 +SLOT="4"
59 +KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~x86"
60 +IUSE="doc"
61 +
62 +RDEPEND+=" >=media-gfx/imagemagick-6.9.0:="
63 +DEPEND+=" test? ( >=media-gfx/imagemagick-7.1.0:=[jpeg,lqr,lcms,postscript,tiff,webp] )"
64 +
65 +all_ruby_prepare() {
66 + # Avoid unused dependency on rake-compiler. This also avoids an
67 + # extra compile during tests.
68 + sed -i -e '/extensiontask/ s:^:#:' \
69 + -e '/ExtensionTask/,/end/ s:^:#:' \
70 + -e '/compile/ s:^:#:' Rakefile || die
71 + sed -i -e '/pry/ s:^:#:' spec/spec_helper.rb || die
72 + sed -i -e 's/git ls-files/find */' ${RUBY_FAKEGEM_GEMSPEC} || die
73 +
74 + # Squelch harmless warning about imagemagick installation.
75 + sed -i -e '/prefix/ s:ImageMagick:ImageMagick-6:' ext/RMagick/extconf.rb || die
76 +
77 + # Reading PDFs is not allowed by the default Gentoo security policy for imagemagick
78 + #sed -i -e '/can read PDF file/askip "Not allowed by Gentoo security policy"' spec/rmagick/image/read_spec.rb || die
79 +
80 + # Update version number hardcoded in tests
81 + sed -i -e 's/"7.0"/"7.1"/' spec/rmagick/image/channel_mean_spec.rb || die
82 +
83 + # Create directory used for a test
84 + mkdir tmp
85 +}
86 +
87 +each_ruby_test() {
88 + # Borrowed from media-gfx/gscan2pdf
89 + # Needed to avoid test failures on e.g. ppc, bug #815856
90 + # (Unclear why it doesn't manifest on amd64 here at least)
91 + local confdir="${HOME}/.config/ImageMagick"
92 + mkdir -p "${confdir}" || die
93 + cat > "${confdir}/policy.xml" <<-EOT || die
94 + <policymap>
95 + <policy domain="coder" rights="read|write" pattern="PDF" />
96 + <policy domain="coder" rights="read" pattern="PS" />
97 + </policymap>
98 + EOT
99 +
100 + RSPEC_VERSION="3" ruby-ng_rspec
101 +}
102 +
103 +all_ruby_install() {
104 + all_fakegem_install
105 +
106 + docinto examples
107 + dodoc examples/*
108 +
109 + if use doc ; then
110 + docinto .
111 + dodoc -r doc
112 + fi
113 +}