lua stable port information

Package: lua
Version: 5.0.2
Revision: 1007
Epoch: 1
Description: Small, compilable scripting language
PatchFile: %n.patch
PatchFile-MD5: bb4e66389ffa4adbd609f0b600a60bdf
PatchScript: sed -e 's|@prefix@|%p|g' -e 's|@version@|%v|g' <%{PatchFile} | patch -p1
DescDetail: <<
Lua is a programming language originally designed for extending applications,
but also frequently used as a general-purpose, stand-alone language. Lua
combines simple procedural syntax (similar to Pascal) with powerful data
description constructs based on associative arrays and extensible semantics.
Lua is dynamically typed, interpreted from bytecodes, and has automatic memory
management with garbage collection, making it ideal for configuration,
scripting, and rapid prototyping.

A fundamental concept in the design of Lua is to provide meta-mechanisms for
implementing features, instead of providing a host of features directly in
the language. For example, although Lua is not a pure object-oriented
language, it does provide meta-mechanisms for implementing classes and
inheritance. Lua's meta-mechanisms bring an economy of concepts and keep the
language small, while allowing the semantics to be extended in unconventional
ways. Extensible semantics is a distinguishing feature of Lua.

Lua is implemented as a small library of C functions, written in ANSI C, and
compiles unmodified in all known platforms. The implementation goals are
simplicity, efficiency, portability, and low embedding cost.
<<
License: OSI-Approved
BuildDepends: fink (>= 0.24.12), readline5
Depends: readline5-shlibs, %N-shlibs (= %e:%v-%r)
BuildDependsOnly: false
Source-MD5: dea74646b7e5c621fef7174df83c34b1
Conflicts: lua51, lua51-dev
Replaces: lua51, lua51-dev
CompileScript: <<
make
make so
<<
InstallScript: <<
make INSTALL_ROOT=%i install
make INSTALL_ROOT=%i soinstall
mkdir -p %i/share
mv %i/man %i/share
<<
Homepage: http://www.lua.org/
Maintainer: Jean-Louis Fuchs
Source: mirror:custom:%n-%v.tar.gz
CustomMirror: <<
nam-CA: ftp://csg.uwaterloo.ca/pub/lhf/lua/
eur-DE: ftp://ftp.uni-trier.de/pub/languages/lua/
eur-DE: ftp://ftp.gwdg.de/pub/languages/lua/
eur-GR: ftp://ftp.ntua.gr/pub/lang/lua/
Primary: ftp://ftp.tecgraf.puc-rio.br/pub/lua/
<<
DocFiles: doc/logo.gif doc/lua.html doc/luac.html doc/manual.html doc/readme.html COPYRIGHT HISTORY INSTALL MANIFEST README
SplitOff: <<
Package: lua-shlibs
Description: lua shared libraries
DocFiles: COPYRIGHT HISTORY README
Files: lib/liblua.%v.dylib lib/liblualib.%v.dylib
Shlibs: <<
%p/lib/liblua.%v.dylib 5.0.0 %n (>= 5.0.2-1)
%p/lib/liblualib.%v.dylib 5.0.0 %n (>= 5.0.2-1)
<<
<<

lua stable port .patch

diff -ru lua-5.0.2-orig/Makefile lua-5.0.2/Makefile
--- lua-5.0.2-orig/Makefile 2004-03-12 02:50:55.000000000 +0100
+++ lua-5.0.2/Makefile 2005-09-09 18:43:34.000000000 +0200
@@ -38,9 +38,9 @@

# shared libraries (for Linux)
so:
- ld -o lib/liblua.so.$V -shared src/*.o
- ld -o lib/liblualib.so.$V -shared src/lib/*.o
- cd lib; ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
+ $(CC) -dynamiclib -o lib/liblua.@version@.dylib src/*.o -install_name @prefix@/lib/liblua.@version@.dylib -compatibility_version $V -current_version @version@
+ $(CC) -dynamiclib -o lib/liblualib.@version@.dylib src/lib/*.o lib/liblua.@version@.dylib -install_name @prefix@/lib/liblualib.@version@.dylib -compatibility_version $V -current_version @version@
+ cd lib; ln -fs liblua.@version@.dylib liblua.dylib; ln -fs liblualib.@version@.dylib liblualib.dylib

# binaries using shared libraries
sobin:
@@ -50,8 +50,8 @@

# install shared libraries
soinstall:
- $(INSTALL_EXEC) lib/*.so.* $(INSTALL_LIB)
- cd $(INSTALL_LIB); ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
+ $(INSTALL_EXEC) lib/*.dylib $(INSTALL_LIB)
+ cd $(INSTALL_LIB); ln -fs liblua.@version@.dylib liblua.dylib; ln -fs liblualib.@version@.dylib liblualib.dylib

# clean shared libraries
soclean:
diff -ru lua-5.0.2-orig/config lua-5.0.2/config
--- lua-5.0.2-orig/config 2003-04-11 16:00:41.000000000 +0200
+++ lua-5.0.2/config 2005-09-09 18:47:34.000000000 +0200
@@ -25,7 +25,7 @@
# interface (e.g., Linux, Solaris, IRIX, BSD, AIX, HPUX, and probably others),
# uncomment the next two lines.
#
-#LOADLIB= -DUSE_DLOPEN=1
+LOADLIB= -DUSE_DLOPEN=1
#DLLIB= -ldl
#
# In Linux with gcc, you should also uncomment the next definition for
@@ -33,7 +33,7 @@
# allows dynamic libraries to link back to the `lua' program, so that they do
# not need the Lua libraries. (Other systems may have an equivalent facility.)
#
-#MYLDFLAGS= -Wl,-E
+MYLDFLAGS= -Wl,-search_paths_first -L../../lib $(LDFLAGS)
#
# On Windows systems. support for dynamic loading is enabled by default.
# To disable this support, uncomment the next line.
@@ -45,7 +45,7 @@
# If your system is not POSIX but has popen and pclose, define USE_POPEN=1.
# If you don't want to support pipes, define USE_POPEN=0.
#
-#POPEN= -DUSE_POPEN=1
+POPEN= -DUSE_POPEN=1
#POPEN= -DUSE_POPEN=0
#
# The form below will probably work in (some) Windows systems.
@@ -100,8 +100,8 @@
# to add -lreadline (and perhaps also -lhistory and -lcurses or -lncurses)
# to EXTRA_LIBS.
#
-#USERCONF=-DLUA_USERCONFIG='"$(LUA)/etc/saconfig.c"' -DUSE_READLINE
-#EXTRA_LIBS= -lm -ldl -lreadline # -lhistory -lcurses -lncurses
+USERCONF=-DLUA_USERCONFIG='"$(LUA)/etc/saconfig.c"' -DUSE_READLINE
+EXTRA_LIBS= -lm -ldl -lreadline # -lhistory -lcurses -lncurses

# ------------------------------------------------------------------ C compiler

@@ -119,8 +119,8 @@
# debug information. If you only want the shared libraries, you may want to
# add -fPIC to MYCFLAGS.
#
-MYCFLAGS= -O2
-#MYCFLAGS= -O3 -fomit-frame-pointer # -fPIC
+#MYCFLAGS= -O2
+MYCFLAGS= -O3 -fomit-frame-pointer # -fPIC

# Write here any options you may need for your C linker.
#MYLDFLAGS=
@@ -157,8 +157,8 @@
# You may prefer to use "install" instead of "cp" if you have it.
# If you use "install", you may also want to change the permissions after -m.
#
-INSTALL_EXEC= cp
-INSTALL_DATA= cp
+INSTALL_EXEC= cp -p
+INSTALL_DATA= cp -p
#INSTALL_EXEC= install -m 0755
#INSTALL_DATA= install -m 0644

diff -ru lua-5.0.2-orig/src/lib/lbaselib.c lua-5.0.2/src/lib/lbaselib.c
--- lua-5.0.2-orig/src/lib/lbaselib.c 2004-03-04 01:45:13.000000000 +0100
+++ lua-5.0.2/src/lib/lbaselib.c 2005-09-09 18:43:34.000000000 +0200
@@ -409,7 +409,7 @@
#endif

#ifndef LUA_PATH_DEFAULT
-#define LUA_PATH_DEFAULT "?;?.lua"
+#define LUA_PATH_DEFAULT "?;?.lua;@prefix@/share/lua/5.0/?.lua;@prefix@/share/lua/5.0/?/?.lua;@prefix@/share/lua/5.0/?/init.lua"
#endif


lua _unstable_ port information

Package: lua
Version: 5.0.2
Revision: 1007
Epoch: 1
Description: Small, compilable scripting language
PatchFile: %n.patch
PatchFile-MD5: bb4e66389ffa4adbd609f0b600a60bdf
PatchScript: sed -e 's|@prefix@|%p|g' -e 's|@version@|%v|g' <%{PatchFile} | patch -p1
DescDetail: <<
Lua is a programming language originally designed for extending applications,
but also frequently used as a general-purpose, stand-alone language. Lua
combines simple procedural syntax (similar to Pascal) with powerful data
description constructs based on associative arrays and extensible semantics.
Lua is dynamically typed, interpreted from bytecodes, and has automatic memory
management with garbage collection, making it ideal for configuration,
scripting, and rapid prototyping.

A fundamental concept in the design of Lua is to provide meta-mechanisms for
implementing features, instead of providing a host of features directly in
the language. For example, although Lua is not a pure object-oriented
language, it does provide meta-mechanisms for implementing classes and
inheritance. Lua's meta-mechanisms bring an economy of concepts and keep the
language small, while allowing the semantics to be extended in unconventional
ways. Extensible semantics is a distinguishing feature of Lua.

Lua is implemented as a small library of C functions, written in ANSI C, and
compiles unmodified in all known platforms. The implementation goals are
simplicity, efficiency, portability, and low embedding cost.
<<
License: OSI-Approved
BuildDepends: fink (>= 0.24.12), readline5
Depends: readline5-shlibs, %N-shlibs (= %e:%v-%r)
BuildDependsOnly: false
Source-MD5: dea74646b7e5c621fef7174df83c34b1
Conflicts: lua51, lua51-dev
Replaces: lua51, lua51-dev
CompileScript: <<
make
make so
<<
InstallScript: <<
make INSTALL_ROOT=%i install
make INSTALL_ROOT=%i soinstall
mkdir -p %i/share
mv %i/man %i/share
<<
Homepage: http://www.lua.org/
Maintainer: Jean-Louis Fuchs
Source: mirror:custom:%n-%v.tar.gz
CustomMirror: <<
nam-CA: ftp://csg.uwaterloo.ca/pub/lhf/lua/
eur-DE: ftp://ftp.uni-trier.de/pub/languages/lua/
eur-DE: ftp://ftp.gwdg.de/pub/languages/lua/
eur-GR: ftp://ftp.ntua.gr/pub/lang/lua/
Primary: ftp://ftp.tecgraf.puc-rio.br/pub/lua/
<<
DocFiles: doc/logo.gif doc/lua.html doc/luac.html doc/manual.html doc/readme.html COPYRIGHT HISTORY INSTALL MANIFEST README
SplitOff: <<
Package: lua-shlibs
Description: lua shared libraries
DocFiles: COPYRIGHT HISTORY README
Files: lib/liblua.%v.dylib lib/liblualib.%v.dylib
Shlibs: <<
%p/lib/liblua.%v.dylib 5.0.0 %n (>= 5.0.2-1)
%p/lib/liblualib.%v.dylib 5.0.0 %n (>= 5.0.2-1)
<<
<<

lua _unstable_ port .patch

diff -ru lua-5.0.2-orig/Makefile lua-5.0.2/Makefile
--- lua-5.0.2-orig/Makefile 2004-03-12 02:50:55.000000000 +0100
+++ lua-5.0.2/Makefile 2005-09-09 18:43:34.000000000 +0200
@@ -38,9 +38,9 @@

# shared libraries (for Linux)
so:
- ld -o lib/liblua.so.$V -shared src/*.o
- ld -o lib/liblualib.so.$V -shared src/lib/*.o
- cd lib; ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
+ $(CC) -dynamiclib -o lib/liblua.@version@.dylib src/*.o -install_name @prefix@/lib/liblua.@version@.dylib -compatibility_version $V -current_version @version@
+ $(CC) -dynamiclib -o lib/liblualib.@version@.dylib src/lib/*.o lib/liblua.@version@.dylib -install_name @prefix@/lib/liblualib.@version@.dylib -compatibility_version $V -current_version @version@
+ cd lib; ln -fs liblua.@version@.dylib liblua.dylib; ln -fs liblualib.@version@.dylib liblualib.dylib

# binaries using shared libraries
sobin:
@@ -50,8 +50,8 @@

# install shared libraries
soinstall:
- $(INSTALL_EXEC) lib/*.so.* $(INSTALL_LIB)
- cd $(INSTALL_LIB); ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
+ $(INSTALL_EXEC) lib/*.dylib $(INSTALL_LIB)
+ cd $(INSTALL_LIB); ln -fs liblua.@version@.dylib liblua.dylib; ln -fs liblualib.@version@.dylib liblualib.dylib

# clean shared libraries
soclean:
diff -ru lua-5.0.2-orig/config lua-5.0.2/config
--- lua-5.0.2-orig/config 2003-04-11 16:00:41.000000000 +0200
+++ lua-5.0.2/config 2005-09-09 18:47:34.000000000 +0200
@@ -25,7 +25,7 @@
# interface (e.g., Linux, Solaris, IRIX, BSD, AIX, HPUX, and probably others),
# uncomment the next two lines.
#
-#LOADLIB= -DUSE_DLOPEN=1
+LOADLIB= -DUSE_DLOPEN=1
#DLLIB= -ldl
#
# In Linux with gcc, you should also uncomment the next definition for
@@ -33,7 +33,7 @@
# allows dynamic libraries to link back to the `lua' program, so that they do
# not need the Lua libraries. (Other systems may have an equivalent facility.)
#
-#MYLDFLAGS= -Wl,-E
+MYLDFLAGS= -Wl,-search_paths_first -L../../lib $(LDFLAGS)
#
# On Windows systems. support for dynamic loading is enabled by default.
# To disable this support, uncomment the next line.
@@ -45,7 +45,7 @@
# If your system is not POSIX but has popen and pclose, define USE_POPEN=1.
# If you don't want to support pipes, define USE_POPEN=0.
#
-#POPEN= -DUSE_POPEN=1
+POPEN= -DUSE_POPEN=1
#POPEN= -DUSE_POPEN=0
#
# The form below will probably work in (some) Windows systems.
@@ -100,8 +100,8 @@
# to add -lreadline (and perhaps also -lhistory and -lcurses or -lncurses)
# to EXTRA_LIBS.
#
-#USERCONF=-DLUA_USERCONFIG='"$(LUA)/etc/saconfig.c"' -DUSE_READLINE
-#EXTRA_LIBS= -lm -ldl -lreadline # -lhistory -lcurses -lncurses
+USERCONF=-DLUA_USERCONFIG='"$(LUA)/etc/saconfig.c"' -DUSE_READLINE
+EXTRA_LIBS= -lm -ldl -lreadline # -lhistory -lcurses -lncurses

# ------------------------------------------------------------------ C compiler

@@ -119,8 +119,8 @@
# debug information. If you only want the shared libraries, you may want to
# add -fPIC to MYCFLAGS.
#
-MYCFLAGS= -O2
-#MYCFLAGS= -O3 -fomit-frame-pointer # -fPIC
+#MYCFLAGS= -O2
+MYCFLAGS= -O3 -fomit-frame-pointer # -fPIC

# Write here any options you may need for your C linker.
#MYLDFLAGS=
@@ -157,8 +157,8 @@
# You may prefer to use "install" instead of "cp" if you have it.
# If you use "install", you may also want to change the permissions after -m.
#
-INSTALL_EXEC= cp
-INSTALL_DATA= cp
+INSTALL_EXEC= cp -p
+INSTALL_DATA= cp -p
#INSTALL_EXEC= install -m 0755
#INSTALL_DATA= install -m 0644

diff -ru lua-5.0.2-orig/src/lib/lbaselib.c lua-5.0.2/src/lib/lbaselib.c
--- lua-5.0.2-orig/src/lib/lbaselib.c 2004-03-04 01:45:13.000000000 +0100
+++ lua-5.0.2/src/lib/lbaselib.c 2005-09-09 18:43:34.000000000 +0200
@@ -409,7 +409,7 @@
#endif

#ifndef LUA_PATH_DEFAULT
-#define LUA_PATH_DEFAULT "?;?.lua"
+#define LUA_PATH_DEFAULT "?;?.lua;@prefix@/share/lua/5.0/?.lua;@prefix@/share/lua/5.0/?/?.lua;@prefix@/share/lua/5.0/?/init.lua"
#endif