1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-26 05:02:18 +00:00
freebsd-ports/databases/luadbi/Makefile
John Marino 746fd726c0 databases/luadbi is not jobs safe
I've witnessed this port fail two separate times because it doesn't ensure
that the "build" directory has been created before it starts constructing
object files.
2016-06-01 23:03:37 +00:00

63 lines
1.5 KiB
Makefile

# Created by: Olexander Melnyk <olexander.v.melnyk@gmail.com>
# $FreeBSD$
PORTNAME= luadbi
PORTVERSION= 0.5
PORTREVISION= 2
CATEGORIES= databases
MASTER_SITES= GOOGLE_CODE
DISTNAME= ${PORTNAME}.${PORTVERSION}
MAINTAINER= olexander.v.melnyk@gmail.com
COMMENT= LuaDBI driver
LICENSE= MIT
NO_WRKSUBDIR= yes
USES= gmake lua:51 shebangfix
SHEBANG_FILES= DBI.lua
MAKE_JOBS_UNSAFE= yes
CFLAGS+= -fpic -I${LOCALBASE}/include -I${LUA_INCDIR} -I. \
-I${LOCALBASE}/include/postgresql/server
LDFLAGS+= -shared -L${LOCALBASE}/lib -L${LUA_LIBDIR}
MAKE_ENV+= COMMON_LDFLAGS="${LDFLAGS}"
OPTIONS_MULTI= DATABASE
OPTIONS_MULTI_DATABASE= MYSQL SQLITE3 PGSQL
OPTIONS_DEFAULT= MYSQL
PLIST_FILES= %%LUA_MODSHAREDIR%%/DBI.lua
MYSQL_USE= MYSQL=yes
MYSQL_LDFLAGS= -L ${LOCALBASE}/lib/mysql
MYSQL_CFLAGS= -I ${LOCALBASE}/include/mysql
MYSQL_ALL_TARGET= mysql
MYSQL_PLIST_FILES= %%LUA_MODLIBDIR%%/dbdmysql.so
SQLITE3_USES= sqlite:3
SQLITE3_ALL_TARGET= sqlite3
SQLITE3_PLIST_FILES= %%LUA_MODLIBDIR%%/dbdsqlite3.so
PGSQL_USES= pgsql
PGSQL_ALL_TARGET= psql
PGSQL_PLIST_FILES= %%LUA_MODLIBDIR%%/dbdpostgresql.so
do-install:
@${MKDIR} ${STAGEDIR}${LUA_MODLIBDIR}
@${MKDIR} ${STAGEDIR}${LUA_MODSHAREDIR}
${CP} ${WRKSRC}/DBI.lua ${STAGEDIR}${LUA_MODSHAREDIR}
do-install-MYSQL-on:
${INSTALL_PROGRAM} ${WRKSRC}/dbdmysql.so ${STAGEDIR}${LUA_MODLIBDIR}
do-install-SQLITE3-on:
${INSTALL_PROGRAM} ${WRKSRC}/dbdsqlite3.so ${STAGEDIR}${LUA_MODLIBDIR}
do-install-PGSQL-on:
${INSTALL_PROGRAM} ${WRKSRC}/dbdpostgresql.so ${STAGEDIR}${LUA_MODLIBDIR}
.include <bsd.port.mk>