[BACK]Return to Makefile CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / databases / lua-lsqlite3

File: [cvs.NetBSD.org] / pkgsrc / databases / lua-lsqlite3 / Makefile (download)

Revision 1.9, Wed Nov 23 16:19:35 2022 UTC (2 months, 1 week ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2022Q4-base, pkgsrc-2022Q4, HEAD
Changes since 1.8: +2 -2 lines

massive revision bump after textproc/icu update

# $NetBSD: Makefile,v 1.9 2022/11/23 16:19:35 adam Exp $

DISTNAME=	lsqlite3_fsl09y
PKGNAME=	${LUA_PKGPREFIX}-lsqlite3-0.9.5
PKGREVISION=	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"