Optionally build the ODBC driver for freetds. This will allow ODBC

clients to load the driver to talk to MS SQL Server.
This commit is contained in:
jlam 2005-12-30 21:07:42 +00:00
parent 6516295733
commit b8c78246e7
3 changed files with 38 additions and 2 deletions

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.30 2005/12/30 16:39:39 jlam Exp $
# $NetBSD: Makefile,v 1.31 2005/12/30 21:07:42 jlam Exp $
DISTNAME= freetds-0.63
PKGREVISION= 2
@ -12,6 +12,8 @@ COMMENT= LGPL'd implementation of Sybase's db-lib/ct-lib/ODBC libs
USE_LIBTOOL= yes
USE_TOOLS+= gmake
.include "options.mk"
GNU_CONFIGURE= yes
CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR:Q}
CONFIGURE_ARGS+= --datadir=${PREFIX}/share

View file

@ -1,4 +1,4 @@
@comment $NetBSD: PLIST,v 1.13 2005/12/27 21:04:23 reed Exp $
@comment $NetBSD: PLIST,v 1.14 2005/12/30 21:07:42 jlam Exp $
bin/bsqldb
bin/defncopy
bin/freebcp
@ -21,6 +21,7 @@ include/tdsver.h
lib/libct.la
lib/libsybdb.la
lib/libtds.la
${ODBC}lib/libtdsodbc.la
lib/libtdssrv.la
man/man1/bsqldb.1
man/man1/defncopy.1

View file

@ -0,0 +1,33 @@
# $NetBSD: options.mk,v 1.1 2005/12/30 21:07:42 jlam Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.freetds
PKG_OPTIONS_OPTIONAL_GROUPS+= odbc
PKG_OPTIONS_GROUP.odbc= iodbc #unixodbc
.include "../../mk/bsd.options.mk"
###
### Whether to build with iODBC to enable ODBC access to TDS servers.
###
.if !empty(PKG_OPTIONS:Miodbc)
ODBC_DRIVER= yes
. include "../../databases/iodbc/buildlink3.mk"
CONFIGURE_ARGS+= --enable-odbc
CONFIGURE_ARGS+= --with-iodbc=${BUILDLINK_PREFIX.iodbc}
PLIST_SUBST+= ODBC=
.endif
###
### Whether to build with unixODBC to enable ODBC access to TDS servers.
###
.if !empty(PKG_OPTIONS:Munixodbc)
. include "../../databases/unixodbc/buildlink3.mk"
CONFIGURE_ARGS+= --enable-odbc
CONFIGURE_ARGS+= --with-unixodbc=${BUILDLINK_PREFIX.unixodbc}
PLIST_SUBST+= ODBC=
.endif
.if empty(PKG_OPTIONS:Miodbc) && empty(PKG_OPTIONS:Munixodbc)
CONFIGURE_ARGS+= --disable-odbc
PLIST_SUBST+= ODBC="@comment "
.endif