summaryrefslogtreecommitdiffstats
path: root/lua/Pkgfile
blob: 3b7b6b8103b0ebd29d8bcbeab026224a92df9a31 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
description="A powerful, fast, lightweight, embeddable scripting language."
longdesc="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."
url=http://www.lua.org
packager="Tilman Sauerbeck <tilman AT crux DOT nu>"
maintainer="Lukc <lukc AT upyum DOT com>"
lastver="wcat http://www.lua.org/ftp/ | grep '\.tar\.gz' | sed -e 's/\.tar\.gz.*//;s/.*lua-//;/all/d' | tail -n 1"
license=MIT
depends=()

name=lua
version=5.1.4
release=1
source=(
	http://www.lua.org/ftp/$name-$version.tar.gz
	$name.diff
)

# XXX: À faire
#  - Compilation croisée.
#  - Construction statique.
#  - Installation dans des préfixes alternatifs.
#  - Filer le paquet à Kooda ?

build() {
	cd $name-$version

	patch -Np1 -i $SRC/$name.diff
	
	make linux
	make INSTALL_TOP=$PKG/usr install
	
	install -D -m 0644 etc/lua.pc $PKG/usr/lib/pkgconfig/lua.pc
	if [[ "$mandir" != "/usr/man" ]]; then
		mkdir -p $PKG$mandir
		mv $PKG/usr/man/* $PKG$mandir/
		rmdir $PKG/usr/man
	fi
}