diff options
Diffstat (limited to 'extra/lua/Pkgfile')
-rw-r--r-- | extra/lua/Pkgfile | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/extra/lua/Pkgfile b/extra/lua/Pkgfile index f9174d168..ab0918344 100644 --- a/extra/lua/Pkgfile +++ b/extra/lua/Pkgfile @@ -7,16 +7,21 @@ name=lua version=5.1.4 -release=1 -source=(http://www.lua.org/ftp/$name-$version.tar.gz) +release=2 +source=(http://www.lua.org/ftp/$name-$version.tar.gz + lua-5.1.4-patch-lua.patch + lua-5.1.4-cflags.diff) build() { -cd $name-$version -# sed -i "s|-O2|-O2 -march=i486 -mtune=i686|g" src/Makefile -# sed -i "s|/usr/local|$PKG/usr|g" config -make linux -make INSTALL_TOP=$PKG/usr install -rm -rf $PKG/usr/share -install -D -m 0644 etc/lua.pc $PKG/usr/lib/pkgconfig/lua.pc + cd $name-$version + patch < $SRC/lua-5.1.4-patch-lua.patch -d src + + [ "$CARCH" == "x86_64" ] && patch -Np1 -i ../lua-5.1.4-cflags.diff + [ "$CARCH" == "x86_64" ] && export CFLAGS="$CFLAGS -fPIC" + + make linux + make INSTALL_TOP=$PKG/usr install + rm -rf $PKG/usr/share + install -D -m 0644 etc/lua.pc $PKG/usr/lib/pkgconfig/lua.pc } |