1 |
commit: 58e4da94e0983110401bad83cd0980ac1fedc2d1 |
2 |
Author: Hans de Graaff <graaff <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Mar 30 05:49:51 2017 +0000 |
4 |
Commit: Hans de Graaff <graaff <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Mar 30 05:49:51 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=58e4da94 |
7 |
|
8 |
dev-lang/ruby: add 2.3.4 |
9 |
|
10 |
Package-Manager: Portage-2.3.3, Repoman-2.3.1 |
11 |
|
12 |
dev-lang/ruby/Manifest | 2 + |
13 |
dev-lang/ruby/ruby-2.3.4.ebuild | 242 ++++++++++++++++++++++++++++++++++++++++ |
14 |
2 files changed, 244 insertions(+) |
15 |
|
16 |
diff --git a/dev-lang/ruby/Manifest b/dev-lang/ruby/Manifest |
17 |
index 565258f64cb..c7ab7d4480d 100644 |
18 |
--- a/dev-lang/ruby/Manifest |
19 |
+++ b/dev-lang/ruby/Manifest |
20 |
@@ -3,6 +3,7 @@ DIST ruby-2.1.9.tar.xz 9395648 SHA256 39f203f7498aed2456fb500147fada5adcbf102d89 |
21 |
DIST ruby-2.2.6.tar.xz 10487776 SHA256 9414ecc0d09cf71c9a24e8dc82fcc87919ac7359fb08db2791d6c32bfd157339 SHA512 a2cfde1c6df4df6b996f8d86c52b255fd43b469f8b9f0d7a81ce5f4de949a67025d8bead4ce61f03263eb6a8378b156b843f97b429208afaa1d3bfd0a7af4ef4 WHIRLPOOL 77b01fbd54f77196bca93d0120474436dcdc2e8d437cf70ca1382ed38c58cf05c27e9896cb4b2afd61ea2862ce6b864d707cd4682e17dfc7912d4a74da2b741e |
22 |
DIST ruby-2.2.7.tar.xz 10507528 SHA256 234c8aee6543da9efd67008e6e7ee740d41ed57a52e797f65043c3b5ec3bcb53 SHA512 21bebec6d0972f4e6f2988f471c58520e32096e43a61d627eb2210df283a6fd6d0fc49da9063f2d086f3d489f13e948462a6f084f9e931b4fde6102f490cc225 WHIRLPOOL 35e1470b7d5de25efd213b70befa7b0ce599f3e2ef73aacdf343d7ed3fe14836ab0899124cce8670c00470af9428a81a7f693cb5897448c2d2e824d5b8a1819b |
23 |
DIST ruby-2.3.3.tar.xz 11444164 SHA256 1a4fa8c2885734ba37b97ffdb4a19b8fba0e8982606db02d936e65bac07419dc SHA512 73dd6ed896ff52d953b153b2cab359c87953ea77521878f1ee16c1e217cc46bcb253100debe61ba631e6ffa0bc773e592d603a374508ed5189a311136ccd8d20 WHIRLPOOL aa368a2d0f067ac9d0c6fed62c0e1bdfac0d49c473cd49be9b2774ed3097b76286d091a0887528227f36307b8c1217a2493c5c48fb462db52a3e23cb251a7f79 |
24 |
+DIST ruby-2.3.4.tar.xz 11450108 SHA256 341cd9032e9fd17c452ed8562a8d43f7e45bfe05e411d0d7d627751dd82c578c SHA512 9e3adc2de6703e50e75db37db2981006d4c69759929d61db6a0d63627cfe5977d0ad66d2c69d7161cfc0c0d1c2cb38e5181a06ccd2790df2f72ec25c2ad01e02 WHIRLPOOL 1e9d4112134910ebf1bd241b5031551fdfa882405ca850d9b11af9dc79251379971e18666600d88ef2054c4794a98142df150f83cb06f1dff616faee45ffe1cc |
25 |
DIST ruby-2.4.0.tar.xz 9906880 SHA256 3a87fef45cba48b9322236be60c455c13fd4220184ce7287600361319bb63690 SHA512 975a5388592adc038461e0acebb6c0efee242891b2ea8621476401458efe2bc0fdd317d3bf99beb745b0b3808410efdff33862da29c95c027f457943721e3ab6 WHIRLPOOL 5e0594aa853f9a8a64837d6c34d7110f32471bda719df3ae724643cbe9722b5003cf014ac10130b5a1d59c3f4cc65967c4c00edeea47801e389241be7fe0b53f |
26 |
DIST ruby-2.4.1.tar.xz 9939188 SHA256 4fc8a9992de3e90191de369270ea4b6c1b171b7941743614cc50822ddc1fe654 SHA512 e6fd290b6edd166348b70f0f1c56f7ed9d956c4c1eb91d97d0548041ca4196b9b75ec1ad35c745bdbfd4de195899093e7205d7f02b014ecf1c48e6f31cf25903 WHIRLPOOL b45a6e3bd70e6ef802d084ad87ad0eddd85932e07939bd6ed6a2e6944aa289f231971fedd7d1eece792becb08312f37b80073a2a9df070f61f32747c0708523e |
27 |
DIST ruby-patches-2.1.10.tar.bz2 1931 SHA256 7e02c1b6a6352693bfd5828c9d1a7633a52baa57d8770df182ed0d8b450a3341 SHA512 85928207db4f76e58925e50d39d73db2d521674385ce3232828377e7d7bb4252aafb9f93d6045d4c159bf094b472af61ef9307203db313bf28918fe35e0f3a21 WHIRLPOOL 17a698b0a09be15f444ea34b33e9aa1d029fbd572c565072a92480bf7b6b21f1b6b88b0da3183a486bae30e7e65f3172cd72b7336be1dc5974b62bd8e2b9ef7a |
28 |
@@ -10,5 +11,6 @@ DIST ruby-patches-2.1.9.tar.bz2 1931 SHA256 7e02c1b6a6352693bfd5828c9d1a7633a52b |
29 |
DIST ruby-patches-2.2.6.tar.bz2 2272 SHA256 f54373704ce8df732490e8d1e7e35188503faacc5278fe0ab0d8c07bdc762fed SHA512 ed8bff8f730ccb114e62784d29541f276b2821d9eb121a9772dc4aabc139b688f2b14f5f27710098a8cd751c62d31b46170b427ad54dc4f6490c003450ae1583 WHIRLPOOL 8598c9284252c1e7cc9f9019c5f468ce5ab8b4ae013e71c631cd00cc8bfde068b041f1bc6851bb2962982a1e46cbde0ddc51c186ea41638a7881c587c658e603 |
30 |
DIST ruby-patches-2.2.7.tar.bz2 2272 SHA256 f54373704ce8df732490e8d1e7e35188503faacc5278fe0ab0d8c07bdc762fed SHA512 ed8bff8f730ccb114e62784d29541f276b2821d9eb121a9772dc4aabc139b688f2b14f5f27710098a8cd751c62d31b46170b427ad54dc4f6490c003450ae1583 WHIRLPOOL 8598c9284252c1e7cc9f9019c5f468ce5ab8b4ae013e71c631cd00cc8bfde068b041f1bc6851bb2962982a1e46cbde0ddc51c186ea41638a7881c587c658e603 |
31 |
DIST ruby-patches-2.3.3-r1.tar.bz2 2223 SHA256 f0a803173564368e5cf31162e1dba901c46640f9e861255f6cbe14256d18f3eb SHA512 bb47000e516017c1fedf7c5313b0628fa734030e69bd0fed1c06a38dd115b8c50837e3dd917f272e24abf5609c4c12793ae4570bfd7d6210290785bf2f8287bd WHIRLPOOL 0b0d4dcf7df4ff3ff11610bfe7a7b29ed621b45b412cb7618a6572f98a568ac67419bd852b193cfc3aa0968382cf9400a578511e9e8fb8b2125bc876e733bd64 |
32 |
+DIST ruby-patches-2.3.4.tar.bz2 2255 SHA256 32bb888f3ea9e81e4fdff5e852493aafc8f12bfcf9997981f7b7588d6e8ec9c1 SHA512 af7ad3255cf8450859e3c5564393ca106893fd1e40178ad153fb8e66871d30e326f63d48c1904fac5c353408f71e767c72d49fdbf47198c041a628b41c51c868 WHIRLPOOL dc412a788ec77dc9dad4fd631fc8aa5c909b9d21bf6b0b538c4ba398c1670cb01fbf1e4d92a38fa869b96f786707a9c45c7fe5ca7e04f75ff428b20d9fb34c53 |
33 |
DIST ruby-patches-2.4.0.tar.bz2 2047 SHA256 9560b8e8dc4a5517814df07aa635c9269f5e7cff5a15827a25a9f0811194e450 SHA512 b35db875a7e4a226e75eb6f7bc68b4bc97cc699bdc5f6930015e55cdc324b67b9883a2aa574c9c9a8b5dc5345c4df8a5ca8ace5b794b3e4de6517f3eefd25745 WHIRLPOOL fc5d226f46fe4ee1c86f6fff51ec9184b8c0ec08a1793eab365437d4ce2fd573cfc8857386cd10932f7dde05254bc975eff5b7986aea429730c606147fae2a5c |
34 |
DIST ruby-patches-2.4.1.tar.bz2 2047 SHA256 9560b8e8dc4a5517814df07aa635c9269f5e7cff5a15827a25a9f0811194e450 SHA512 b35db875a7e4a226e75eb6f7bc68b4bc97cc699bdc5f6930015e55cdc324b67b9883a2aa574c9c9a8b5dc5345c4df8a5ca8ace5b794b3e4de6517f3eefd25745 WHIRLPOOL fc5d226f46fe4ee1c86f6fff51ec9184b8c0ec08a1793eab365437d4ce2fd573cfc8857386cd10932f7dde05254bc975eff5b7986aea429730c606147fae2a5c |
35 |
|
36 |
diff --git a/dev-lang/ruby/ruby-2.3.4.ebuild b/dev-lang/ruby/ruby-2.3.4.ebuild |
37 |
new file mode 100644 |
38 |
index 00000000000..cb9bbb4e590 |
39 |
--- /dev/null |
40 |
+++ b/dev-lang/ruby/ruby-2.3.4.ebuild |
41 |
@@ -0,0 +1,242 @@ |
42 |
+# Copyright 1999-2017 Gentoo Foundation |
43 |
+# Distributed under the terms of the GNU General Public License v2 |
44 |
+ |
45 |
+EAPI=5 |
46 |
+ |
47 |
+#PATCHSET=1 |
48 |
+ |
49 |
+inherit autotools eutils flag-o-matic multilib versionator |
50 |
+ |
51 |
+MY_P="${PN}-$(get_version_component_range 1-3)" |
52 |
+S=${WORKDIR}/${MY_P} |
53 |
+ |
54 |
+SLOT=$(get_version_component_range 1-2) |
55 |
+MY_SUFFIX=$(delete_version_separator 1 ${SLOT}) |
56 |
+RUBYVERSION=2.3.0 |
57 |
+ |
58 |
+if [[ -n ${PATCHSET} ]]; then |
59 |
+ if [[ ${PVR} == ${PV} ]]; then |
60 |
+ PATCHSET="${PV}-r0.${PATCHSET}" |
61 |
+ else |
62 |
+ PATCHSET="${PVR}.${PATCHSET}" |
63 |
+ fi |
64 |
+else |
65 |
+ PATCHSET="${PVR}" |
66 |
+fi |
67 |
+ |
68 |
+DESCRIPTION="An object-oriented scripting language" |
69 |
+HOMEPAGE="http://www.ruby-lang.org/" |
70 |
+SRC_URI="mirror://ruby/${SLOT}/${MY_P}.tar.xz |
71 |
+ https://dev.gentoo.org/~flameeyes/ruby-team/${PN}-patches-${PATCHSET}.tar.bz2" |
72 |
+ |
73 |
+LICENSE="|| ( Ruby-BSD BSD-2 )" |
74 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd" |
75 |
+IUSE="berkdb debug doc examples gdbm ipv6 jemalloc libressl +rdoc rubytests socks5 ssl tk xemacs ncurses +readline" |
76 |
+ |
77 |
+RDEPEND=" |
78 |
+ berkdb? ( sys-libs/db:= ) |
79 |
+ gdbm? ( sys-libs/gdbm ) |
80 |
+ jemalloc? ( dev-libs/jemalloc ) |
81 |
+ ssl? ( |
82 |
+ !libressl? ( dev-libs/openssl:0= ) |
83 |
+ libressl? ( dev-libs/libressl ) |
84 |
+ ) |
85 |
+ socks5? ( >=net-proxy/dante-1.1.13 ) |
86 |
+ tk? ( |
87 |
+ dev-lang/tcl:0=[threads] |
88 |
+ dev-lang/tk:0=[threads] |
89 |
+ ) |
90 |
+ ncurses? ( sys-libs/ncurses:0= ) |
91 |
+ readline? ( sys-libs/readline:0= ) |
92 |
+ dev-libs/libyaml |
93 |
+ virtual/libffi |
94 |
+ sys-libs/zlib |
95 |
+ >=app-eselect/eselect-ruby-20151229 |
96 |
+ !<dev-ruby/rdoc-3.9.4 |
97 |
+ !<dev-ruby/rubygems-1.8.10-r1" |
98 |
+ |
99 |
+DEPEND="${RDEPEND}" |
100 |
+ |
101 |
+BUNDLED_GEMS=" |
102 |
+ >=dev-ruby/did_you_mean-1.0.0:1[ruby_targets_ruby23] |
103 |
+ >=dev-ruby/minitest-5.8.3[ruby_targets_ruby23] |
104 |
+ >=dev-ruby/net-telnet-0.1.1[ruby_targets_ruby23] |
105 |
+ >=dev-ruby/power_assert-0.2.6[ruby_targets_ruby23] |
106 |
+ >=dev-ruby/rake-10.4.2[ruby_targets_ruby23] |
107 |
+ >=dev-ruby/test-unit-3.1.5[ruby_targets_ruby23] |
108 |
+" |
109 |
+ |
110 |
+PDEPEND=" |
111 |
+ ${BUNDLED_GEMS} |
112 |
+ virtual/rubygems[ruby_targets_ruby23] |
113 |
+ >=dev-ruby/json-1.8.3[ruby_targets_ruby23] |
114 |
+ rdoc? ( >=dev-ruby/rdoc-4.2.1[ruby_targets_ruby23] ) |
115 |
+ xemacs? ( app-xemacs/ruby-modes )" |
116 |
+ |
117 |
+src_prepare() { |
118 |
+ EPATCH_FORCE="yes" EPATCH_SUFFIX="patch" \ |
119 |
+ epatch "${WORKDIR}/patches" |
120 |
+ |
121 |
+ einfo "Unbundling gems..." |
122 |
+ cd "$S" |
123 |
+ # Remove bundled gems that we will install via PDEPEND, bug |
124 |
+ # 539700. Use explicit version numbers to ensure rm fails when they |
125 |
+ # change so we can update dependencies accordingly. |
126 |
+ rm -f gems/{did_you_mean-1.0.0,minitest-5.8.3,net-telnet-0.1.1,power_assert-0.2.6,rake-10.4.2,test-unit-3.1.5}.gem || die |
127 |
+ |
128 |
+ # Fix a hardcoded lib path in configure script |
129 |
+ sed -i -e "s:\(RUBY_LIB_PREFIX=\"\${prefix}/\)lib:\1$(get_libdir):" \ |
130 |
+ configure.in || die "sed failed" |
131 |
+ |
132 |
+ eautoreconf |
133 |
+} |
134 |
+ |
135 |
+src_configure() { |
136 |
+ local modules= myconf= |
137 |
+ |
138 |
+ # -fomit-frame-pointer makes ruby segfault, see bug #150413. |
139 |
+ filter-flags -fomit-frame-pointer |
140 |
+ # In many places aliasing rules are broken; play it safe |
141 |
+ # as it's risky with newer compilers to leave it as it is. |
142 |
+ append-flags -fno-strict-aliasing |
143 |
+ # SuperH needs this |
144 |
+ use sh && append-flags -mieee |
145 |
+ |
146 |
+ # Socks support via dante |
147 |
+ if use socks5 ; then |
148 |
+ # Socks support can't be disabled as long as SOCKS_SERVER is |
149 |
+ # set and socks library is present, so need to unset |
150 |
+ # SOCKS_SERVER in that case. |
151 |
+ unset SOCKS_SERVER |
152 |
+ fi |
153 |
+ |
154 |
+ # Increase GC_MALLOC_LIMIT if set (default is 8000000) |
155 |
+ if [ -n "${RUBY_GC_MALLOC_LIMIT}" ] ; then |
156 |
+ append-flags "-DGC_MALLOC_LIMIT=${RUBY_GC_MALLOC_LIMIT}" |
157 |
+ fi |
158 |
+ |
159 |
+ # ipv6 hack, bug 168939. Needs --enable-ipv6. |
160 |
+ use ipv6 || myconf="${myconf} --with-lookup-order-hack=INET" |
161 |
+ |
162 |
+ # Determine which modules *not* to build depending in the USE flags. |
163 |
+ if ! use readline ; then |
164 |
+ modules="${modules},readline" |
165 |
+ fi |
166 |
+ if ! use berkdb ; then |
167 |
+ modules="${modules},dbm" |
168 |
+ fi |
169 |
+ if ! use gdbm ; then |
170 |
+ modules="${modules},gdbm" |
171 |
+ fi |
172 |
+ if ! use ssl ; then |
173 |
+ modules="${modules},openssl" |
174 |
+ fi |
175 |
+ if ! use ncurses ; then |
176 |
+ modules="${modules},curses" |
177 |
+ fi |
178 |
+ if ! use tk ; then |
179 |
+ modules="${modules},tk" |
180 |
+ fi |
181 |
+ |
182 |
+ # Provide an empty LIBPATHENV because we disable rpath but we do not |
183 |
+ # need LD_LIBRARY_PATH by default since that breaks USE=multitarget |
184 |
+ # #564272 |
185 |
+ INSTALL="${EPREFIX}/usr/bin/install -c" LIBPATHENV="" econf \ |
186 |
+ --program-suffix=${MY_SUFFIX} \ |
187 |
+ --with-soname=ruby${MY_SUFFIX} \ |
188 |
+ --docdir=${EPREFIX}/usr/share/doc/${P} \ |
189 |
+ --enable-shared \ |
190 |
+ --enable-pthread \ |
191 |
+ --disable-rpath \ |
192 |
+ --with-out-ext="${modules}" \ |
193 |
+ $(use_enable jemalloc jemalloc) \ |
194 |
+ $(use_enable socks5 socks) \ |
195 |
+ $(use_enable doc install-doc) \ |
196 |
+ --enable-ipv6 \ |
197 |
+ $(use_enable debug) \ |
198 |
+ ${myconf} \ |
199 |
+ --enable-option-checking=no \ |
200 |
+ || die "econf failed" |
201 |
+} |
202 |
+ |
203 |
+src_compile() { |
204 |
+ emake V=1 EXTLDFLAGS="${LDFLAGS}" || die "emake failed" |
205 |
+} |
206 |
+ |
207 |
+src_test() { |
208 |
+ emake -j1 V=1 test || die "make test failed" |
209 |
+ |
210 |
+ elog "Ruby's make test has been run. Ruby also ships with a make check" |
211 |
+ elog "that cannot be run until after ruby has been installed." |
212 |
+ elog |
213 |
+ if use rubytests; then |
214 |
+ elog "You have enabled rubytests, so they will be installed to" |
215 |
+ elog "/usr/share/${PN}-${SLOT}/test. To run them you must be a user other" |
216 |
+ elog "than root, and you must place them into a writeable directory." |
217 |
+ elog "Then call: " |
218 |
+ elog |
219 |
+ elog "ruby${MY_SUFFIX} -C /location/of/tests runner.rb" |
220 |
+ else |
221 |
+ elog "Enable the rubytests USE flag to install the make check tests" |
222 |
+ fi |
223 |
+} |
224 |
+ |
225 |
+src_install() { |
226 |
+ # Remove the remaining bundled gems. We do this late in the process |
227 |
+ # since they are used during the build to e.g. create the |
228 |
+ # documentation. |
229 |
+ rm -rf ext/json || die |
230 |
+ |
231 |
+ # Ruby is involved in the install process, we don't want interference here. |
232 |
+ unset RUBYOPT |
233 |
+ |
234 |
+ local MINIRUBY=$(echo -e 'include Makefile\ngetminiruby:\n\t@echo $(MINIRUBY)'|make -f - getminiruby) |
235 |
+ |
236 |
+ LD_LIBRARY_PATH="${S}:${D}/usr/$(get_libdir)${LD_LIBRARY_PATH+:}${LD_LIBRARY_PATH}" |
237 |
+ RUBYLIB="${S}:${D}/usr/$(get_libdir)/ruby/${RUBYVERSION}" |
238 |
+ for d in $(find "${S}/ext" -type d) ; do |
239 |
+ RUBYLIB="${RUBYLIB}:$d" |
240 |
+ done |
241 |
+ export LD_LIBRARY_PATH RUBYLIB |
242 |
+ |
243 |
+ emake V=1 DESTDIR="${D}" install || die "make install failed" |
244 |
+ |
245 |
+ # Remove installed rubygems and rdoc copy |
246 |
+ rm -rf "${D}/usr/$(get_libdir)/ruby/${RUBYVERSION}/rubygems" || die "rm rubygems failed" |
247 |
+ rm -rf "${D}/usr/bin/"gem"${MY_SUFFIX}" || die "rm rdoc bins failed" |
248 |
+ rm -rf "${D}/usr/$(get_libdir)/ruby/${RUBYVERSION}"/rdoc* || die "rm rdoc failed" |
249 |
+ rm -rf "${D}/usr/bin/"{ri,rdoc}"${MY_SUFFIX}" || die "rm rdoc bins failed" |
250 |
+ |
251 |
+ if use doc; then |
252 |
+ make DESTDIR="${D}" install-doc || die "make install-doc failed" |
253 |
+ fi |
254 |
+ |
255 |
+ if use examples; then |
256 |
+ insinto /usr/share/doc/${PF} |
257 |
+ doins -r sample |
258 |
+ fi |
259 |
+ |
260 |
+ dodoc ChangeLog NEWS doc/NEWS* README* || die |
261 |
+ |
262 |
+ if use rubytests; then |
263 |
+ pushd test |
264 |
+ insinto /usr/share/${PN}-${SLOT}/test |
265 |
+ doins -r . |
266 |
+ popd |
267 |
+ fi |
268 |
+} |
269 |
+ |
270 |
+pkg_postinst() { |
271 |
+ if [[ ! -n $(readlink "${ROOT}"usr/bin/ruby) ]] ; then |
272 |
+ eselect ruby set ruby${MY_SUFFIX} |
273 |
+ fi |
274 |
+ |
275 |
+ elog |
276 |
+ elog "To switch between available Ruby profiles, execute as root:" |
277 |
+ elog "\teselect ruby set ruby(19|20|...)" |
278 |
+ elog |
279 |
+} |
280 |
+ |
281 |
+pkg_postrm() { |
282 |
+ eselect ruby cleanup |
283 |
+} |