1999-11-26 21:52:39 +01:00
|
|
|
# New ports collection makefile for: freetds
|
|
|
|
# Date created: 02 Nov 1999
|
|
|
|
# Whom: Domas Mituzas <midom@dammit.lt>
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
|
2000-04-09 00:49:07 +02:00
|
|
|
PORTNAME= freetds
|
2005-04-11 22:52:27 +02:00
|
|
|
PORTVERSION= 0.63
|
1999-11-26 21:52:39 +01:00
|
|
|
CATEGORIES= databases
|
|
|
|
MASTER_SITES= ${MASTER_SITE_SUNSITE}
|
2003-04-11 17:51:25 +02:00
|
|
|
MASTER_SITE_SUBDIR= ALPHA/freetds/stable
|
1999-11-26 21:52:39 +01:00
|
|
|
|
2004-01-15 19:28:02 +01:00
|
|
|
MAINTAINER?= kiesel@schlund.de
|
2003-02-20 18:07:10 +01:00
|
|
|
COMMENT= Sybase/Microsoft TDS protocol library
|
1999-11-26 21:52:39 +01:00
|
|
|
|
2004-07-29 12:42:56 +02:00
|
|
|
TDS_VER?= 5.0
|
|
|
|
|
2004-03-30 21:20:22 +02:00
|
|
|
USE_ICONV= yes
|
2002-09-01 18:07:59 +02:00
|
|
|
USE_REINPLACE= yes
|
2002-09-19 22:33:32 +02:00
|
|
|
USE_GMAKE= yes
|
2003-11-07 09:26:27 +01:00
|
|
|
GNU_GONFIGURE= yes
|
2005-11-15 07:52:12 +01:00
|
|
|
USE_AUTOTOOLS= autoconf:259:env libtool:15
|
2001-12-24 05:40:36 +01:00
|
|
|
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
|
|
|
|
LDFLAGS="-L${LOCALBASE}/lib"
|
2004-07-29 12:42:56 +02:00
|
|
|
CONFIGURE_ARGS= --with-tdsver=${TDS_VER}
|
2001-02-14 13:48:45 +01:00
|
|
|
INSTALLS_SHLIB= yes
|
|
|
|
|
2005-04-11 22:52:27 +02:00
|
|
|
DOCSDIR= ${PREFIX}/share/doc/${PORTNAME}-0.63
|
|
|
|
MAN1= freebcp.1 tsql.1 bsqldb.1 defncopy.1
|
2002-09-19 22:33:32 +02:00
|
|
|
|
2001-12-24 05:40:36 +01:00
|
|
|
.if defined(WITH_IODBC)
|
|
|
|
LIB_DEPENDS+= iodbc:${PORTSDIR}/databases/libiodbc
|
|
|
|
CONFIGURE_ARGS+= --with-iodbc=${LOCALBASE}
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITH_UNIXODBC)
|
|
|
|
LIB_DEPENDS+= odbc:${PORTSDIR}/databases/unixODBC
|
|
|
|
CONFIGURE_ARGS+= --with-unixodbc=${LOCALBASE}
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(WITH_IODBC) || defined(WITH_UNIXODBC)
|
|
|
|
PLIST_SUB+= ODBC=""
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= ODBC="@comment "
|
|
|
|
.endif
|
|
|
|
|
2005-04-11 22:52:27 +02:00
|
|
|
# We cannot use msdblib-style by default, because port databases/sybtcl
|
|
|
|
# relies on sybase-style dblib
|
2004-01-15 19:28:02 +01:00
|
|
|
.if defined(WITH_MSDBLIB)
|
|
|
|
CONFIGURE_ARGS+= --enable-msdblib
|
|
|
|
.endif
|
|
|
|
|
2002-09-19 22:33:32 +02:00
|
|
|
post-extract:
|
|
|
|
@cd ${WRKSRC} && ${LN} -s freetds.conf freetds.conf.dist
|
2003-04-21 18:07:04 +02:00
|
|
|
@cd ${WRKSRC} && ${LN} -s locales.conf locales.conf.dist
|
|
|
|
@cd ${WRKSRC}/src/pool && ${LN} -s pool.conf pool.conf.dist
|
2002-09-19 22:33:32 +02:00
|
|
|
|
2001-02-14 13:48:45 +01:00
|
|
|
post-patch:
|
2002-09-01 18:07:59 +02:00
|
|
|
@${FIND} ${WRKSRC} -name "Makefile.in" | ${XARGS} ${REINPLACE_CMD} -e \
|
2002-10-08 11:10:00 +02:00
|
|
|
's|<malloc.h>|<stdlib.h>| ; \
|
|
|
|
s|/freetds.conf|/freetds.conf.dist|g ; \
|
2003-04-21 18:07:04 +02:00
|
|
|
s|/locales.conf|/locales.conf.dist|g ; \
|
|
|
|
s|/pool.conf|/pool.conf.dist|g ; \
|
2001-12-24 05:40:36 +01:00
|
|
|
s| common.h||g'
|
2004-01-15 19:28:02 +01:00
|
|
|
.if defined(NOPORTDOCS)
|
|
|
|
@${REINPLACE_CMD} -e "s|\(install-data-am:\).*|\1 install-man|g" \
|
|
|
|
${WRKSRC}/doc/Makefile.in
|
|
|
|
.endif
|
2003-11-07 09:26:27 +01:00
|
|
|
|
2001-08-05 06:28:23 +02:00
|
|
|
post-install:
|
2001-12-24 05:40:36 +01:00
|
|
|
@${MKDIR} ${PREFIX}/etc/freetds
|
2003-04-21 18:07:04 +02:00
|
|
|
@${INSTALL_DATA} ${WRKSRC}/interfaces ${PREFIX}/etc/freetds/interfaces.dist
|
|
|
|
@${ECHO_CMD} "Sample configuration files have been installed in ${PREFIX}/etc"
|
|
|
|
@${ECHO_CMD} "You should edit them and remove the .dist-suffix from their names"
|
1999-11-26 21:52:39 +01:00
|
|
|
|
|
|
|
.include <bsd.port.mk>
|