summaryrefslogtreecommitdiff
path: root/repo/lua
diff options
context:
space:
mode:
Diffstat (limited to 'repo/lua')
-rw-r--r--repo/lua/lua.xibuild36
1 files changed, 26 insertions, 10 deletions
diff --git a/repo/lua/lua.xibuild b/repo/lua/lua.xibuild
index 167fd70..738241d 100644
--- a/repo/lua/lua.xibuild
+++ b/repo/lua/lua.xibuild
@@ -35,26 +35,42 @@ prepare () {
}
build () {
- ./configure \
+ ./configure \
--prefix=/usr
cd src
CFLAGS="$CFLAGS -DLUA_USE_LINUX -DLUA_COMPAT_5_2" \
SYSLDFLAGS="$LDFLAGS" \
+ LIB_LIBS="-lpthread -lm -ldl -lreadline" \
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/lib
+ mkdir -p $PKG_DEST/usr/bin
+ make V=$PKG_VER \
+ INSTALL_TOP="$PKG_DEST/usr" \
+ INSTALL_INC="$PKG_DEST/usr/include" \
+ INSTALL_LIB="$PKG_DEST/usr/lib" \
+ install
+ install -D -m 644 src/liblua.so.5.4.4.4 "$PKG_DEST"/usr/lib/liblua.so.5.4.4.4
+ ln -sf liblua.so.5.4.4.4 $PKG_DEST/usr/lib/liblua.so.5.4.4
+ ln -sf liblua.so.5.4.4.4 $PKG_DEST/usr/lib/liblua.so
- 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
+
+ install -D -m 644 lua5.4.pc "$PKG_DEST"/usr/lib/pkgconfig/lua${PKG_VER%.*}.pc
+ install -D -m 644 doc/lua.1 "$PKG_DEST"/usr/share/man/man1/lua$PKG_VER
+ install -D -m 644 doc/luac.1 "$PKG_DEST"/usr/share/man/man1/luac$PKG_VER
+
+ mkdir -p "$PKG_DEST"/usr/share/doc/lua5-3/
+ install -m644 doc/*.html doc/*.css doc/logo.gif doc/cover.png \
+ "$PKG_DEST"/usr/share/doc/lua5-3/
+
+ ln -s lua${PKG_VER%.*} "$PKG_DEST"/usr/bin/lua
+ ln -s luac${PKG_VER%.*}.a "$PKG_DEST"/usr/bin/luac
+ ln -s lua${PKG_VER%.*}.pc "$PKG_DEST"/usr/lib/pkgconfig/lua.pc
+ ln -s lua${PKG_VER} "$PKG_DEST"/usr/share/man/man1/lua.1
+ ln -s luac${PKG_VER} "$PKG_DEST"/usr/share/man/man1/luac.1
}