From 40aaaa64e86ba6710bbeb31c4615a6ce80e75e11 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Wed, 28 Apr 2021 20:21:43 +0100 Subject: gentoo resync : 28.04.2021 --- dev-lua/luarocks/Manifest | 2 + dev-lua/luarocks/luarocks-3.7.0.ebuild | 87 ++++++++++++++++++++++++++++++++++ 2 files changed, 89 insertions(+) create mode 100644 dev-lua/luarocks/luarocks-3.7.0.ebuild (limited to 'dev-lua/luarocks') diff --git a/dev-lua/luarocks/Manifest b/dev-lua/luarocks/Manifest index 59cb15f40ce6..8e79700995a6 100644 --- a/dev-lua/luarocks/Manifest +++ b/dev-lua/luarocks/Manifest @@ -1,3 +1,5 @@ DIST luarocks-3.5.0.tar.gz 244798 BLAKE2B 24ceead8953ad6d9eefbf471fd49e0bd82256cc00c201395770919a680873544db67f062a4af93ddd390985b0b74db55e37a95516287dfc1e077a25b67c9f264 SHA512 fda01b7149839adf7c0e1c05d0f1793e79575c5d378d96ee1e197828e9b9b6e89a635f8a26a5b71db5b48465ef74b219fac18ecdbd59962cbf9da613b05dd42a +DIST luarocks-3.7.0.tar.gz 247576 BLAKE2B b1e119ec897bc8122441445dc215e628d2415dacba9b23c2b075f82a01e21e6e9a8eeab5a3345355d85c566ff9f85ab29194580674521d4d92725b01377ee940 SHA512 cc3c555c488da9f95a118eedb74cb9e2a38b572e172958843dabebce125524e58a13ac65e89a349deb8fef13b6de751074fc3adbb430ab55d4e4109288119153 EBUILD luarocks-3.5.0.ebuild 2072 BLAKE2B 19a562fa571b46b31090b135c93d62d9bf9ccdd430c667bba128677df6426c96c449e6fb08e0aefc8ae2bd6c949236bf33f2bec3d72e5762bd59def3695ce92b SHA512 71b1d213e0d882118500761bced293d4c0759e8649134e60af7bc4b462af9fc1c1456c784d3377f70a3929234fed834489cbfd18c0e8fa38d60333b896d0328e +EBUILD luarocks-3.7.0.ebuild 2095 BLAKE2B 466f0ea629952a62b1dd2c26ebc4775acc7998c755847930ef3a90bc37816891347b1691f7639a1be8a4a8edcd1be8633b10d589cc39e91084318508ef10df7a SHA512 84f24a1f274e09f679c77bce50cd0576445c597a0d23c912839e1af92a0a6d0bfb2bd3279d1a84656feeb815ba0d7cad02ca93646d92f680aee5e3528a89d416 MISC metadata.xml 738 BLAKE2B 49367ad6b9fda430056e09e411ace950195c9121d9eed448cb8420bca760d2311952f5633e7703e4e400544457d0ceb53155d8ce0da9283c0d225caf10ed4b1a SHA512 563e37aaaebac1d2552ae017917d9fa567694144985d01f5f726b48d338b1a2f75ad1ddea8c9972bd3b1731e5cf295ce1206a54c6c41e213f14993958ffe487a diff --git a/dev-lua/luarocks/luarocks-3.7.0.ebuild b/dev-lua/luarocks/luarocks-3.7.0.ebuild new file mode 100644 index 000000000000..7a8d87f5908f --- /dev/null +++ b/dev-lua/luarocks/luarocks-3.7.0.ebuild @@ -0,0 +1,87 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +LUA_COMPAT=( lua5-{1..4} luajit ) + +inherit lua-single + +DESCRIPTION="A package manager for the Lua programming language" +HOMEPAGE="https://luarocks.org" +SRC_URI="https://luarocks.org/releases/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86" +IUSE="libressl test" +REQUIRED_USE="${LUA_REQUIRED_USE}" +RESTRICT="test" + +RDEPEND="${LUA_DEPS}" + +DEPEND=" + net-misc/curl + libressl? ( dev-libs/libressl:0 ) + !libressl? ( dev-libs/openssl:0 ) + ${RDEPEND} +" + +BDEPEND=" + virtual/pkgconfig + test? ( + $(lua_gen_cond_dep 'dev-lua/busted[${LUA_USEDEP}]') + $(lua_gen_cond_dep 'dev-lua/busted-htest[${LUA_USEDEP}]') + ${RDEPEND} + ) +" + +src_prepare() { + default + + # If 'dev-lang/lua' is a new, fresh installation, no 'LUA_LIBDIR' exists, + # as no compiled modules are installed on a new, fresh installation, + # so this check must be disabled, otherwise 'configure' will fail. + sed -e '/LUA_LIBDIR is not a valid directory/d' -i configure || die +} + +src_configure() { + local myeconfargs=( + "--prefix=${EPREFIX}/usr" + "--rocks-tree=$(lua_get_lmod_dir)" + "--with-lua-include=$(lua_get_include_dir)" + "--with-lua-interpreter=${ELUA}" + "--with-lua-lib=$(lua_get_cmod_dir)" + ) + + # Since the configure script is handcrafted, + # and yells at unknown options, do not use 'econf'. + ./configure "${myeconfargs[@]}" || die +} + +src_test() { + busted --lua=${ELUA} || die +} + +src_install() { + default + + { find "${D}" -type f -exec sed -i -e "s:${D}::g" {} \;; } || die +} + +pkg_postinst() { + local lua_abi_ver + if use lua_single_target_luajit; then + lua_abi_ver="5.1" + else + lua_abi_ver=${ELUA#lua} + fi + elog + elog "To manage rocks for a Lua version other than the current ${CATEGORY}/${PN} default (${lua_abi_ver})" + elog "you can use the command-line option --lua-version, e.g." + elog + elog " luarocks --lua-version 5.3 install luasocket" + elog + elog "(use 5.1 for luajit). Note that the relevant Lua version must already be present in the system." + elog +} -- cgit v1.2.3