New package: lua-5.1.4. Contributed by DigitalKiwi.
This commit is contained in:
parent
b0cf505357
commit
17ea977f79
7 changed files with 139 additions and 0 deletions
1
srcpkgs/lua-devel
Symbolic link
1
srcpkgs/lua-devel
Symbolic link
|
@ -0,0 +1 @@
|
|||
lua
|
2
srcpkgs/lua/depends
Normal file
2
srcpkgs/lua/depends
Normal file
|
@ -0,0 +1,2 @@
|
|||
abi_depends=">=5.1.4"
|
||||
api_depends="${abi_depends}"
|
20
srcpkgs/lua/lua-devel.template
Normal file
20
srcpkgs/lua/lua-devel.template
Normal file
|
@ -0,0 +1,20 @@
|
|||
# Template file for 'lua-devel'.
|
||||
#
|
||||
short_desc="${short_desc} - development files"
|
||||
long_desc="${long_desc}
|
||||
|
||||
This package contains files for development, headers, static libs, etc."
|
||||
|
||||
Add_dependency run ncurses-devel
|
||||
Add_dependency run readline-devel
|
||||
Add_dependency run lua
|
||||
|
||||
do_install()
|
||||
{
|
||||
install -d ${DESTDIR}/usr/{lib,share}
|
||||
|
||||
mv ${SRCPKGDESTDIR}/usr/include ${DESTDIR}/usr
|
||||
mv ${SRCPKGDESTDIR}/usr/lib/lib*.*a ${DESTDIR}/usr/lib
|
||||
mv ${SRCPKGDESTDIR}/usr/lib/pkgconfig ${DESTDIR}/usr/lib
|
||||
mv ${SRCPKGDESTDIR}/usr/share/doc ${DESTDIR}/usr/share
|
||||
}
|
13
srcpkgs/lua/patches/lua-5.1-cflags.diff
Normal file
13
srcpkgs/lua/patches/lua-5.1-cflags.diff
Normal file
|
@ -0,0 +1,13 @@
|
|||
diff -Naur lua-5.1.orig/src/Makefile lua-5.1/src/Makefile
|
||||
--- lua-5.1.orig/src/Makefile 2006-02-16 16:45:09.000000000 +0100
|
||||
+++ lua-5.1/src/Makefile 2006-03-01 14:55:29.000000000 +0100
|
||||
@@ -8,7 +8,8 @@
|
||||
PLAT= none
|
||||
|
||||
CC= gcc
|
||||
-CFLAGS= -O2 -Wall $(MYCFLAGS)
|
||||
+CFLAGS ?= -O2 -Wall
|
||||
+CFLAGS += $(MYCFLAGS)
|
||||
AR= ar rcu
|
||||
RANLIB= ranlib
|
||||
RM= rm -f
|
55
srcpkgs/lua/patches/lua-arch.patch
Normal file
55
srcpkgs/lua/patches/lua-arch.patch
Normal file
|
@ -0,0 +1,55 @@
|
|||
diff -ur lua-5.1.orig/etc/lua.pc lua-5.1/etc/lua.pc
|
||||
--- lua-5.1.orig/etc/lua.pc 2006-03-21 11:51:53.000000000 +0100
|
||||
+++ lua-5.1/etc/lua.pc 2006-03-21 11:52:05.000000000 +0100
|
||||
@@ -6,7 +6,7 @@
|
||||
V= 5.1
|
||||
|
||||
# grep '^INSTALL_.*=' ../Makefile | sed 's/INSTALL_TOP/prefix/'
|
||||
-prefix= /usr/local
|
||||
+prefix= /usr
|
||||
INSTALL_BIN= ${prefix}/bin
|
||||
INSTALL_INC= ${prefix}/include
|
||||
INSTALL_LIB= ${prefix}/lib
|
||||
diff -ur lua-5.1.orig/src/Makefile lua-5.1/src/Makefile
|
||||
--- lua-5.1.orig/src/Makefile 2006-03-21 11:51:53.000000000 +0100
|
||||
+++ lua-5.1/src/Makefile 2006-03-21 11:52:09.000000000 +0100
|
||||
@@ -23,6 +23,7 @@
|
||||
PLATS= aix ansi bsd generic linux macosx mingw posix solaris
|
||||
|
||||
LUA_A= liblua.a
|
||||
+LUA_SO= liblua.so
|
||||
CORE_O= lapi.o lcode.o ldebug.o ldo.o ldump.o lfunc.o lgc.o llex.o lmem.o \
|
||||
lobject.o lopcodes.o lparser.o lstate.o lstring.o ltable.o ltm.o \
|
||||
lundump.o lvm.o lzio.o
|
||||
@@ -36,7 +37,7 @@
|
||||
LUAC_O= luac.o print.o
|
||||
|
||||
ALL_O= $(CORE_O) $(LIB_O) $(LUA_O) $(LUAC_O)
|
||||
-ALL_T= $(LUA_A) $(LUA_T) $(LUAC_T)
|
||||
+ALL_T= $(LUA_A) $(LUA_SO) $(LUA_T) $(LUAC_T)
|
||||
ALL_A= $(LUA_A)
|
||||
|
||||
default: $(PLAT)
|
||||
@@ -51,6 +52,10 @@
|
||||
$(AR) $@ $?
|
||||
$(RANLIB) $@
|
||||
|
||||
+$(LUA_SO): $(CORE_O) $(LIB_O)
|
||||
+ $(CC) -shared -ldl -Wl,-soname,liblua.so -o $@.5.1 $? -lm $(MYLDFLAGS)
|
||||
+ ln -s $@.5.1 $@
|
||||
+
|
||||
$(LUA_T): $(LUA_O) $(LUA_A)
|
||||
$(CC) -o $@ $(MYLDFLAGS) $(LUA_O) $(LUA_A) $(LIBS)
|
||||
|
||||
diff -ur lua-5.1.orig/src/luaconf.h lua-5.1/src/luaconf.h
|
||||
--- lua-5.1.orig/src/luaconf.h 2006-03-21 11:51:53.000000000 +0100
|
||||
+++ lua-5.1/src/luaconf.h 2006-03-21 11:52:05.000000000 +0100
|
||||
@@ -82,7 +82,7 @@
|
||||
".\\?.dll;" LUA_CDIR"?.dll;" LUA_CDIR"loadall.dll"
|
||||
|
||||
#else
|
||||
-#define LUA_ROOT "/usr/local/"
|
||||
+#define LUA_ROOT "/usr/"
|
||||
#define LUA_LDIR LUA_ROOT "share/lua/5.1/"
|
||||
#define LUA_CDIR LUA_ROOT "lib/lua/5.1/"
|
||||
#define LUA_PATH_DEFAULT \
|
47
srcpkgs/lua/template
Normal file
47
srcpkgs/lua/template
Normal file
|
@ -0,0 +1,47 @@
|
|||
# Template file for 'lua'
|
||||
pkgname=lua
|
||||
version=5.1.4
|
||||
patch_args="-Np1"
|
||||
distfiles="http://www.lua.org/ftp/$pkgname-$version.tar.gz"
|
||||
build_style=custom-install
|
||||
short_desc="Lua is a powerful, fast, lightweight, embeddable scripting language."
|
||||
maintainer="Robert Djubek <envy1988@gmail.com>"
|
||||
homepage="http://www.lua.org"
|
||||
license="MIT"
|
||||
checksum=b038e225eaf2a5b57c9bcc35cd13aa8c6c8288ef493d52970c9545074098af3a
|
||||
long_desc="
|
||||
Lua combines simple procedural syntax with powerful data description
|
||||
constructs based on associative arrays and extensible semantics. Lua
|
||||
is dynamically typed, runs by interpreting bytecode for a register-based
|
||||
virtual machine, and has automatic memory management with incremental
|
||||
garbage collection, making it ideal for configuration, scripting, and
|
||||
rapid prototyping."
|
||||
|
||||
subpackages="lua-devel"
|
||||
|
||||
Add_dependency run glibc
|
||||
Add_dependency run ncurses-libs
|
||||
Add_dependency run readline
|
||||
Add_dependency build ncurses-devel
|
||||
Add_dependency build readline-devel
|
||||
|
||||
do_build()
|
||||
{
|
||||
export CFLAGS="$XBPS_CFLAGS -fPIC"
|
||||
make INSTALL_DATA="cp -d" LUA_SO=liblua.so ${makejobs} linux
|
||||
}
|
||||
|
||||
do_install()
|
||||
{
|
||||
make INSTALL_DATA="cp -d" INSTALL_TOP="${DESTDIR}/usr" \
|
||||
TO_LIB="liblua.a liblua.so liblua.so.5.1" \
|
||||
INSTALL_MAN="${DESTDIR}/usr/share/man/man1" install
|
||||
install -Dm 644 etc/lua.pc ${DESTDIR}/usr/lib/pkgconfig/lua.pc
|
||||
install -Dm644 COPYRIGHT \
|
||||
${DESTDIR}/usr/share/licenses/${pkgname}/COPYRIGHT
|
||||
|
||||
# Install the documentation
|
||||
mkdir -p ${DESTDIR}/usr/share/doc/lua
|
||||
cp -R doc/* ${DESTDIR}/usr/share/doc/lua
|
||||
cd ${DESTDIR}/usr/lib && ln -sf liblua.so.5.1 liblua.so.5
|
||||
}
|
|
@ -132,6 +132,7 @@ libnl.so libnl libnl-devel
|
|||
libssl.so libssl openssl-devel
|
||||
libcrypto.so libssl openssl-devel
|
||||
libreadline.so readline readline-devel
|
||||
libhistory.so readline readline-devel
|
||||
libxfcegui4.so libxfcegui4 libxfcegui4-devel
|
||||
libxfce4kbd-private.so libxfcegui4 libxfcegui4-devel
|
||||
libxfce4menu-0.1.so libxfce4menu libxfce4menu-devel
|
||||
|
|
Loading…
Reference in a new issue