svn commit: r359255 - in head: contrib/lutok lib lib/liblutok share/mk

Brooks Davis brooks at FreeBSD.org
Mon Mar 23 18:26:25 UTC 2020


Author: brooks
Date: Mon Mar 23 18:26:23 2020
New Revision: 359255
URL: https://svnweb.freebsd.org/changeset/base/359255

Log:
  Add liblutok a lightweight C++ API for lua.
  
  It is added an INTERNALLIB and not installed.  It will be used by kyua.
  
  This is a preparatory commit for D24103.
  
  Reviewed by:	emaste
  Obtained from:	CheriBSD
  Sponsored by:	DARPA

Added:
  head/contrib/lutok/
     - copied from r359045, vendor/lutok/dist/
  head/lib/liblutok/
  head/lib/liblutok/Makefile   (contents, props changed)
Modified:
  head/lib/Makefile
  head/share/mk/src.libnames.mk

Modified: head/lib/Makefile
==============================================================================
--- head/lib/Makefile	Mon Mar 23 18:17:56 2020	(r359254)
+++ head/lib/Makefile	Mon Mar 23 18:26:23 2020	(r359255)
@@ -205,6 +205,7 @@ SUBDIR.${MK_RADIUS_SUPPORT}+=	libradius
 SUBDIR.${MK_SENDMAIL}+=	libmilter libsm libsmdb libsmutil
 SUBDIR.${MK_TELNET}+=	libtelnet
 SUBDIR.${MK_TESTS_SUPPORT}+=	atf
+SUBDIR.${MK_TESTS_SUPPORT}.${MK_CXX}+=	liblutok
 SUBDIR.${MK_TESTS}+=	tests
 SUBDIR.${MK_UNBOUND}+=	libunbound
 SUBDIR.${MK_USB}+=	libusbhid libusb

Added: head/lib/liblutok/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/lib/liblutok/Makefile	Mon Mar 23 18:26:23 2020	(r359255)
@@ -0,0 +1,26 @@
+# $FreeBSD$
+
+LIB_CXX=	lutok
+INTERNALLIB=
+
+LIBADD=		lua
+
+.PATH: ${SRCTOP}/contrib/lutok
+SRCS=	c_gate.cpp		\
+	debug.cpp		\
+	exceptions.cpp		\
+	operations.cpp		\
+	stack_cleaner.cpp	\
+	state.cpp
+
+CFLAGS+=	-I${SRCTOP}/contrib/lutok/include \
+		-I${SRCTOP}/lib/liblua	\
+		-I${SRCTOP}/contrib/lua/src
+
+WARNS?=	3
+SHLIB_MAJOR=	0
+
+# lutok uses auto_ptr
+CFLAGS+=	-Wno-deprecated-declarations
+
+.include <bsd.lib.mk>

Modified: head/share/mk/src.libnames.mk
==============================================================================
--- head/share/mk/src.libnames.mk	Mon Mar 23 18:17:56 2020	(r359254)
+++ head/share/mk/src.libnames.mk	Mon Mar 23 18:26:23 2020	(r359255)
@@ -42,6 +42,7 @@ _INTERNALLIBS=	\
 		ipf \
 		lpr \
 		lua \
+		lutok \
 		netbsd \
 		ntp \
 		ntpevent \
@@ -295,6 +296,7 @@ _DP_magic=	z
 _DP_mt=		sbuf bsdxml
 _DP_ldns=	ssl crypto
 _DP_lua=	m
+_DP_lutok=	lua
 .if ${MK_OPENSSL} != "no"
 _DP_fetch=	ssl crypto
 .else
@@ -472,6 +474,9 @@ LIBELFTC?=	${LIBELFTCDIR}/libelftc${PIE_SUFFIX}.a
 
 LIBLUADIR=	${_LIB_OBJTOP}/lib/liblua
 LIBLUA?=	${LIBLUADIR}/liblua${PIE_SUFFIX}.a
+
+LIBLUTOKDIR=	${_LIB_OBJTOP}/lib/liblutok
+LIBLUTOK?=	${LIBLUTOKDIR}/liblutok${PIE_SUFFIX}.a
 
 LIBPEDIR=	${_LIB_OBJTOP}/lib/libpe
 LIBPE?=		${LIBPEDIR}/libpe${PIE_SUFFIX}.a


More information about the svn-src-all mailing list