Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F137923360
D14709.id40372.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
5 KB
Referenced Files
None
Subscribers
None
D14709.id40372.diff
View Options
Index: lua54/Makefile
===================================================================
--- lua54/Makefile
+++ lua54/Makefile
@@ -0,0 +1,68 @@
+# Created by: russ.haley@gmail.com
+# Date: 2018-03-14
+# $FreeBSD$
+
+PORTNAME= lua
+PORTVERSION= 5.4.0
+PORTREVISION= 1
+CATEGORIES= lang
+MASTER_SITES= https://www.lua.org/work/
+DISTVERSIONSUFFIX=-work1
+PKGNAMESUFFIX= 54
+
+MAINTAINER= russ.haley@gmail.com
+COMMENT= Small, embeddable scripting language providing easy access to C code
+
+LICENSE= MIT
+
+LUA_VER= 5.4
+USE_LDCONFIG= yes
+
+# Overriding __MAKE_CONF makes sure that we don't re-parse
+# /etc/make.conf during do-build, which would jeopardize the build
+# if, for instance, the user set CFLAGS=mumble
+# NOTE: /etc/make.conf is read BEFORE Makefile, so we already
+# have its settings when we get here.
+# See http://wiki.freebsd.org/MatthiasAndree/LuaLessonsLearnt
+MAKE_ARGS= __MAKE_CONF=${NONEXISTENT}
+
+BUILD_WRKSRC= ${WRKSRC}/src
+LUA_CMD = ${PORTNAME}${PKGNAMESUFFIX}
+LUAC_CMD = ${PORTNAME}c${PKGNAMESUFFIX}
+LUA_LIB_STATIC=liblua-${LUA_VER}.a
+LUA_LIB_SHARED=liblua-${LUA_VER}.so
+LUA_PC_FILE=${PORTNAME}-${LUA_VER}.pc
+ALL_TARGET=freebsd
+
+#LUA_NILINTABLE=-DLUA_NILINTABLE
+
+MAKE_ARGS+= CC="${CC}" \
+ MYCFLAGS="${LUA_NILINTABLE} -fPIC -I/usr/include/edit"\
+ MYLIBS=-ledit \
+ LUA_T=${LUA_CMD}\
+ LUAC_T=${LUAC_CMD} \
+ LUA_A=${LUA_LIB_STATIC} \
+ LUA_SO=${LUA_LIB_SHARED} \
+ LUA_SONAME=${LUA_LIB_SHARED} \
+ TO_BIN="${LUA_CMD} ${LUAC_CMD}" \
+ TO_LIB="${LUA_LIB_SHARED} ${LUA_LIB_STATIC}" \
+ INSTALL_TOP=${STAGEDIR}${PREFIX} \
+ INSTALL_INC=${STAGEDIR}${PREFIX}/include/${PORTNAME}${PKGNAMESUFFIX} \
+ INSTALL_EXEC="${INSTALL_PROGRAM}"
+
+SUB_FILES= ${LUA_PC_FILE}
+SUB_LIST= version=${PORTVERSION} \
+ includedir=${LUA_INCDIR} \
+ libdir=${LUA_LIBDIR} \
+ soname=${PORTNAME}-${LUA_VER}
+
+post-install:
+ @${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/${LUA_LIB_SHARED}
+ @${MV} ${STAGEDIR}${PREFIX}/man/man1/lua.1 \
+ ${STAGEDIR}${PREFIX}/man/man1/${LUA_CMD}.1
+ @${MV} ${STAGEDIR}${PREFIX}/man/man1/luac.1 \
+ ${STAGEDIR}${PREFIX}/man/man1/${LUAC_CMD}.1
+ ${INSTALL_DATA} ${WRKDIR}/${LUA_PC_FILE} \
+ ${STAGEDIR}${PREFIX}/libdata/pkgconfig
+
+.include <bsd.port.mk>
Index: lua54/distinfo
===================================================================
--- lua54/distinfo
+++ lua54/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1521177371
+SHA256 (lua-5.4.0-work1.tar.gz) = ada03980481110bfde44b3bd44bde4b03d72c84318b34d657b5b5a91ddb3912c
+SIZE (lua-5.4.0-work1.tar.gz) = 319225
Index: lua54/files/lua-5.4.pc.in
===================================================================
--- lua54/files/lua-5.4.pc.in
+++ lua54/files/lua-5.4.pc.in
@@ -0,0 +1,10 @@
+version=%%version%%
+libdir=%%libdir%%
+includedir=%%includedir%%
+soname=%%soname%%
+
+Name: Lua
+Description: A small embeddable language
+Version: ${version}
+Libs: -L${libdir} -l${soname} -lm
+Cflags: -I${includedir}
Index: lua54/files/patch-src_Makefile
===================================================================
--- lua54/files/patch-src_Makefile
+++ lua54/files/patch-src_Makefile
@@ -0,0 +1,36 @@
+--- src/Makefile.orig 2018-03-12 18:06:03 UTC
++++ src/Makefile
+@@ -35,12 +35,13 @@ BASE_O= $(CORE_O) $(LIB_O) $(MYOBJS)
+
+ LUA_T= lua
+ LUA_O= lua.o
++LUA_SO= liblua.so
+
+ LUAC_T= luac
+ LUAC_O= luac.o
+
+ ALL_O= $(BASE_O) $(LUA_O) $(LUAC_O)
+-ALL_T= $(LUA_A) $(LUA_T) $(LUAC_T)
++ALL_T= $(LUA_A) $(LUA_T) $(LUAC_T) $(LUA_SO)
+ ALL_A= $(LUA_A)
+
+ # Targets start here.
+@@ -52,6 +53,9 @@ o: $(ALL_O)
+
+ a: $(ALL_A)
+
++$(LUA_SO): $(CORE_O) $(LIB_O)
++ $(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(MYLDFLAGS) -shared -Wl,-soname=$(LUA_SONAME) $?
++
+ $(LUA_A): $(BASE_O)
+ $(AR) $@ $(BASE_O)
+ $(RANLIB) $@
+@@ -99,7 +103,7 @@ c89:
+
+
+ freebsd:
+- $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX -DLUA_USE_READLINE" SYSLIBS="-Wl,-E -lreadline"
++ $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX -DLUA_USE_READLINE" SYSLIBS="-Wl,-E"
+
+ generic: $(ALL)
+
Index: lua54/pkg-descr
===================================================================
--- lua54/pkg-descr
+++ lua54/pkg-descr
@@ -0,0 +1,21 @@
+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.
+
+WWW: http://www.lua.org/
Index: lua54/pkg-plist
===================================================================
--- lua54/pkg-plist
+++ lua54/pkg-plist
@@ -0,0 +1,14 @@
+bin/lua54
+bin/luac54
+include/lua54/lauxlib.h
+include/lua54/lua.h
+include/lua54/lua.hpp
+include/lua54/luaconf.h
+include/lua54/lualib.h
+lib/liblua-5.4.a
+lib/liblua-5.4.so
+libdata/pkgconfig/lua-5.4.pc
+man/man1/lua54.1.gz
+man/man1/luac54.1.gz
+@dir lib/lua/5.4
+@dir %%DATADIR%%/5.4
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 28, 7:19 AM (19 h, 17 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26277144
Default Alt Text
D14709.id40372.diff (5 KB)
Attached To
Mode
D14709: [new port] lang/lua54 - new port for Lua 5.4.0
Attached
Detach File
Event Timeline
Log In to Comment