pkgsrc/databases/lua-lsqlite3/Makefile
nia ecb91bb49e databases: Add lua-lsqlite3
lsqlite3 is a thin wrapper around the public domain SQLite3 database engine.

The lsqlite3 module supports the creation and manipulation of SQLite3
databases.

After a require('lsqlite3') the exported functions are called with prefix
sqlite3.  However, most sqlite3 functions are called via an object-oriented
interface to either database or SQL statement objects.
2020-07-09 15:27:56 +00:00

40 lines
1.2 KiB
Makefile

# $NetBSD: Makefile,v 1.1 2020/07/09 15:27:56 nia Exp $
DISTNAME= lsqlite3_fsl09y
PKGNAME= ${LUA_PKGPREFIX}-lsqlite3-0.9.5
CATEGORIES= databases lua
MASTER_SITES= http://lua.sqlite.org/index.cgi/zip/
EXTRACT_SUFX= .zip
MAINTAINER= nia@NetBSD.org
HOMEPAGE= http://lua.sqlite.org/index.cgi/index
COMMENT= Binding for Lua to the SQLite3 database library
LICENSE= mit
INSTALLATION_DIRS+= ${LUA_CDIR} ${LUA_LDIR}
INSTALLATION_DIRS+= ${LUA_DOCDIR}/examples
pre-build:
# Don't use the internal copy of sqlite3
${RM} -f ${WRKSRC}/sqlite3.h
# Copy our makefile into place.
${CP} -f ${FILESDIR}/Makefile ${WRKSRC}/Makefile
pre-install:
# For compatibility with the statically linked variant.
${PRINTF} '%s\n' 'return require("lsqlite3")' > ${WRKSRC}/lsqlite3complete.lua
do-install:
${INSTALL_LIB} ${WRKSRC}/lsqlite3.so \
${DESTDIR}${PREFIX}/${LUA_CDIR}/lsqlite3.so
${INSTALL_LIB} ${WRKSRC}/lsqlite3complete.lua \
${DESTDIR}${PREFIX}/${LUA_LDIR}/lsqlite3complete.lua
${INSTALL_DATA} ${WRKSRC}/examples/*.lua \
${DESTDIR}${PREFIX}/${LUA_DOCDIR}/examples
do-test:
cd ${WRKSRC}/test && LUA_CPATH=${WRKSRC}/?.so ${LUA_INTERPRETER} test.lua
.include "../../lang/lua/module.mk"
.include "../../databases/sqlite3/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"