# $NetBSD: Makefile.common,v 1.9 2015/06/12 10:48:46 wiz Exp $
# used by databases/p5-sqlrelay/Makefile
# used by databases/php-sqlrelay/Makefile
# used by databases/py-sqlrelay/Makefile
# used by databases/ruby-sqlrelay/Makefile
# used by databases/sqlrelay-freetds/Makefile
# used by databases/sqlrelay-mysql/Makefile
# used by databases/sqlrelay-odbc/Makefile
# used by databases/sqlrelay-pgsql/Makefile
# used by databases/sqlrelay-sqlite/Makefile
# used by databases/sqlrelay/Makefile

DISTNAME=		sqlrelay-0.59
CATEGORIES=		databases
MASTER_SITES=		${MASTER_SITE_SOURCEFORGE:=sqlrelay/}

MAINTAINER=		filip@joyent.com
HOMEPAGE=		http://sqlrelay.sourceforge.net/
LICENSE=		gnu-gpl-v2 AND gnu-lgpl-v2

PKG_DESTDIR_SUPPORT=	user-destdir

GNU_CONFIGURE=		yes
USE_LANGUAGES=		c c++
USE_TOOLS+=		gmake
USE_LIBTOOL=		yes
BUILD_DEFS+=		VARBASE
MAKE_JOBS_SAFE=		no

DESCR_SRC=		${.CURDIR}/../../databases/sqlrelay/DESCR
DISTINFO_FILE=		${.CURDIR}/../../databases/sqlrelay/distinfo
PATCHDIR=		${.CURDIR}/../../databases/sqlrelay/patches

CONFIGURE_ARGS+=	--localstatedir=${VARBASE}
CONFIGURE_ARGS+=	--sysconfdir=${PKG_SYSCONFDIR}
CONFIGURE_ARGS+=	--with-rudiments-prefix=${BUILDLINK_PREFIX.rudiments}

PKG_SYSCONFSUBDIR=	sqlrelay
EGDIR=			${PREFIX}/share/examples/sqlrelay

.include "../../mk/compiler.mk"
.if !empty(PKGSRC_COMPILER:Mclang)
_WRAP_EXTRA_ARGS.CXX+=	-Wno-error=overloaded-virtual
CWRAPPERS_APPEND.cxx+=	-Wno-error=overloaded-virtual
.endif

.include "../../devel/pcre/buildlink3.mk"
.include "../../devel/rudiments/buildlink3.mk"
.include "../../devel/zlib/buildlink3.mk"
.include "../../security/openssl/buildlink3.mk"
.include "../../mk/pthread.buildlink3.mk"
.include "../../mk/readline.buildlink3.mk"
