Configuration
All the binaries were built using Tecmake with the following configuration parameters and changes:
Lua 5.2
LuaBinaries distribution of Lua 5.2 uses the same default configuration of the makefiles provided by the Lua.org distribution tar file, but using "lua52" as library and program names. A small difference is that the "etc/bin2c.c" utility is re-added to the distribution.
AIX/IRIX/SunOS LUA_USE_POSIX LUA_USE_DLOPEN Linux/BSD/Cygwin LUA_USE_POSIX LUA_USE_DLOPEN LUA_USE_READLINE MacOSX LUA_USE_POSIX LUA_DL_DYLD In Windows the default configuration also enable equivalent definitions for LUA_USE_ISATTY and LUA_USE_POPEN (part of LUA_USE_POSIX). And LUA_DL_DLL is also defined. The executables contain support for command line globing (so you can use "lua52 *.lua"). The executables are dependent on the "lua52.dll" library. The modules default search path (LUA_CPATH definition) also includes the "clibs" subfolder used by the Lua for Windows distribution. The LoadLibraryEx uses the alternate search path flag.
In UNIX the executables exports the Lua functions, so they are not dependent on the LuaBinaries dynamic libraries.
Note: The default LUA_CPATH supports the "52" suffix used in Tecgraf libraries.
Lua 5.1
LuaBinaries distribution of Lua 5.1 uses the same default configuration of the makefiles provided by the Lua.org distribution tar file, but using "lua5.1" as library and program names. A small difference is that the "etc/bin2c.c" utility is re-added to the distribution.
AIX/IRIX/SunOS LUA_USE_POSIX LUA_USE_DLOPEN Linux/BSD/Cygwin LUA_USE_POSIX LUA_USE_DLOPEN LUA_USE_READLINE MacOSX LUA_USE_POSIX LUA_DL_DYLD In Windows the default configuration also enable equivalent definitions for LUA_USE_ISATTY and LUA_USE_POPEN (part of LUA_USE_POSIX). And LUA_DL_DLL is also defined. The executables contain support for command line globing (so you can use "lua5.1 *.lua"). The executables are dependent on the "lua5.1.dll" library. The modules default search path (LUA_CPATH definition) also includes the "clibs" subfolder.
In UNIX the executables exports the Lua functions, so they are not dependent on the LuaBinaries dynamic libraries.
Note 1: The name "lua5.1" was a decision we made at the release of LuaBinaries for Lua 5.1.0. Unfortunately it was a bad decision, but because of several applications compatibility we will keep it until Lua 5.2.0 is released.
Note 2: The default LUA_CPATH supports the "51" suffix used in Tecgraf libraries.
Lua 5.0
lualib USE_TMPNAME defined in all systems.
USE_POPEN defined in non Windows systems.
USE_DLOPEN defined in non Windows systems, except AIX.luac LUA_OPNAMES defined in all systems. lua (executable) _POSIX_SOURCE defined in non Windows systems.
LUA_USERCONFIG='"$(LUA5)/etc/saconfig.c"' and USE_READLINE defined only in Linux systems.
-Wl,-E parameter used in Linux systems.
In Release 2, linked with the dynamic library in Windows, statically linked in UNIX.
Lua 4.0
lualib POPEN defined in non Windows systems. bin2c fixed a problem with C++ compilers. lua (executable) _POSIX_SOURCE defined in non Windows systems.
Lua 3.2
bin2c fixed a problem with C++ compilers.
Libraries and executables were built using speed optimization. In UNIX the dynamic libraries were NOT built with the -fpic parameter. In MacOS X the dynamic libraries are in bundle format. The source code along with the "config.mak" files for Tecmake are also available.
The DLLs were built using the cdecl calling convention. This could be a problem for Visual Basic users.
In Visual C++ 6 and 7 we use the single thread C Run Time Library for static libraries and the multi thread C RTL for DLLs. Since Visual C++ 8 both (static and dynamic) use the multi thread C RTL.
The library names have at least the major version number as a suffix. Except for Lua 3 because of historical reasons. So several versions of Lua can coexist in the same system, can be easily linked, and identified.
If you want to build dynamically loadable modules that should be compatible with LuaBinaries please check the Using LuaBinaries documentation.
Building LuaBinaries
If you need to build the binaries yourself consider using Tecmake. It is easy and will make your life easier. The Tecmake configuration files (*.mak) available at the "src" folder are very easy to understand also.
The LuaBinaries source packages already include the Tecmake compact version for UNIX, so no installation is necessary, just type "make". It will build the same binaries, with the same names and folder configuration we use.
In the "src" folder there are also scripts called "make_uname" that will call Tecmake to build the library and the executables. After installing Tecmake just run "make_uname". In Windows an additional parameter specifing the compiler is needed, for ex: "make_uname vc9" or "make_uname mingw4".
IDE project files and Makefiles are also included in the source code. They are not used to build the standard distribution. The IDE project files are intended for those who want to debug Lua code using the LuaBinaries configuration. We use Premake to build the IDE project files.
The standard Lua.org makefiles are still available but be aware that they do not build the dynamic libraries in UNIX.
In Ubuntu you will need to install the following package and its dependencies to build the interpreter executable:
libreadline5-dev
For those who build installation packages like MSI, RPM or DEB, please use the binaries from LuaBinaries, just repack them in the installation package format. Or if you want to rebuild the binaries then make sure use the same configuration and the same name standard. This will make the life of many Lua users and package developers easier. If the packaging format requires a different file name then please use the standard file name and add a symbolic link with the required file name, or at least add a symbolic link to the standard file name.
For those who build Lua binaries in other platforms following the LuaBinaries standards we would be happy to redistribute your binaries in the LuaBinaries downloads. Also installation packages using LuaBinaries are welcome to be redistributed in the LuaBinaries downloads.