summaryrefslogtreecommitdiff
path: root/dev-lang/ruby
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-12-25 23:06:25 +0000
committerV3n3RiX <venerix@redcorelinux.org>2020-12-25 23:06:25 +0000
commit441d1370330332b7d78f238d2f5e13f7aed5e4e0 (patch)
tree6a5171dd615dfeee62a45044144c66e864738fb0 /dev-lang/ruby
parentab3da91fb6c91a9df52fff8f991570f456fd3c7a (diff)
gentoo christmass resync : 25.12.2020
Diffstat (limited to 'dev-lang/ruby')
-rw-r--r--dev-lang/ruby/Manifest6
-rw-r--r--dev-lang/ruby/ruby-2.6.6-r1.ebuild232
-rw-r--r--dev-lang/ruby/ruby-2.6.6.ebuild232
-rw-r--r--dev-lang/ruby/ruby-2.7.1-r1.ebuild235
-rw-r--r--dev-lang/ruby/ruby-2.7.1-r2.ebuild237
-rw-r--r--dev-lang/ruby/ruby-2.7.1.ebuild235
6 files changed, 0 insertions, 1177 deletions
diff --git a/dev-lang/ruby/Manifest b/dev-lang/ruby/Manifest
index 079a9a231ae9..1be5c16339e3 100644
--- a/dev-lang/ruby/Manifest
+++ b/dev-lang/ruby/Manifest
@@ -15,15 +15,9 @@ AUX 2.6/010-default-gem-location.patch 688 BLAKE2B 4c2074d69b9fe5258a2fe0e38bb50
AUX 2.7/010-default-gem-location.patch 688 BLAKE2B 4c2074d69b9fe5258a2fe0e38bb501a39f34ad1fa08ef338224edba1f06073138cbe3d831ecdf9910c989a7f0a1c6c6b73ced0d8ff212207a3a3df5f4d90b5de SHA512 65206a6ca42ade0413ae1467f41082f4a93b3166644d2504cff3d280d23da02fd41aea5aca69dd43f6081b436db90a5b1e98725d8fa51519ca302c02ec526ad7
DIST ruby-2.5.8.tar.xz 11298404 BLAKE2B 3256c0448e72b63c0bd89f89a27fa9c09c8feed54d42cd79899b7d5cfe9dbc29ca708d12c630b3f52ff85b0c6a4011ae7ff0483d64b2fd445700a72a91028035 SHA512 2886be764a454425c5beef2777c64a70ee0d048b07896b327633d904f5077fea4299526689f9e2ac4dcd2fc4811cf9a6c8ce75367ed35d29dfe1a54222872e0d
DIST ruby-2.6.6.tar.xz 11567284 BLAKE2B 45e910dd9b128c46bff3003834c4fdcbbc2e2e4d3e44f298ff4356a285de2c375d6b6021a3aa28d89336b32a1655fa4a7c086d07f4a0f6bcd578a11dd4a894da SHA512 86caf93dbf61d03781767ab5375a7edf4761f13ba08ccfefe16c0a7550499237e7390c2f72a95d42670d4fe76b2401b4218936187c62ec1572799e9e04c50d62
-DIST ruby-2.7.1.tar.xz 12003684 BLAKE2B 90a35c3e246cfe982a146be29a3d121d6e2c251ed96703dbc46b98c21e0e43e5445132e6119e584ae35f7193f063ff1b14822f947a4e07037c37fbba5e4038da SHA512 79f98b1ea98e0b10ec79da1883e8fc84d48ffe5c09ae945cbebde94365e35a589d919aac965f74d70ca7e21370ecee631ac5a8f9c4eac61d62f5aa629f27bf31
DIST ruby-2.7.2.tar.xz 12037052 BLAKE2B a4ad22295b3fed4e8064fc6e77adb8642d1fa7ae1f4ef912d7bde19c735cb25b1a3e3aefba53dad944046d844d608bcefba61c314cf1e52747f50d7d91f4c436 SHA512 7972278b096aa768c7adf2befd26003e18781a29ca317640317d30d93d6e963ded197724c8e2f1dfe1e838c5647176d414a74732a62e931fb50d6f2e0f777349
EBUILD ruby-2.5.8-r1.ebuild 7100 BLAKE2B 912195706cc476e52dd0e20005d4a04a11b286312de1129a91e281e291fa3caeb7de083e296db8384de3816198f3c1c02168bfc09120628cef95cece93345ad8 SHA512 1f20bab421047c622053d7e07a873e1e8c35bac6b5d938ed1d72e33cf7f99be7ec1f300eac9da38651fcc7b3761a81140f630cf1039cde78c3858e2942e01728
EBUILD ruby-2.5.8.ebuild 6189 BLAKE2B aa04b9f393085468d3452bfcc55a45c721bcbe51c9602d6f44510d1f936369f1c741ade879d24c619b1722270a460ba20bc679f0714a98d310d8293bc84c3678 SHA512 156ac0da5b5e6d1240bcb42ad9a7ce455a17077a3bfd66610d5425216ff7436462e8e1362764c8614900376eef146b168e1dd4691cddd9f13ded5a4a30204c9e
-EBUILD ruby-2.6.6-r1.ebuild 6614 BLAKE2B b4862b320dbb557bde3b3c6e86b0d178a3421587afdb848ecf5991d48525c20b0012cf88cd31cc5f130088127b6c6ea5dd121cb461c842cab183f3db02260356 SHA512 28f23b21a389e90a59738a4debb38ed0eb30e44eac1dd3df0037fdd37d6e1467ee61beaa5dd35460cd767b743ef48c6c31b243cb207ffdef3b94bb3ef6d6241e
EBUILD ruby-2.6.6-r2.ebuild 7508 BLAKE2B 57e533cae47720895e1c5b09489df0895540cafe9b6601c2434f73de8fba58fefc24ccc3d9c60c0b729eafb0200e4e28657ad10f20c578c6fc6f2a67950fd99a SHA512 a4c5caf911449ca64d801de6e44c9431d7934f885905040a830b90fe7c87ee50c8cf1e8fc838ab50af6856ac96c9b85f4e251408ea7aeeb8ebd335708e7d17eb
-EBUILD ruby-2.6.6.ebuild 6614 BLAKE2B af5f7d759a8676db12091569871bf5d39a430715b1bba11c6f8a7fafb210039d0966797c5b2974fb56e91e670b65710adb73dbcc64cf20f2473c1b02f84bd4ba SHA512 ca639f0b01b4618f876d6473aa4a6756a97d66b8194a623865f8f96758016e3d4109ca5905570bbd0c7ad680c66722fffa91fc6c506083fd8e0ea418e354ffe9
-EBUILD ruby-2.7.1-r1.ebuild 6777 BLAKE2B 6f2bf65a51e784c931b962b7e1430655dc194801a2fd0ea63eff7c6ff97dd624939ff5f37ed6a2fa9aaec27ab0cad94281d4172051cc5e298e4df3b15d6deb41 SHA512 733c164d8d1a70a68d313ec764807386df22cbefa04346e788b3701e7a242899cb086ae18096002c3dee0c3f6459752a3f751c032320a9b0ae947e0ab2d16cc4
-EBUILD ruby-2.7.1-r2.ebuild 6857 BLAKE2B e4ed8cbe491edcc6123435383ead38cbe968f388acd35a0b9aa4e2ce556b8ac15e4c8ae5057678c5ef3c9e552b2a285953e85792fef8d45b0242dc4a52a59bb1 SHA512 1ac8a7d752fd80d4b70833acb059f650b0e79df376a6c956dd1f47857ef418e8ba5a7ff3cdf893eec17dd7afef901b95dec25eab8b1bda0e7f907ca658933453
-EBUILD ruby-2.7.1.ebuild 6777 BLAKE2B 987421adeb916bed61606194e0c4eff5d26e4da8e7d973bcc4ee2983fdbfb38c030a256b5327d23af3e2fd44dd2287cbeb4fd7072d375a3723fc16b1e18a5430 SHA512 3b733ece468748c72245c0cd83f8cb603e279db33aefa224f52c3441143332939b35f773a1d2d4a2cca688a74875f32537209b15cffbb5b4d7c1f6618f8a4a6b
EBUILD ruby-2.7.2.ebuild 7679 BLAKE2B b4b0172836ea666a7e74d2cce467b7a19f449c702c49254a9a58f90925110207d9a9b183e285c63d8034eba931a30738fb935db129eece6ccafe1ff2615b4b73 SHA512 7dcac5ddecc5bd150a3b1c6a9ea29d34565fd242689c94d4101a5ff1e923f9917dc3ba0e8f32985092b21d067263f2cc08ca25d15808260c8100a9bffc76b29a
MISC metadata.xml 523 BLAKE2B 4ed08360a279c8d44fe87f677cdc24a76eda6d37c591186951e16321f464d4451d0d1299c4e1d996bffe15a8cca672d4c5c1bc5fb0aa6cda69b8eff90ec31df8 SHA512 f74c386a3d6314d630aff11c40314db40b7f9fb202910480b37aa65b7bac62d6e87fa7590b2a26aa1713bb65be486ed84138e1273eaf7c8b966d7414e6b55464
diff --git a/dev-lang/ruby/ruby-2.6.6-r1.ebuild b/dev-lang/ruby/ruby-2.6.6-r1.ebuild
deleted file mode 100644
index 7a67e1a482c5..000000000000
--- a/dev-lang/ruby/ruby-2.6.6-r1.ebuild
+++ /dev/null
@@ -1,232 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools flag-o-matic multilib
-
-MY_P="${PN}-$(ver_cut 1-3)"
-S=${WORKDIR}/${MY_P}
-
-SLOT=$(ver_cut 1-2)
-MY_SUFFIX=$(ver_rs 1 '' ${SLOT})
-RUBYVERSION=${SLOT}.0
-
-DESCRIPTION="An object-oriented scripting language"
-HOMEPAGE="https://www.ruby-lang.org/"
-SRC_URI="https://cache.ruby-lang.org/pub/ruby/${SLOT}/${MY_P}.tar.xz"
-
-LICENSE="|| ( Ruby-BSD BSD-2 )"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
-IUSE="berkdb debug doc examples gdbm ipv6 jemalloc jit libressl +rdoc rubytests socks5 +ssl static-libs tk xemacs"
-
-RDEPEND="
- berkdb? ( sys-libs/db:= )
- gdbm? ( sys-libs/gdbm:= )
- jemalloc? ( dev-libs/jemalloc )
- jit? ( || ( sys-devel/gcc:* sys-devel/clang:* ) )
- ssl? (
- !libressl? ( dev-libs/openssl:0= )
- libressl? ( dev-libs/libressl )
- )
- socks5? ( >=net-proxy/dante-1.1.13 )
- tk? (
- dev-lang/tcl:0=[threads]
- dev-lang/tk:0=[threads]
- )
- dev-libs/libyaml
- dev-libs/libffi:=
- sys-libs/readline:0=
- sys-libs/zlib
- >=app-eselect/eselect-ruby-20181225
-"
-
-DEPEND="${RDEPEND}"
-
-BUNDLED_GEMS="
- >=dev-ruby/did_you_mean-1.2.1[ruby_targets_ruby26]
- >=dev-ruby/minitest-5.11.3[ruby_targets_ruby26]
- >=dev-ruby/net-telnet-0.2.0[ruby_targets_ruby26]
- >=dev-ruby/power_assert-1.1.3[ruby_targets_ruby26]
- >=dev-ruby/rake-12.3.2[ruby_targets_ruby26]
- >=dev-ruby/test-unit-3.2.9[ruby_targets_ruby26]
- >=dev-ruby/xmlrpc-0.3.0[ruby_targets_ruby26]
-"
-
-PDEPEND="
- ${BUNDLED_GEMS}
- virtual/rubygems[ruby_targets_ruby26]
- >=dev-ruby/bundler-1.17.2[ruby_targets_ruby26]
- >=dev-ruby/json-2.0.2[ruby_targets_ruby26]
- rdoc? ( >=dev-ruby/rdoc-6.1.2[ruby_targets_ruby26] )
- xemacs? ( app-xemacs/ruby-modes )"
-
-src_prepare() {
- # 005 does not compile bigdecimal and is questionable because it
- # compiles ruby in a non-standard way, may be dropped
- eapply "${FILESDIR}"/2.6/010*.patch
-
- einfo "Unbundling gems..."
- cd "$S"
- # Remove bundled gems that we will install via PDEPEND, bug
- # 539700.
- rm -fr gems/* || die
-
- einfo "Removing bundled libraries..."
- rm -fr ext/fiddle/libffi-3.2.1 || die
-
- eapply_user
-
- eautoreconf
-}
-
-src_configure() {
- local modules= myconf=
-
- # -fomit-frame-pointer makes ruby segfault, see bug #150413.
- filter-flags -fomit-frame-pointer
- # In many places aliasing rules are broken; play it safe
- # as it's risky with newer compilers to leave it as it is.
- append-flags -fno-strict-aliasing
-
- # Socks support via dante
- if use socks5 ; then
- # Socks support can't be disabled as long as SOCKS_SERVER is
- # set and socks library is present, so need to unset
- # SOCKS_SERVER in that case.
- unset SOCKS_SERVER
- fi
-
- # Increase GC_MALLOC_LIMIT if set (default is 8000000)
- if [ -n "${RUBY_GC_MALLOC_LIMIT}" ] ; then
- append-flags "-DGC_MALLOC_LIMIT=${RUBY_GC_MALLOC_LIMIT}"
- fi
-
- # ipv6 hack, bug 168939. Needs --enable-ipv6.
- use ipv6 || myconf="${myconf} --with-lookup-order-hack=INET"
-
- # Determine which modules *not* to build depending in the USE flags.
- if ! use berkdb ; then
- modules="${modules},dbm"
- fi
- if ! use gdbm ; then
- modules="${modules},gdbm"
- fi
- if ! use ssl ; then
- modules="${modules},openssl"
- fi
- if ! use tk ; then
- modules="${modules},tk"
- fi
-
- # Provide an empty LIBPATHENV because we disable rpath but we do not
- # need LD_LIBRARY_PATH by default since that breaks USE=multitarget
- # #564272
- INSTALL="${EPREFIX}/usr/bin/install -c" LIBPATHENV="" econf \
- --program-suffix=${MY_SUFFIX} \
- --with-soname=ruby${MY_SUFFIX} \
- --enable-shared \
- --enable-pthread \
- --disable-rpath \
- --with-out-ext="${modules}" \
- $(use_with jemalloc jemalloc) \
- $(use_enable jit jit-support ) \
- $(use_enable socks5 socks) \
- $(use_enable doc install-doc) \
- --enable-ipv6 \
- $(use_enable static-libs static) \
- $(use_enable static-libs install-static-library) \
- $(use_with static-libs static-linked-ext) \
- $(use_enable debug) \
- ${myconf} \
- --enable-option-checking=no
-
- # Makefile is broken because it lacks -ldl
- rm -rf ext/-test-/popen_deadlock || die
-}
-
-src_compile() {
- emake V=1 EXTLDFLAGS="${LDFLAGS}" MJIT_CFLAGS="${CFLAGS}" MJIT_OPTFLAGS="" MJIT_DEBUGFLAGS=""
-}
-
-src_test() {
- emake -j1 V=1 test
-
- elog "Ruby's make test has been run. Ruby also ships with a make check"
- elog "that cannot be run until after ruby has been installed."
- elog
- if use rubytests; then
- elog "You have enabled rubytests, so they will be installed to"
- elog "/usr/share/${PN}-${SLOT}/test. To run them you must be a user other"
- elog "than root, and you must place them into a writeable directory."
- elog "Then call: "
- elog
- elog "ruby${MY_SUFFIX} -C /location/of/tests runner.rb"
- else
- elog "Enable the rubytests USE flag to install the make check tests"
- fi
-}
-
-src_install() {
- # Remove the remaining bundled gems. We do this late in the process
- # since they are used during the build to e.g. create the
- # documentation.
- rm -rf ext/json || die
- rm -rf lib/bundler* lib/rdoc/rdoc.gemspec || die
-
- # Ruby is involved in the install process, we don't want interference here.
- unset RUBYOPT
-
- local MINIRUBY=$(echo -e 'include Makefile\ngetminiruby:\n\t@echo $(MINIRUBY)'|make -f - getminiruby)
-
- LD_LIBRARY_PATH="${S}:${ED}/usr/$(get_libdir)${LD_LIBRARY_PATH+:}${LD_LIBRARY_PATH}"
- RUBYLIB="${S}:${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"
- for d in $(find "${S}/ext" -type d) ; do
- RUBYLIB="${RUBYLIB}:$d"
- done
- export LD_LIBRARY_PATH RUBYLIB
-
- # Create directory for the default gems
- local gem_home="${EPREFIX}/usr/$(get_libdir)/ruby/gems/${RUBYVERSION}"
- mkdir -p "${D}/${gem_home}" || die "mkdir gem home failed"
-
- emake V=1 DESTDIR="${D}" GEM_DESTDIR=${gem_home} install
-
- # Remove installed rubygems and rdoc copy
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}/rubygems" || die "rm rubygems failed"
- rm -rf "${ED}/usr/bin/"gem"${MY_SUFFIX}" || die "rm rdoc bins failed"
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"/rdoc* || die "rm rdoc failed"
- rm -rf "${ED}/usr/bin/"{bundle,bundler,ri,rdoc}"${MY_SUFFIX}" || die "rm rdoc bins failed"
-
- if use doc; then
- emake DESTDIR="${D}" GEM_DESTDIR=${gem_home} install-doc
- fi
-
- if use examples; then
- dodoc -r sample
- fi
-
- dodoc ChangeLog NEWS doc/NEWS* README*
-
- if use rubytests; then
- pushd test
- insinto /usr/share/${PN}-${SLOT}/test
- doins -r .
- popd
- fi
-}
-
-pkg_postinst() {
- if [[ ! -n $(readlink "${EROOT}"/usr/bin/ruby) ]] ; then
- eselect ruby set ruby${MY_SUFFIX}
- fi
-
- elog
- elog "To switch between available Ruby profiles, execute as root:"
- elog "\teselect ruby set ruby(23|24|...)"
- elog
-}
-
-pkg_postrm() {
- eselect ruby cleanup
-}
diff --git a/dev-lang/ruby/ruby-2.6.6.ebuild b/dev-lang/ruby/ruby-2.6.6.ebuild
deleted file mode 100644
index e7c55656994f..000000000000
--- a/dev-lang/ruby/ruby-2.6.6.ebuild
+++ /dev/null
@@ -1,232 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools flag-o-matic multilib
-
-MY_P="${PN}-$(ver_cut 1-3)"
-S=${WORKDIR}/${MY_P}
-
-SLOT=$(ver_cut 1-2)
-MY_SUFFIX=$(ver_rs 1 '' ${SLOT})
-RUBYVERSION=${SLOT}.0
-
-DESCRIPTION="An object-oriented scripting language"
-HOMEPAGE="https://www.ruby-lang.org/"
-SRC_URI="https://cache.ruby-lang.org/pub/ruby/${SLOT}/${MY_P}.tar.xz"
-
-LICENSE="|| ( Ruby-BSD BSD-2 )"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
-IUSE="berkdb debug doc examples gdbm ipv6 jemalloc jit libressl +rdoc rubytests socks5 +ssl static-libs tk xemacs"
-
-RDEPEND="
- berkdb? ( sys-libs/db:= )
- gdbm? ( sys-libs/gdbm:= )
- jemalloc? ( dev-libs/jemalloc )
- jit? ( || ( sys-devel/gcc:* sys-devel/clang:* ) )
- ssl? (
- !libressl? ( dev-libs/openssl:0= )
- libressl? ( dev-libs/libressl )
- )
- socks5? ( >=net-proxy/dante-1.1.13 )
- tk? (
- dev-lang/tcl:0=[threads]
- dev-lang/tk:0=[threads]
- )
- dev-libs/libyaml
- dev-libs/libffi:=
- sys-libs/readline:0=
- sys-libs/zlib
- >=app-eselect/eselect-ruby-20171225
-"
-
-DEPEND="${RDEPEND}"
-
-BUNDLED_GEMS="
- >=dev-ruby/did_you_mean-1.2.1[ruby_targets_ruby26]
- >=dev-ruby/minitest-5.11.3[ruby_targets_ruby26]
- >=dev-ruby/net-telnet-0.2.0[ruby_targets_ruby26]
- >=dev-ruby/power_assert-1.1.3[ruby_targets_ruby26]
- >=dev-ruby/rake-12.3.2[ruby_targets_ruby26]
- >=dev-ruby/test-unit-3.2.9[ruby_targets_ruby26]
- >=dev-ruby/xmlrpc-0.3.0[ruby_targets_ruby26]
-"
-
-PDEPEND="
- ${BUNDLED_GEMS}
- virtual/rubygems[ruby_targets_ruby26]
- >=dev-ruby/bundler-1.17.2[ruby_targets_ruby26]
- >=dev-ruby/json-2.0.2[ruby_targets_ruby26]
- rdoc? ( >=dev-ruby/rdoc-6.1.2[ruby_targets_ruby26] )
- xemacs? ( app-xemacs/ruby-modes )"
-
-src_prepare() {
- # 005 does not compile bigdecimal and is questionable because it
- # compiles ruby in a non-standard way, may be dropped
- eapply "${FILESDIR}"/2.6/010*.patch
-
- einfo "Unbundling gems..."
- cd "$S"
- # Remove bundled gems that we will install via PDEPEND, bug
- # 539700.
- rm -fr gems/* || die
-
- einfo "Removing bundled libraries..."
- rm -fr ext/fiddle/libffi-3.2.1 || die
-
- eapply_user
-
- eautoreconf
-}
-
-src_configure() {
- local modules= myconf=
-
- # -fomit-frame-pointer makes ruby segfault, see bug #150413.
- filter-flags -fomit-frame-pointer
- # In many places aliasing rules are broken; play it safe
- # as it's risky with newer compilers to leave it as it is.
- append-flags -fno-strict-aliasing
-
- # Socks support via dante
- if use socks5 ; then
- # Socks support can't be disabled as long as SOCKS_SERVER is
- # set and socks library is present, so need to unset
- # SOCKS_SERVER in that case.
- unset SOCKS_SERVER
- fi
-
- # Increase GC_MALLOC_LIMIT if set (default is 8000000)
- if [ -n "${RUBY_GC_MALLOC_LIMIT}" ] ; then
- append-flags "-DGC_MALLOC_LIMIT=${RUBY_GC_MALLOC_LIMIT}"
- fi
-
- # ipv6 hack, bug 168939. Needs --enable-ipv6.
- use ipv6 || myconf="${myconf} --with-lookup-order-hack=INET"
-
- # Determine which modules *not* to build depending in the USE flags.
- if ! use berkdb ; then
- modules="${modules},dbm"
- fi
- if ! use gdbm ; then
- modules="${modules},gdbm"
- fi
- if ! use ssl ; then
- modules="${modules},openssl"
- fi
- if ! use tk ; then
- modules="${modules},tk"
- fi
-
- # Provide an empty LIBPATHENV because we disable rpath but we do not
- # need LD_LIBRARY_PATH by default since that breaks USE=multitarget
- # #564272
- INSTALL="${EPREFIX}/usr/bin/install -c" LIBPATHENV="" econf \
- --program-suffix=${MY_SUFFIX} \
- --with-soname=ruby${MY_SUFFIX} \
- --enable-shared \
- --enable-pthread \
- --disable-rpath \
- --with-out-ext="${modules}" \
- $(use_with jemalloc jemalloc) \
- $(use_enable jit jit-support ) \
- $(use_enable socks5 socks) \
- $(use_enable doc install-doc) \
- --enable-ipv6 \
- $(use_enable static-libs static) \
- $(use_enable static-libs install-static-library) \
- $(use_with static-libs static-linked-ext) \
- $(use_enable debug) \
- ${myconf} \
- --enable-option-checking=no
-
- # Makefile is broken because it lacks -ldl
- rm -rf ext/-test-/popen_deadlock || die
-}
-
-src_compile() {
- emake V=1 EXTLDFLAGS="${LDFLAGS}" MJIT_CFLAGS="${CFLAGS}" MJIT_OPTFLAGS="" MJIT_DEBUGFLAGS=""
-}
-
-src_test() {
- emake -j1 V=1 test
-
- elog "Ruby's make test has been run. Ruby also ships with a make check"
- elog "that cannot be run until after ruby has been installed."
- elog
- if use rubytests; then
- elog "You have enabled rubytests, so they will be installed to"
- elog "/usr/share/${PN}-${SLOT}/test. To run them you must be a user other"
- elog "than root, and you must place them into a writeable directory."
- elog "Then call: "
- elog
- elog "ruby${MY_SUFFIX} -C /location/of/tests runner.rb"
- else
- elog "Enable the rubytests USE flag to install the make check tests"
- fi
-}
-
-src_install() {
- # Remove the remaining bundled gems. We do this late in the process
- # since they are used during the build to e.g. create the
- # documentation.
- rm -rf ext/json || die
- rm -rf lib/bundler* lib/rdoc/rdoc.gemspec || die
-
- # Ruby is involved in the install process, we don't want interference here.
- unset RUBYOPT
-
- local MINIRUBY=$(echo -e 'include Makefile\ngetminiruby:\n\t@echo $(MINIRUBY)'|make -f - getminiruby)
-
- LD_LIBRARY_PATH="${S}:${ED}/usr/$(get_libdir)${LD_LIBRARY_PATH+:}${LD_LIBRARY_PATH}"
- RUBYLIB="${S}:${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"
- for d in $(find "${S}/ext" -type d) ; do
- RUBYLIB="${RUBYLIB}:$d"
- done
- export LD_LIBRARY_PATH RUBYLIB
-
- # Create directory for the default gems
- local gem_home="${EPREFIX}/usr/$(get_libdir)/ruby/gems/${RUBYVERSION}"
- mkdir -p "${D}/${gem_home}" || die "mkdir gem home failed"
-
- emake V=1 DESTDIR="${D}" GEM_DESTDIR=${gem_home} install
-
- # Remove installed rubygems and rdoc copy
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}/rubygems" || die "rm rubygems failed"
- rm -rf "${ED}/usr/bin/"gem"${MY_SUFFIX}" || die "rm rdoc bins failed"
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"/rdoc* || die "rm rdoc failed"
- rm -rf "${ED}/usr/bin/"{bundle,bundler,ri,rdoc}"${MY_SUFFIX}" || die "rm rdoc bins failed"
-
- if use doc; then
- emake DESTDIR="${D}" GEM_DESTDIR=${gem_home} install-doc
- fi
-
- if use examples; then
- dodoc -r sample
- fi
-
- dodoc ChangeLog NEWS doc/NEWS* README*
-
- if use rubytests; then
- pushd test
- insinto /usr/share/${PN}-${SLOT}/test
- doins -r .
- popd
- fi
-}
-
-pkg_postinst() {
- if [[ ! -n $(readlink "${EROOT}"/usr/bin/ruby) ]] ; then
- eselect ruby set ruby${MY_SUFFIX}
- fi
-
- elog
- elog "To switch between available Ruby profiles, execute as root:"
- elog "\teselect ruby set ruby(23|24|...)"
- elog
-}
-
-pkg_postrm() {
- eselect ruby cleanup
-}
diff --git a/dev-lang/ruby/ruby-2.7.1-r1.ebuild b/dev-lang/ruby/ruby-2.7.1-r1.ebuild
deleted file mode 100644
index c1b75c35766f..000000000000
--- a/dev-lang/ruby/ruby-2.7.1-r1.ebuild
+++ /dev/null
@@ -1,235 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools flag-o-matic multilib
-
-MY_P="${PN}-$(ver_cut 1-3)"
-S=${WORKDIR}/${MY_P}
-
-SLOT=$(ver_cut 1-2)
-MY_SUFFIX=$(ver_rs 1 '' ${SLOT})
-RUBYVERSION=${SLOT}.0
-
-DESCRIPTION="An object-oriented scripting language"
-HOMEPAGE="https://www.ruby-lang.org/"
-SRC_URI="https://cache.ruby-lang.org/pub/ruby/${SLOT}/${MY_P}.tar.xz"
-
-LICENSE="|| ( Ruby-BSD BSD-2 )"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
-IUSE="berkdb debug doc examples gdbm ipv6 jemalloc jit libressl +rdoc rubytests socks5 +ssl static-libs tk xemacs"
-
-RDEPEND="
- berkdb? ( sys-libs/db:= )
- gdbm? ( sys-libs/gdbm:= )
- jemalloc? ( dev-libs/jemalloc )
- jit? ( || ( sys-devel/gcc:* sys-devel/clang:* ) )
- ssl? (
- !libressl? ( dev-libs/openssl:0= )
- libressl? ( dev-libs/libressl )
- )
- socks5? ( >=net-proxy/dante-1.1.13 )
- tk? (
- dev-lang/tcl:0=[threads]
- dev-lang/tk:0=[threads]
- )
- dev-libs/libyaml
- dev-libs/libffi:=
- sys-libs/readline:0=
- sys-libs/zlib
- >=app-eselect/eselect-ruby-20191222
-"
-
-DEPEND="${RDEPEND}"
-
-BUNDLED_GEMS="
- >=dev-ruby/minitest-5.13.0[ruby_targets_ruby27]
- >=dev-ruby/net-telnet-0.2.0[ruby_targets_ruby27]
- >=dev-ruby/power_assert-1.1.7[ruby_targets_ruby27]
- >=dev-ruby/rake-13.0.1[ruby_targets_ruby27]
- >=dev-ruby/test-unit-3.3.4[ruby_targets_ruby27]
- >=dev-ruby/xmlrpc-0.3.0[ruby_targets_ruby27]
-"
-
-PDEPEND="
- ${BUNDLED_GEMS}
- virtual/rubygems[ruby_targets_ruby27]
- >=dev-ruby/bundler-2.1.4[ruby_targets_ruby27]
- >=dev-ruby/did_you_mean-1.3.1[ruby_targets_ruby27]
- >=dev-ruby/json-2.0.2[ruby_targets_ruby27]
- rdoc? ( >=dev-ruby/rdoc-6.1.2[ruby_targets_ruby27] )
- xemacs? ( app-xemacs/ruby-modes )"
-
-src_prepare() {
- # 005 does not compile bigdecimal and is questionable because it
- # compiles ruby in a non-standard way, may be dropped
- eapply "${FILESDIR}"/2.7/010*.patch
-
- einfo "Unbundling gems..."
- cd "$S"
- # Remove bundled gems that we will install via PDEPEND, bug
- # 539700.
- rm -fr gems/* || die
- # Don't install CLI tools since they will clash with the gem
- rm -f bin/{racc,racc2y,y2racc} || die
- sed -i -e '/executables/ s:^:#:' lib/racc/racc.gemspec || die
-
- einfo "Removing bundled libraries..."
- rm -fr ext/fiddle/libffi-3.2.1 || die
-
- eapply_user
-
- eautoreconf
-}
-
-src_configure() {
- local modules= myconf=
-
- # -fomit-frame-pointer makes ruby segfault, see bug #150413.
- filter-flags -fomit-frame-pointer
- # In many places aliasing rules are broken; play it safe
- # as it's risky with newer compilers to leave it as it is.
- append-flags -fno-strict-aliasing
-
- # Socks support via dante
- if use socks5 ; then
- # Socks support can't be disabled as long as SOCKS_SERVER is
- # set and socks library is present, so need to unset
- # SOCKS_SERVER in that case.
- unset SOCKS_SERVER
- fi
-
- # Increase GC_MALLOC_LIMIT if set (default is 8000000)
- if [ -n "${RUBY_GC_MALLOC_LIMIT}" ] ; then
- append-flags "-DGC_MALLOC_LIMIT=${RUBY_GC_MALLOC_LIMIT}"
- fi
-
- # ipv6 hack, bug 168939. Needs --enable-ipv6.
- use ipv6 || myconf="${myconf} --with-lookup-order-hack=INET"
-
- # Determine which modules *not* to build depending in the USE flags.
- if ! use berkdb ; then
- modules="${modules},dbm"
- fi
- if ! use gdbm ; then
- modules="${modules},gdbm"
- fi
- if ! use ssl ; then
- modules="${modules},openssl"
- fi
- if ! use tk ; then
- modules="${modules},tk"
- fi
-
- # Provide an empty LIBPATHENV because we disable rpath but we do not
- # need LD_LIBRARY_PATH by default since that breaks USE=multitarget
- # #564272
- INSTALL="${EPREFIX}/usr/bin/install -c" LIBPATHENV="" econf \
- --program-suffix=${MY_SUFFIX} \
- --with-soname=ruby${MY_SUFFIX} \
- --enable-shared \
- --enable-pthread \
- --disable-rpath \
- --with-out-ext="${modules}" \
- $(use_with jemalloc jemalloc) \
- $(use_enable jit jit-support ) \
- $(use_enable socks5 socks) \
- $(use_enable doc install-doc) \
- --enable-ipv6 \
- $(use_enable static-libs static) \
- $(use_enable static-libs install-static-library) \
- $(use_with static-libs static-linked-ext) \
- $(use_enable debug) \
- ${myconf} \
- --enable-option-checking=no
-
- # Makefile is broken because it lacks -ldl
- rm -rf ext/-test-/popen_deadlock || die
-}
-
-src_compile() {
- emake V=1 EXTLDFLAGS="${LDFLAGS}" MJIT_CFLAGS="${CFLAGS}" MJIT_OPTFLAGS="" MJIT_DEBUGFLAGS=""
-}
-
-src_test() {
- emake -j1 V=1 test
-
- elog "Ruby's make test has been run. Ruby also ships with a make check"
- elog "that cannot be run until after ruby has been installed."
- elog
- if use rubytests; then
- elog "You have enabled rubytests, so they will be installed to"
- elog "/usr/share/${PN}-${SLOT}/test. To run them you must be a user other"
- elog "than root, and you must place them into a writeable directory."
- elog "Then call: "
- elog
- elog "ruby${MY_SUFFIX} -C /location/of/tests runner.rb"
- else
- elog "Enable the rubytests USE flag to install the make check tests"
- fi
-}
-
-src_install() {
- # Remove the remaining bundled gems. We do this late in the process
- # since they are used during the build to e.g. create the
- # documentation.
- rm -rf ext/json || die
- rm -rf lib/bundler* lib/rdoc/rdoc.gemspec || die
-
- # Ruby is involved in the install process, we don't want interference here.
- unset RUBYOPT
-
- local MINIRUBY=$(echo -e 'include Makefile\ngetminiruby:\n\t@echo $(MINIRUBY)'|make -f - getminiruby)
-
- LD_LIBRARY_PATH="${S}:${ED}/usr/$(get_libdir)${LD_LIBRARY_PATH+:}${LD_LIBRARY_PATH}"
- RUBYLIB="${S}:${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"
- for d in $(find "${S}/ext" -type d) ; do
- RUBYLIB="${RUBYLIB}:$d"
- done
- export LD_LIBRARY_PATH RUBYLIB
-
- # Create directory for the default gems
- local gem_home="${EPREFIX}/usr/$(get_libdir)/ruby/gems/${RUBYVERSION}"
- mkdir -p "${D}/${gem_home}" || die "mkdir gem home failed"
-
- emake V=1 DESTDIR="${D}" GEM_DESTDIR=${gem_home} install
-
- # Remove installed rubygems and rdoc copy
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}/rubygems" || die "rm rubygems failed"
- rm -rf "${ED}/usr/bin/"gem"${MY_SUFFIX}" || die "rm rdoc bins failed"
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"/rdoc* || die "rm rdoc failed"
- rm -rf "${ED}/usr/bin/"{bundle,bundler,ri,rdoc}"${MY_SUFFIX}" || die "rm rdoc bins failed"
-
- if use doc; then
- emake DESTDIR="${D}" GEM_DESTDIR=${gem_home} install-doc
- fi
-
- if use examples; then
- dodoc -r sample
- fi
-
- dodoc ChangeLog NEWS doc/NEWS* README*
-
- if use rubytests; then
- pushd test
- insinto /usr/share/${PN}-${SLOT}/test
- doins -r .
- popd
- fi
-}
-
-pkg_postinst() {
- if [[ ! -n $(readlink "${EROOT}"/usr/bin/ruby) ]] ; then
- eselect ruby set ruby${MY_SUFFIX}
- fi
-
- elog
- elog "To switch between available Ruby profiles, execute as root:"
- elog "\teselect ruby set ruby(23|24|...)"
- elog
-}
-
-pkg_postrm() {
- eselect ruby cleanup
-}
diff --git a/dev-lang/ruby/ruby-2.7.1-r2.ebuild b/dev-lang/ruby/ruby-2.7.1-r2.ebuild
deleted file mode 100644
index e4e8048e083a..000000000000
--- a/dev-lang/ruby/ruby-2.7.1-r2.ebuild
+++ /dev/null
@@ -1,237 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools flag-o-matic multilib
-
-MY_P="${PN}-$(ver_cut 1-3)"
-S=${WORKDIR}/${MY_P}
-
-SLOT=$(ver_cut 1-2)
-MY_SUFFIX=$(ver_rs 1 '' ${SLOT})
-RUBYVERSION=${SLOT}.0
-
-DESCRIPTION="An object-oriented scripting language"
-HOMEPAGE="https://www.ruby-lang.org/"
-SRC_URI="https://cache.ruby-lang.org/pub/ruby/${SLOT}/${MY_P}.tar.xz"
-
-LICENSE="|| ( Ruby-BSD BSD-2 )"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
-IUSE="berkdb debug doc examples gdbm ipv6 jemalloc jit libressl +rdoc rubytests socks5 +ssl static-libs systemtap tk xemacs"
-
-RDEPEND="
- berkdb? ( sys-libs/db:= )
- gdbm? ( sys-libs/gdbm:= )
- jemalloc? ( dev-libs/jemalloc )
- jit? ( || ( sys-devel/gcc:* sys-devel/clang:* ) )
- ssl? (
- !libressl? ( dev-libs/openssl:0= )
- libressl? ( dev-libs/libressl )
- )
- socks5? ( >=net-proxy/dante-1.1.13 )
- systemtap? ( dev-util/systemtap )
- tk? (
- dev-lang/tcl:0=[threads]
- dev-lang/tk:0=[threads]
- )
- dev-libs/libyaml
- dev-libs/libffi:=
- sys-libs/readline:0=
- sys-libs/zlib
- >=app-eselect/eselect-ruby-20191222
-"
-
-DEPEND="${RDEPEND}"
-
-BUNDLED_GEMS="
- >=dev-ruby/minitest-5.13.0[ruby_targets_ruby27]
- >=dev-ruby/net-telnet-0.2.0[ruby_targets_ruby27]
- >=dev-ruby/power_assert-1.1.7[ruby_targets_ruby27]
- >=dev-ruby/rake-13.0.1[ruby_targets_ruby27]
- >=dev-ruby/test-unit-3.3.4[ruby_targets_ruby27]
- >=dev-ruby/xmlrpc-0.3.0[ruby_targets_ruby27]
-"
-
-PDEPEND="
- ${BUNDLED_GEMS}
- virtual/rubygems[ruby_targets_ruby27]
- >=dev-ruby/bundler-2.1.4[ruby_targets_ruby27]
- >=dev-ruby/did_you_mean-1.3.1[ruby_targets_ruby27]
- >=dev-ruby/json-2.0.2[ruby_targets_ruby27]
- rdoc? ( >=dev-ruby/rdoc-6.1.2[ruby_targets_ruby27] )
- xemacs? ( app-xemacs/ruby-modes )"
-
-src_prepare() {
- # 005 does not compile bigdecimal and is questionable because it
- # compiles ruby in a non-standard way, may be dropped
- eapply "${FILESDIR}"/2.7/010*.patch
-
- einfo "Unbundling gems..."
- cd "$S"
- # Remove bundled gems that we will install via PDEPEND, bug
- # 539700.
- rm -fr gems/* || die
- # Don't install CLI tools since they will clash with the gem
- rm -f bin/{racc,racc2y,y2racc} || die
- sed -i -e '/executables/ s:^:#:' lib/racc/racc.gemspec || die
-
- einfo "Removing bundled libraries..."
- rm -fr ext/fiddle/libffi-3.2.1 || die
-
- eapply_user
-
- eautoreconf
-}
-
-src_configure() {
- local modules= myconf=
-
- # -fomit-frame-pointer makes ruby segfault, see bug #150413.
- filter-flags -fomit-frame-pointer
- # In many places aliasing rules are broken; play it safe
- # as it's risky with newer compilers to leave it as it is.
- append-flags -fno-strict-aliasing
-
- # Socks support via dante
- if use socks5 ; then
- # Socks support can't be disabled as long as SOCKS_SERVER is
- # set and socks library is present, so need to unset
- # SOCKS_SERVER in that case.
- unset SOCKS_SERVER
- fi
-
- # Increase GC_MALLOC_LIMIT if set (default is 8000000)
- if [ -n "${RUBY_GC_MALLOC_LIMIT}" ] ; then
- append-flags "-DGC_MALLOC_LIMIT=${RUBY_GC_MALLOC_LIMIT}"
- fi
-
- # ipv6 hack, bug 168939. Needs --enable-ipv6.
- use ipv6 || myconf="${myconf} --with-lookup-order-hack=INET"
-
- # Determine which modules *not* to build depending in the USE flags.
- if ! use berkdb ; then
- modules="${modules},dbm"
- fi
- if ! use gdbm ; then
- modules="${modules},gdbm"
- fi
- if ! use ssl ; then
- modules="${modules},openssl"
- fi
- if ! use tk ; then
- modules="${modules},tk"
- fi
-
- # Provide an empty LIBPATHENV because we disable rpath but we do not
- # need LD_LIBRARY_PATH by default since that breaks USE=multitarget
- # #564272
- INSTALL="${EPREFIX}/usr/bin/install -c" LIBPATHENV="" econf \
- --program-suffix=${MY_SUFFIX} \
- --with-soname=ruby${MY_SUFFIX} \
- --enable-shared \
- --enable-pthread \
- --disable-rpath \
- --with-out-ext="${modules}" \
- $(use_with jemalloc jemalloc) \
- $(use_enable jit jit-support ) \
- $(use_enable socks5 socks) \
- $(use_enable systemtap dtrace) \
- $(use_enable doc install-doc) \
- --enable-ipv6 \
- $(use_enable static-libs static) \
- $(use_enable static-libs install-static-library) \
- $(use_with static-libs static-linked-ext) \
- $(use_enable debug) \
- ${myconf} \
- --enable-option-checking=no
-
- # Makefile is broken because it lacks -ldl
- rm -rf ext/-test-/popen_deadlock || die
-}
-
-src_compile() {
- emake V=1 EXTLDFLAGS="${LDFLAGS}" MJIT_CFLAGS="${CFLAGS}" MJIT_OPTFLAGS="" MJIT_DEBUGFLAGS=""
-}
-
-src_test() {
- emake -j1 V=1 test
-
- elog "Ruby's make test has been run. Ruby also ships with a make check"
- elog "that cannot be run until after ruby has been installed."
- elog
- if use rubytests; then
- elog "You have enabled rubytests, so they will be installed to"
- elog "/usr/share/${PN}-${SLOT}/test. To run them you must be a user other"
- elog "than root, and you must place them into a writeable directory."
- elog "Then call: "
- elog
- elog "ruby${MY_SUFFIX} -C /location/of/tests runner.rb"
- else
- elog "Enable the rubytests USE flag to install the make check tests"
- fi
-}
-
-src_install() {
- # Remove the remaining bundled gems. We do this late in the process
- # since they are used during the build to e.g. create the
- # documentation.
- rm -rf ext/json || die
- rm -rf lib/bundler* lib/rdoc/rdoc.gemspec || die
-
- # Ruby is involved in the install process, we don't want interference here.
- unset RUBYOPT
-
- local MINIRUBY=$(echo -e 'include Makefile\ngetminiruby:\n\t@echo $(MINIRUBY)'|make -f - getminiruby)
-
- LD_LIBRARY_PATH="${S}:${ED}/usr/$(get_libdir)${LD_LIBRARY_PATH+:}${LD_LIBRARY_PATH}"
- RUBYLIB="${S}:${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"
- for d in $(find "${S}/ext" -type d) ; do
- RUBYLIB="${RUBYLIB}:$d"
- done
- export LD_LIBRARY_PATH RUBYLIB
-
- # Create directory for the default gems
- local gem_home="${EPREFIX}/usr/$(get_libdir)/ruby/gems/${RUBYVERSION}"
- mkdir -p "${D}/${gem_home}" || die "mkdir gem home failed"
-
- emake V=1 DESTDIR="${D}" GEM_DESTDIR=${gem_home} install
-
- # Remove installed rubygems and rdoc copy
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}/rubygems" || die "rm rubygems failed"
- rm -rf "${ED}/usr/bin/"gem"${MY_SUFFIX}" || die "rm rdoc bins failed"
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"/rdoc* || die "rm rdoc failed"
- rm -rf "${ED}/usr/bin/"{bundle,bundler,ri,rdoc}"${MY_SUFFIX}" || die "rm rdoc bins failed"
-
- if use doc; then
- emake DESTDIR="${D}" GEM_DESTDIR=${gem_home} install-doc
- fi
-
- if use examples; then
- dodoc -r sample
- fi
-
- dodoc ChangeLog NEWS doc/NEWS* README*
-
- if use rubytests; then
- pushd test
- insinto /usr/share/${PN}-${SLOT}/test
- doins -r .
- popd
- fi
-}
-
-pkg_postinst() {
- if [[ ! -n $(readlink "${EROOT}"/usr/bin/ruby) ]] ; then
- eselect ruby set ruby${MY_SUFFIX}
- fi
-
- elog
- elog "To switch between available Ruby profiles, execute as root:"
- elog "\teselect ruby set ruby(23|24|...)"
- elog
-}
-
-pkg_postrm() {
- eselect ruby cleanup
-}
diff --git a/dev-lang/ruby/ruby-2.7.1.ebuild b/dev-lang/ruby/ruby-2.7.1.ebuild
deleted file mode 100644
index 49b0ce2ee2e1..000000000000
--- a/dev-lang/ruby/ruby-2.7.1.ebuild
+++ /dev/null
@@ -1,235 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools flag-o-matic multilib
-
-MY_P="${PN}-$(ver_cut 1-3)"
-S=${WORKDIR}/${MY_P}
-
-SLOT=$(ver_cut 1-2)
-MY_SUFFIX=$(ver_rs 1 '' ${SLOT})
-RUBYVERSION=${SLOT}.0
-
-DESCRIPTION="An object-oriented scripting language"
-HOMEPAGE="https://www.ruby-lang.org/"
-SRC_URI="https://cache.ruby-lang.org/pub/ruby/${SLOT}/${MY_P}.tar.xz"
-
-LICENSE="|| ( Ruby-BSD BSD-2 )"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
-IUSE="berkdb debug doc examples gdbm ipv6 jemalloc jit libressl +rdoc rubytests socks5 +ssl static-libs tk xemacs"
-
-RDEPEND="
- berkdb? ( sys-libs/db:= )
- gdbm? ( sys-libs/gdbm:= )
- jemalloc? ( dev-libs/jemalloc )
- jit? ( || ( sys-devel/gcc:* sys-devel/clang:* ) )
- ssl? (
- !libressl? ( dev-libs/openssl:0= )
- libressl? ( dev-libs/libressl )
- )
- socks5? ( >=net-proxy/dante-1.1.13 )
- tk? (
- dev-lang/tcl:0=[threads]
- dev-lang/tk:0=[threads]
- )
- dev-libs/libyaml
- dev-libs/libffi:=
- sys-libs/readline:0=
- sys-libs/zlib
- >=app-eselect/eselect-ruby-20171225
-"
-
-DEPEND="${RDEPEND}"
-
-BUNDLED_GEMS="
- >=dev-ruby/minitest-5.13.0[ruby_targets_ruby27]
- >=dev-ruby/net-telnet-0.2.0[ruby_targets_ruby27]
- >=dev-ruby/power_assert-1.1.7[ruby_targets_ruby27]
- >=dev-ruby/rake-13.0.1[ruby_targets_ruby27]
- >=dev-ruby/test-unit-3.3.4[ruby_targets_ruby27]
- >=dev-ruby/xmlrpc-0.3.0[ruby_targets_ruby27]
-"
-
-PDEPEND="
- ${BUNDLED_GEMS}
- virtual/rubygems[ruby_targets_ruby27]
- >=dev-ruby/bundler-2.1.4[ruby_targets_ruby27]
- >=dev-ruby/did_you_mean-1.3.1[ruby_targets_ruby27]
- >=dev-ruby/json-2.0.2[ruby_targets_ruby27]
- rdoc? ( >=dev-ruby/rdoc-6.1.2[ruby_targets_ruby27] )
- xemacs? ( app-xemacs/ruby-modes )"
-
-src_prepare() {
- # 005 does not compile bigdecimal and is questionable because it
- # compiles ruby in a non-standard way, may be dropped
- eapply "${FILESDIR}"/2.7/010*.patch
-
- einfo "Unbundling gems..."
- cd "$S"
- # Remove bundled gems that we will install via PDEPEND, bug
- # 539700.
- rm -fr gems/* || die
- # Don't install CLI tools since they will clash with the gem
- rm -f bin/{racc,racc2y,y2racc} || die
- sed -i -e '/executables/ s:^:#:' lib/racc/racc.gemspec || die
-
- einfo "Removing bundled libraries..."
- rm -fr ext/fiddle/libffi-3.2.1 || die
-
- eapply_user
-
- eautoreconf
-}
-
-src_configure() {
- local modules= myconf=
-
- # -fomit-frame-pointer makes ruby segfault, see bug #150413.
- filter-flags -fomit-frame-pointer
- # In many places aliasing rules are broken; play it safe
- # as it's risky with newer compilers to leave it as it is.
- append-flags -fno-strict-aliasing
-
- # Socks support via dante
- if use socks5 ; then
- # Socks support can't be disabled as long as SOCKS_SERVER is
- # set and socks library is present, so need to unset
- # SOCKS_SERVER in that case.
- unset SOCKS_SERVER
- fi
-
- # Increase GC_MALLOC_LIMIT if set (default is 8000000)
- if [ -n "${RUBY_GC_MALLOC_LIMIT}" ] ; then
- append-flags "-DGC_MALLOC_LIMIT=${RUBY_GC_MALLOC_LIMIT}"
- fi
-
- # ipv6 hack, bug 168939. Needs --enable-ipv6.
- use ipv6 || myconf="${myconf} --with-lookup-order-hack=INET"
-
- # Determine which modules *not* to build depending in the USE flags.
- if ! use berkdb ; then
- modules="${modules},dbm"
- fi
- if ! use gdbm ; then
- modules="${modules},gdbm"
- fi
- if ! use ssl ; then
- modules="${modules},openssl"
- fi
- if ! use tk ; then
- modules="${modules},tk"
- fi
-
- # Provide an empty LIBPATHENV because we disable rpath but we do not
- # need LD_LIBRARY_PATH by default since that breaks USE=multitarget
- # #564272
- INSTALL="${EPREFIX}/usr/bin/install -c" LIBPATHENV="" econf \
- --program-suffix=${MY_SUFFIX} \
- --with-soname=ruby${MY_SUFFIX} \
- --enable-shared \
- --enable-pthread \
- --disable-rpath \
- --with-out-ext="${modules}" \
- $(use_with jemalloc jemalloc) \
- $(use_enable jit jit-support ) \
- $(use_enable socks5 socks) \
- $(use_enable doc install-doc) \
- --enable-ipv6 \
- $(use_enable static-libs static) \
- $(use_enable static-libs install-static-library) \
- $(use_with static-libs static-linked-ext) \
- $(use_enable debug) \
- ${myconf} \
- --enable-option-checking=no
-
- # Makefile is broken because it lacks -ldl
- rm -rf ext/-test-/popen_deadlock || die
-}
-
-src_compile() {
- emake V=1 EXTLDFLAGS="${LDFLAGS}" MJIT_CFLAGS="${CFLAGS}" MJIT_OPTFLAGS="" MJIT_DEBUGFLAGS=""
-}
-
-src_test() {
- emake -j1 V=1 test
-
- elog "Ruby's make test has been run. Ruby also ships with a make check"
- elog "that cannot be run until after ruby has been installed."
- elog
- if use rubytests; then
- elog "You have enabled rubytests, so they will be installed to"
- elog "/usr/share/${PN}-${SLOT}/test. To run them you must be a user other"
- elog "than root, and you must place them into a writeable directory."
- elog "Then call: "
- elog
- elog "ruby${MY_SUFFIX} -C /location/of/tests runner.rb"
- else
- elog "Enable the rubytests USE flag to install the make check tests"
- fi
-}
-
-src_install() {
- # Remove the remaining bundled gems. We do this late in the process
- # since they are used during the build to e.g. create the
- # documentation.
- rm -rf ext/json || die
- rm -rf lib/bundler* lib/rdoc/rdoc.gemspec || die
-
- # Ruby is involved in the install process, we don't want interference here.
- unset RUBYOPT
-
- local MINIRUBY=$(echo -e 'include Makefile\ngetminiruby:\n\t@echo $(MINIRUBY)'|make -f - getminiruby)
-
- LD_LIBRARY_PATH="${S}:${ED}/usr/$(get_libdir)${LD_LIBRARY_PATH+:}${LD_LIBRARY_PATH}"
- RUBYLIB="${S}:${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"
- for d in $(find "${S}/ext" -type d) ; do
- RUBYLIB="${RUBYLIB}:$d"
- done
- export LD_LIBRARY_PATH RUBYLIB
-
- # Create directory for the default gems
- local gem_home="${EPREFIX}/usr/$(get_libdir)/ruby/gems/${RUBYVERSION}"
- mkdir -p "${D}/${gem_home}" || die "mkdir gem home failed"
-
- emake V=1 DESTDIR="${D}" GEM_DESTDIR=${gem_home} install
-
- # Remove installed rubygems and rdoc copy
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}/rubygems" || die "rm rubygems failed"
- rm -rf "${ED}/usr/bin/"gem"${MY_SUFFIX}" || die "rm rdoc bins failed"
- rm -rf "${ED}/usr/$(get_libdir)/ruby/${RUBYVERSION}"/rdoc* || die "rm rdoc failed"
- rm -rf "${ED}/usr/bin/"{bundle,bundler,ri,rdoc}"${MY_SUFFIX}" || die "rm rdoc bins failed"
-
- if use doc; then
- emake DESTDIR="${D}" GEM_DESTDIR=${gem_home} install-doc
- fi
-
- if use examples; then
- dodoc -r sample
- fi
-
- dodoc ChangeLog NEWS doc/NEWS* README*
-
- if use rubytests; then
- pushd test
- insinto /usr/share/${PN}-${SLOT}/test
- doins -r .
- popd
- fi
-}
-
-pkg_postinst() {
- if [[ ! -n $(readlink "${EROOT}"/usr/bin/ruby) ]] ; then
- eselect ruby set ruby${MY_SUFFIX}
- fi
-
- elog
- elog "To switch between available Ruby profiles, execute as root:"
- elog "\teselect ruby set ruby(23|24|...)"
- elog
-}
-
-pkg_postrm() {
- eselect ruby cleanup
-}