diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
commit | 8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch) | |
tree | 7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-lua/luarocks/luarocks-2.2.0.ebuild | |
parent | 30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff) |
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-lua/luarocks/luarocks-2.2.0.ebuild')
-rw-r--r-- | dev-lua/luarocks/luarocks-2.2.0.ebuild | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/dev-lua/luarocks/luarocks-2.2.0.ebuild b/dev-lua/luarocks/luarocks-2.2.0.ebuild new file mode 100644 index 000000000000..a64514f182e2 --- /dev/null +++ b/dev-lua/luarocks/luarocks-2.2.0.ebuild @@ -0,0 +1,52 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 + +inherit eutils multilib + +DESCRIPTION="A deployment and management system for Lua modules" +HOMEPAGE="http://www.luarocks.org" +SRC_URI="http://luarocks.org/releases/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="amd64 ~ppc x86" +IUSE="curl openssl" + +DEPEND="dev-lang/lua + curl? ( net-misc/curl ) + openssl? ( dev-libs/openssl )" +RDEPEND="${DEPEND} + app-arch/unzip" + +src_configure() { + USE_MD5="md5sum" + USE_FETCH="wget" + use openssl && USE_MD5="openssl" + use curl && USE_FETCH="curl" + + # econf doesn't work b/c it passes variables the custom configure can't + # handle + ./configure \ + --prefix=/usr \ + --with-lua-lib=/usr/$(get_libdir) \ + --rocks-tree=/usr/$(get_libdir)/lua/luarocks \ + --with-downloader=$USE_FETCH \ + --with-md5-checker=$USE_MD5 \ + || die "configure failed" +} + +src_compile() { + # -j1 b/c make tries to delete files it has yet to create (bug #402005) + emake DESTDIR="${D}" -j1 || die "make failed" +} + +src_install() { + # -j1 b/c otherwise it fails to find src/bin/luarocks + emake DESTDIR="${D}" -j1 install || die "einstall" +} + +pkg_preinst() { + find "${D}" -type f | xargs sed -i -e "s:${D}::g" || die "sed failed" +} |