Lua is a powerful, light-weight programming language designed for extending applications. Lua is 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, making it ideal for configuration, scripting, and rapid prototyping. Lua is a language engine that you can embed into your application. This means that, besides syntax and semantics, Lua has an API that allows the application to exchange data with Lua programs and also to extend Lua with C functions. In this sense, Lua can be regarded as a language framework for building domain-specific languages. 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. The result is a fast language engine with small footprint, making it ideal in embedded systems too.
50 lines
2 KiB
Text
50 lines
2 KiB
Text
$NetBSD: patch-Makefile,v 1.1.1.1 2015/01/17 17:50:23 alnsn Exp $
|
|
|
|
--- Makefile.orig 2014-10-29 23:14:41.000000000 +0000
|
|
+++ Makefile
|
|
@@ -10,11 +10,11 @@ PLAT= none
|
|
# so take care if INSTALL_TOP is not an absolute path. See the local target.
|
|
# You may want to make INSTALL_LMOD and INSTALL_CMOD consistent with
|
|
# LUA_ROOT, LUA_LDIR, and LUA_CDIR in luaconf.h.
|
|
-INSTALL_TOP= /usr/local
|
|
+INSTALL_TOP= ${PREFIX}
|
|
INSTALL_BIN= $(INSTALL_TOP)/bin
|
|
-INSTALL_INC= $(INSTALL_TOP)/include
|
|
+INSTALL_INC= $(INSTALL_TOP)/include/lua-5.3
|
|
INSTALL_LIB= $(INSTALL_TOP)/lib
|
|
-INSTALL_MAN= $(INSTALL_TOP)/man/man1
|
|
+INSTALL_MAN= $(INSTALL_TOP)/${PKGMANDIR}/man1
|
|
INSTALL_LMOD= $(INSTALL_TOP)/share/lua/$V
|
|
INSTALL_CMOD= $(INSTALL_TOP)/lib/lua/$V
|
|
|
|
@@ -39,10 +39,10 @@ RM= rm -f
|
|
PLATS= aix bsd c89 freebsd generic linux macosx mingw posix solaris
|
|
|
|
# What to install.
|
|
-TO_BIN= lua luac
|
|
+TO_BIN= lua5.3 luac5.3
|
|
TO_INC= lua.h luaconf.h lualib.h lauxlib.h lua.hpp
|
|
-TO_LIB= liblua.a
|
|
-TO_MAN= lua.1 luac.1
|
|
+TO_LIB= liblua5.3.la
|
|
+TO_MAN= lua5.3.1 luac5.3.1
|
|
|
|
# Lua version and release.
|
|
V= 5.3
|
|
@@ -58,11 +58,11 @@ test: dummy
|
|
src/lua -v
|
|
|
|
install: dummy
|
|
- cd src && $(MKDIR) $(INSTALL_BIN) $(INSTALL_INC) $(INSTALL_LIB) $(INSTALL_MAN) $(INSTALL_LMOD) $(INSTALL_CMOD)
|
|
- cd src && $(INSTALL_EXEC) $(TO_BIN) $(INSTALL_BIN)
|
|
- cd src && $(INSTALL_DATA) $(TO_INC) $(INSTALL_INC)
|
|
- cd src && $(INSTALL_DATA) $(TO_LIB) $(INSTALL_LIB)
|
|
- cd doc && $(INSTALL_DATA) $(TO_MAN) $(INSTALL_MAN)
|
|
+ cd src && $(MKDIR) $(DESTDIR)$(INSTALL_BIN) $(DESTDIR)$(INSTALL_INC) $(DESTDIR)$(INSTALL_LIB) $(DESTDIR)$(INSTALL_MAN) $(DESTDIR)$(INSTALL_LMOD) $(DESTDIR)$(INSTALL_CMOD)
|
|
+ cd src && $(LIBTOOL) --tag=CC --mode=install $(BSD_INSTALL_PROGRAM) $(TO_BIN) $(DESTDIR)$(INSTALL_BIN)
|
|
+ cd src && $(INSTALL_DATA) $(TO_INC) $(DESTDIR)$(INSTALL_INC)
|
|
+ cd src && $(LIBTOOL) --tag=CC --mode=install $(BSD_INSTALL_LIB) $(TO_LIB) $(DESTDIR)$(INSTALL_LIB)
|
|
+ cd doc && $(INSTALL_DATA) $(TO_MAN) $(DESTDIR)$(INSTALL_MAN)
|
|
|
|
uninstall:
|
|
cd src && cd $(INSTALL_BIN) && $(RM) $(TO_BIN)
|