2013-03-21 18:43:46 +01:00
|
|
|
# Created by: Domas Mituzas <midom@dammit.lt>
|
1999-11-26 21:52:39 +01:00
|
|
|
# $FreeBSD$
|
|
|
|
|
2000-04-09 00:49:07 +02:00
|
|
|
PORTNAME= freetds
|
2015-05-10 15:18:32 +02:00
|
|
|
PORTVERSION= 0.91.112.0.0
|
2008-12-06 23:43:44 +01:00
|
|
|
PORTEPOCH= 1
|
1999-11-26 21:52:39 +01:00
|
|
|
CATEGORIES= databases
|
2014-09-21 16:10:53 +02:00
|
|
|
MASTER_SITES= ftp://ftp.freetds.org/pub/freetds/stable/
|
1999-11-26 21:52:39 +01:00
|
|
|
|
2014-12-24 01:14:11 +01:00
|
|
|
MAINTAINER= bofh@FreeBSD.org
|
2003-02-20 18:07:10 +01:00
|
|
|
COMMENT= Sybase/Microsoft TDS protocol library
|
1999-11-26 21:52:39 +01:00
|
|
|
|
2014-09-21 16:10:53 +02:00
|
|
|
LICENSE= GPLv2
|
|
|
|
|
|
|
|
LIB_DEPENDS= libgcrypt.so:${PORTSDIR}/security/libgcrypt
|
|
|
|
|
2004-07-29 12:42:56 +02:00
|
|
|
TDS_VER?= 5.0
|
|
|
|
|
2015-05-10 15:18:32 +02:00
|
|
|
USES= autoreconf iconv gmake pkgconfig libtool:keepla tar:bzip2
|
2014-05-08 01:59:12 +02:00
|
|
|
GNU_CONFIGURE= yes
|
2011-09-24 00:26:39 +02:00
|
|
|
CPPFLAGS+= -I${LOCALBASE}/include
|
|
|
|
LDFLAGS+= -L${LOCALBASE}/lib
|
2014-09-21 16:10:53 +02:00
|
|
|
LIBS+= -lgcrypt
|
2014-09-27 10:31:58 +02:00
|
|
|
CONFIGURE_ARGS= --with-tdsver=${TDS_VER} --sysconfdir=${ETCDIR} \
|
|
|
|
--enable-sybase-compat --enable-msdblib
|
2007-10-05 22:25:32 +02:00
|
|
|
USE_LDCONFIG= yes
|
2014-05-08 01:59:12 +02:00
|
|
|
INSTALL_TARGET= install-strip
|
2001-02-14 13:48:45 +01:00
|
|
|
|
2009-03-03 06:55:42 +01:00
|
|
|
PORTDOCS= *
|
|
|
|
|
2015-05-10 15:18:32 +02:00
|
|
|
OPTIONS_DEFINE= DOCS
|
|
|
|
OPTIONS_SINGLE= SSL
|
|
|
|
OPTIONS_SINGLE_SSL= OPENSSL GNUTLS
|
|
|
|
OPTIONS_DEFAULT= OPENSSL
|
2014-09-21 16:10:53 +02:00
|
|
|
OPTIONS_RADIO= ODBC
|
2013-03-21 18:43:46 +01:00
|
|
|
OPTIONS_RADIO_ODBC= IODBC UNIXODBC
|
2014-09-21 16:10:53 +02:00
|
|
|
OPENSSL_USE= OPENSSL=yes
|
|
|
|
OPENSSL_CONFIGURE_ON= --with-openssl=${OPENSSLBASE}
|
|
|
|
GNUTLS_LIB_DEPENDS= libgnutls.so:${PORTSDIR}/security/gnutls
|
|
|
|
GNUTLS_CONFIGURE_ON= --with-gnutls
|
|
|
|
IODBC_LIB_DEPENDS= libiodbc.so:${PORTSDIR}/databases/libiodbc
|
|
|
|
IODBC_CONFIGURE_ON= --with-iodbc=${LOCALBASE}
|
|
|
|
IODBC_CPPFLAGS= -I${LOCALBASE}/include/libiodbc
|
|
|
|
UNIXODBC_LIB_DEPENDS= libodbc.so:${PORTSDIR}/databases/unixODBC
|
|
|
|
UNIXODBC_CONFIGURE_ON= --with-unixodbc=${LOCALBASE}
|
2009-03-03 06:55:42 +01:00
|
|
|
|
2013-03-21 18:43:46 +01:00
|
|
|
.include <bsd.port.options.mk>
|
2009-03-03 06:55:42 +01:00
|
|
|
|
2013-04-04 15:37:18 +02:00
|
|
|
.if ${PORT_OPTIONS:MIODBC} || ${PORT_OPTIONS:MUNIXODBC}
|
2001-12-24 05:40:36 +01:00
|
|
|
PLIST_SUB+= ODBC=""
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= ODBC="@comment "
|
|
|
|
.endif
|
|
|
|
|
2002-09-19 22:33:32 +02:00
|
|
|
post-extract:
|
2014-09-21 16:10:53 +02:00
|
|
|
@cd ${WRKSRC} && ${LN} -s freetds.conf freetds.conf.sample
|
|
|
|
@cd ${WRKSRC} && ${LN} -s locales.conf locales.conf.sample
|
|
|
|
@cd ${WRKSRC}/src/pool && ${LN} -s pool.conf pool.conf.sample
|
2002-09-19 22:33:32 +02:00
|
|
|
|
2001-02-14 13:48:45 +01:00
|
|
|
post-patch:
|
2015-05-10 15:18:32 +02:00
|
|
|
@${FIND} ${WRKSRC} -name "Makefile.am" | ${XARGS} ${REINPLACE_CMD} -e \
|
2002-10-08 11:10:00 +02:00
|
|
|
's|<malloc.h>|<stdlib.h>| ; \
|
2014-09-21 16:10:53 +02:00
|
|
|
s|/freetds.conf|/freetds.conf.sample|g ; \
|
|
|
|
s|/locales.conf|/locales.conf.sample|g ; \
|
|
|
|
s|/pool.conf|/pool.conf.sample|g ; \
|
2001-12-24 05:40:36 +01:00
|
|
|
s| common.h||g'
|
2014-09-21 16:10:53 +02:00
|
|
|
@${REINPLACE_CMD} -e 's|$$ODBC_INC/isql.h|$$ODBC_INC/libiodbc/isql.h|g ; \
|
|
|
|
s|$$ODBC_INC/isqlext.h|$$ODBC_INC/libiodbc/isqlext.h|g' ${WRKSRC}/configure
|
2003-11-07 09:26:27 +01:00
|
|
|
|
2001-08-05 06:28:23 +02:00
|
|
|
post-install:
|
2015-05-10 15:18:32 +02:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/interfaces ${STAGEDIR}${ETCDIR}/interfaces.sample
|
2014-09-21 16:10:53 +02:00
|
|
|
.if ${PORT_OPTIONS:MDOCS}
|
|
|
|
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
2015-05-10 15:18:32 +02:00
|
|
|
(cd ${WRKSRC}/doc/doc/${PORTNAME}-${PORTVERSION} && \
|
2014-09-21 16:10:53 +02:00
|
|
|
${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
|
|
|
|
.endif
|
1999-11-26 21:52:39 +01:00
|
|
|
|
2013-03-21 18:43:46 +01:00
|
|
|
.include <bsd.port.mk>
|