Makefile 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. # $OpenBSD: Makefile,v 1.10 2016/09/23 09:16:53 sthen Exp $
  2. COMMENT-main= database interface library for Lua (including SQLite3)
  3. COMMENT-mysql= MySQL driver for luadbi
  4. COMMENT-pgsql= PostgreSQL driver for luadbi
  5. V= 0.5
  6. DISTNAME= luadbi.$V
  7. PKGNAME-main= luadbi-$V
  8. PKGNAME-mysql= luadbi-mysql-$V
  9. PKGNAME-pgsql= luadbi-pgsql-$V
  10. REVISION-main= 1
  11. REVISION-mysql= 3
  12. REVISION-pgsql= 0
  13. CATEGORIES= databases
  14. HOMEPAGE= https://luadbi.googlecode.com/
  15. # MIT
  16. PERMIT_PACKAGE_CDROM= Yes
  17. MASTER_SITES= ${HOMEPAGE}/files/
  18. MULTI_PACKAGES= -main -mysql -pgsql
  19. WANTLIB-main= sqlite3
  20. LIB_DEPENDS-main= databases/sqlite3
  21. RUN_DEPENDS-main= #empty
  22. WANTLIB-mysql= mysqlclient
  23. LIB_DEPENDS-mysql= databases/mariadb
  24. RUN_DEPENDS-mysql= ${BASE_PKGPATH},-main
  25. WANTLIB-pgsql= pq
  26. BUILD_DEPENDS= databases/postgresql,-server
  27. LIB_DEPENDS-pgsql= databases/postgresql
  28. RUN_DEPENDS-pgsql= ${BASE_PKGPATH},-main
  29. MODULES= lang/lua
  30. USE_GMAKE= Yes
  31. ALL_TARGET= free # == sqlite3 mysql postgresql
  32. NO_TEST= Yes
  33. MAKE_FLAGS= CC="${CC}" \
  34. COMMON_LDFLAGS="-L${LOCALBASE}/lib" \
  35. CFLAGS="${CFLAGS} -I${MODLUA_INCL_DIR} -I${LOCALBASE}/include -I${LOCALBASE}/include/mysql \
  36. -I${LOCALBASE}/include/postgresql/ -I${LOCALBASE}/include/postgresql/server \
  37. -I. -fpic -shared"
  38. WRKDIST= ${WRKDIR}
  39. do-install:
  40. ${INSTALL_DATA_DIR} ${MODLUA_LIBDIR} ${MODLUA_DATADIR}
  41. ${INSTALL_DATA} ${WRKSRC}/DBI.lua ${MODLUA_DATADIR}
  42. # XXX: Not using INSTALL_PROGRAM, it strips the library.
  43. ${INSTALL_SCRIPT} ${WRKSRC}/*.so ${MODLUA_LIBDIR}
  44. .include <bsd.port.mk>