public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Conrad Kostecki" <conikost@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lua/lua-bit32/
Date: Mon, 16 Nov 2020 17:31:44 +0000 (UTC)	[thread overview]
Message-ID: <1605547772.4b5eadf238bca4d1aa983578457d7d15317f1a7b.conikost@gentoo> (raw)

commit:     4b5eadf238bca4d1aa983578457d7d15317f1a7b
Author:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 16 17:27:59 2020 +0000
Commit:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
CommitDate: Mon Nov 16 17:29:32 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4b5eadf2

dev-lua/lua-bit32: use correct lua version

The previous revision used wrongly the system enabled lua instead of the
LUA_TARGETS. The change now uses always the correct LUA.

Also updated LUA_CPATH to use for each LUA version the correct *.so
file.

Closes: https://bugs.gentoo.org/752615
Package-Manager: Portage-3.0.9, Repoman-3.0.2
Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org>

 dev-lua/lua-bit32/lua-bit32-5.3.5-r101.ebuild | 75 +++++++++++++++++++++++++++
 1 file changed, 75 insertions(+)

diff --git a/dev-lua/lua-bit32/lua-bit32-5.3.5-r101.ebuild b/dev-lua/lua-bit32/lua-bit32-5.3.5-r101.ebuild
new file mode 100644
index 00000000000..6bb9594da9c
--- /dev/null
+++ b/dev-lua/lua-bit32/lua-bit32-5.3.5-r101.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+LUA_COMPAT=( lua5-1 luajit )
+
+MY_PN="lua-compat-5.3"
+MY_PV="0.10"
+
+inherit lua toolchain-funcs
+
+DESCRIPTION="Backported Lua bit manipulation library"
+HOMEPAGE="https://github.com/keplerproject/lua-compat-5.3"
+SRC_URI="https://github.com/keplerproject/${MY_PN}/archive/v${MY_PV}.tar.gz -> lua-compat53-${MY_PV}.tar.gz"
+S="${WORKDIR}/${MY_PN}-${MY_PV}"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="test"
+REQUIRED_USE="${LUA_REQUIRED_USE}"
+RESTRICT="!test? ( test )"
+
+DEPEND="${LUA_DEPS}"
+RDEPEND="${DEPEND}"
+
+lua_src_compile() {
+	local compiler=(
+		"$(tc-getCC)"
+		"${CFLAGS}"
+		"-fPIC"
+		"${LDFLAGS}"
+		"-DLUA_COMPAT_BITLIB"
+		"-Ic-api"
+		"$(lua_get_CFLAGS)"
+		"-c lbitlib.c"
+		"-o lbitlib-${ELUA}.o"
+	)
+	einfo "${compiler[@]}"
+	${compiler[@]} || die
+
+	local linker=(
+		"$(tc-getCC)"
+		"-shared"
+		"${LDFLAGS}"
+		"-o bit32-${ELUA}.so"
+		"lbitlib-${ELUA}.o"
+	)
+	einfo "${linker[@]}"
+	${linker[@]} || die
+}
+
+src_compile() {
+	lua_foreach_impl lua_src_compile
+}
+
+lua_src_test() {
+	LUA_CPATH="./bit32-${ELUA}.so" "${ELUA}" "tests/test-bit32.lua" || die
+}
+
+src_test() {
+	lua_foreach_impl lua_src_test
+}
+
+lua_src_install() {
+	exeinto "$(lua_get_cmod_dir)"
+	newexe "bit32-${ELUA}.so" "bit32.so"
+}
+
+src_install() {
+	default
+
+	lua_foreach_impl lua_src_install
+}


             reply	other threads:[~2020-11-16 17:31 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-16 17:31 Conrad Kostecki [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-04-21  8:25 [gentoo-commits] repo/gentoo:master commit in: dev-lua/lua-bit32/ Joonas Niilola
2022-07-22  7:31 James Le Cuirot
2021-04-21 20:29 Conrad Kostecki
2021-04-20 21:20 Sergei Trofimovich
2021-04-18 19:41 Sergei Trofimovich
2021-03-16 17:52 Conrad Kostecki
2021-03-06 15:14 Sergei Trofimovich
2020-11-24  7:45 Agostino Sarubbo
2020-11-24  7:20 Agostino Sarubbo
2020-11-24  1:10 Sam James
2020-11-24  1:10 Sam James
2020-11-16 17:31 Conrad Kostecki
2020-10-18 13:27 Conrad Kostecki
2020-10-10 15:31 Conrad Kostecki
2020-10-10 15:31 Conrad Kostecki
2020-10-10 10:39 Conrad Kostecki
2020-08-24 14:39 Joonas Niilola

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1605547772.4b5eadf238bca4d1aa983578457d7d15317f1a7b.conikost@gentoo \
    --to=conikost@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox