dev-db/redis: GitHub PR dropped slotted-Lua improvements
authorRobin H. Johnson <robbat2@gentoo.org>
Thu, 18 Apr 2019 05:08:23 +0000 (22:08 -0700)
committerRobin H. Johnson <robbat2@gentoo.org>
Thu, 18 Apr 2019 05:10:34 +0000 (22:10 -0700)
Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
dev-db/redis/redis-4.0.14.ebuild
dev-db/redis/redis-5.0.4.ebuild

index 5f2c18f61cbc8f13decd315109d0b64ec4128e7e..08d29146a9bc7230b6ed01106cd6b0e28b5d89a9 100644 (file)
@@ -71,15 +71,28 @@ src_prepare() {
        cp "${FILESDIR}"/configure.ac-3.2 configure.ac || die
 
        # Use the correct pkgconfig name for Lua
-       has_version 'dev-lang/lua:5.1' \
-               && LUAPKGCONFIG=lua5.1 \
-               || LUAPKGCONFIG=lua
+       if false && has_version 'dev-lang/lua:5.3'; then
+               # Lua5.3 gives:
+               #lua_bit.c:83:2: error: #error "Unknown number type, check LUA_NUMBER_* in luaconf.h"
+               LUAPKGCONFIG=lua5.3
+       elif false && has_version 'dev-lang/lua:5.2'; then
+               # Lua5.2 fails with:
+               # scripting.c:(.text+0x1f9b): undefined reference to `lua_open'
+               # Because lua_open because lua_newstate in 5.2
+               LUAPKGCONFIG=lua5.2
+       elif has_version 'dev-lang/lua:5.1'; then
+               LUAPKGCONFIG=lua5.1
+       else
+               LUAPKGCONFIG=lua
+       fi
+       # The upstream configure script handles luajit specially, and is not
+       # effected by these changes.
+       einfo "Selected LUAPKGCONFIG=${LUAPKGCONFIG}"
        sed -i  \
                -e "/^AC_INIT/s|, [0-9].+, |, $PV, |" \
                -e "s:AC_CONFIG_FILES(\[Makefile\]):AC_CONFIG_FILES([${makefiles}]):g" \
                -e "/PKG_CHECK_MODULES.*\<LUA\>/s,lua5.1,${LUAPKGCONFIG},g" \
                configure.ac || die "Sed failed for configure.ac"
-
        eautoreconf
 }
 
index 519fc3837ca90bdf477b4dbf489f71335cbd9769..07c6466e9a12a6d2c0289a059665ad74e419b558 100644 (file)
@@ -71,9 +71,23 @@ src_prepare() {
        cp "${FILESDIR}"/configure.ac-3.2 configure.ac || die
 
        # Use the correct pkgconfig name for Lua
-       has_version 'dev-lang/lua:5.1' \
-               && LUAPKGCONFIG=lua5.1 \
-               || LUAPKGCONFIG=lua
+       if false && has_version 'dev-lang/lua:5.3'; then
+               # Lua5.3 gives:
+               #lua_bit.c:83:2: error: #error "Unknown number type, check LUA_NUMBER_* in luaconf.h"
+               LUAPKGCONFIG=lua5.3
+       elif false && has_version 'dev-lang/lua:5.2'; then
+               # Lua5.2 fails with:
+               # scripting.c:(.text+0x1f9b): undefined reference to `lua_open'
+               # Because lua_open because lua_newstate in 5.2
+               LUAPKGCONFIG=lua5.2
+       elif has_version 'dev-lang/lua:5.1'; then
+               LUAPKGCONFIG=lua5.1
+       else
+               LUAPKGCONFIG=lua
+       fi
+       # The upstream configure script handles luajit specially, and is not
+       # effected by these changes.
+       einfo "Selected LUAPKGCONFIG=${LUAPKGCONFIG}"
        sed -i  \
                -e "/^AC_INIT/s|, [0-9].+, |, $PV, |" \
                -e "s:AC_CONFIG_FILES(\[Makefile\]):AC_CONFIG_FILES([${makefiles}]):g" \