diff options
author | davidovski <david@davidovski.xyz> | 2022-05-31 11:05:19 +0100 |
---|---|---|
committer | davidovski <david@davidovski.xyz> | 2022-05-31 11:05:19 +0100 |
commit | 48ca75555522716f0f686dcae3dd6cf3d8ad714d (patch) | |
tree | 00c0f58550ba4661e87376f2f02c8001c69bae44 /repo/lua/lua.xibuild | |
parent | 871b2b573f01c1b3176a0f65458b3d281b41c437 (diff) |
removed idea of repos
Diffstat (limited to 'repo/lua/lua.xibuild')
-rw-r--r-- | repo/lua/lua.xibuild | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/repo/lua/lua.xibuild b/repo/lua/lua.xibuild new file mode 100644 index 0000000..167fd70 --- /dev/null +++ b/repo/lua/lua.xibuild @@ -0,0 +1,60 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="readline" + +PKG_VER=5.4.4 +SOURCE=https://www.lua.org/ftp/lua-$PKG_VER.tar.gz +ADDITIONAL=" + lua5.4.pc + +CVE-2022-28805.patch +extern-c-for-cpp.patch +fix-double-free.patch +lua-5.4.4-shared_library-1.patch + " + +DESC="A powerful lightweight scripting language" + +prepare () { + apply_patches + sed -e "s|@MAJOR_VER@|${PKG_VER%.*}|g" \ + -e "s|@MINOR_VER@|${PKG_VER}|g" \ + -i lua5.4.pc + + cat > configure.ac <<-EOF + top_buildir=. + + AC_INIT(src/luaconf.h) + AC_PROG_LIBTOOL + AC_OUTPUT() + EOF + libtoolize --force --install && aclocal && autoconf + + +} + +build () { + ./configure \ + --prefix=/usr + cd src + CFLAGS="$CFLAGS -DLUA_USE_LINUX -DLUA_COMPAT_5_2" \ + SYSLDFLAGS="$LDFLAGS" \ + RPATH="/usr/lib" make +} + +package () { + cd .. + sed -i "s/INSTALL= install -p/INSTALL= install/g" Makefile + make V=${PKG_VER%.*} \ + INSTALL_TOP="$PKG_DEST"/usr \ + INSTALL_INC="$PKG_DEST"/usr/include/lua${PKG_VER%.*} \ + INSTALL_LIB="$PKG_DEST"/usr/lib/lua${PKG_VER%.*} install + + + mkdir -p $PKG_DEST/usr/share/doc/lua-$PKG_VER + for s in html css gif png; do + cp doc/*.$s $PKG_DEST/usr/share/doc/lua-$PKG_VER + done + install -Dm644 lua5.4.pc "$PKG_DEST"/usr/lib/pkgconfig/lua5.4.pc +} |