openbsd-ports/databases/mysql/Makefile

107 lines
2.5 KiB
Makefile
Raw Normal View History

2006-01-05 19:13:26 -05:00
# $OpenBSD: Makefile,v 1.114 2006/01/06 00:13:26 brad Exp $
# Uses pthreads
.if ${MACHINE_ARCH} == "hppa" || ${MACHINE_ARCH} == "m88k"
BROKEN= "gen_lex_hash hangs"
.endif
COMMENT= "multithreaded SQL database (client)"
COMMENT-server= "multithreaded SQL database (server)"
2002-02-20 13:03:32 -05:00
COMMENT-tests= "multithreaded SQL database (regression test suite)"
2006-01-05 19:13:26 -05:00
VERSION= 5.0.18
DISTNAME= mysql-${VERSION}
2006-01-05 19:13:26 -05:00
FULLPKGNAME= mysql-client-${VERSION}
2005-12-11 23:55:43 -05:00
PKGNAME-server= mysql-server-${VERSION}
FULLPKGNAME-tests= mysql-tests-${VERSION}
CATEGORIES= databases
2006-01-05 19:13:26 -05:00
V= MySQL-5.0
SHARED_LIBS= mysqlclient 15.0 \
mysqlclient_r 15.0
2005-12-26 16:32:00 -05:00
MASTER_SITES= http://mysql.mirrors.pair.com/Downloads/$V/
HOMEPAGE= http://www.mysql.com/
2000-09-24 03:03:59 -04:00
MAINTAINER= Brad Smith <brad@openbsd.org>
2002-12-14 18:56:43 -05:00
# GPL
PERMIT_PACKAGE_CDROM= Yes
PERMIT_PACKAGE_FTP= Yes
PERMIT_DISTFILES_CDROM= Yes
PERMIT_DISTFILES_FTP= Yes
2005-01-25 11:01:07 -05:00
WANTLIB= c crypto m pthread ssl z
2000-02-14 17:32:08 -05:00
DB_DIR?= /var/mysql
SOCKET_DIR= /var/run/mysql
SUBST_VARS= DB_DIR SOCKET_DIR VERSION
# Suggested flags for the C compiler, needed for
# high load servers otherwise MySQL will crash.
CXX= ${CC}
CXXFLAGS= ${CFLAGS} -felide-constructors -fno-exceptions -fno-rtti
VMEM_WARNING= Yes
USE_GMAKE= Yes
2005-12-26 16:32:00 -05:00
USE_LIBTOOL= Yes
CONFIGURE_STYLE= autoconf
AUTOCONF_VERSION= 2.59
CONFIGURE_ARGS+= ${CONFIGURE_SHARED}
CONFIGURE_ARGS+= --enable-thread-safe-client \
--localstatedir="${DB_DIR}" \
2006-01-05 19:13:26 -05:00
--with-big-tables \
--with-comment='OpenBSD port: ${FULLPKGNAME-server}' \
--with-libwrap \
2005-12-11 23:55:43 -05:00
--with-low-memory \
2003-08-26 20:14:49 -04:00
--with-mysqld-user="_mysql" \
--with-openssl \
--with-unix-socket-path="${SOCKET_DIR}/mysql.sock" \
--with-vio \
--without-bench \
2002-12-14 18:56:43 -05:00
--without-debug \
--without-docs \
--without-extra-tools \
2002-12-14 18:56:43 -05:00
--without-readline
2003-12-28 17:17:50 -05:00
.include <bsd.own.mk>
2003-12-28 17:17:50 -05:00
USE_GCC3?= No
2003-12-28 17:17:50 -05:00
.if ${USE_GCC3:L} == "yes"
2004-01-06 09:13:03 -05:00
CONFIGURE_ARGS+= --with-client-ldflags=-lsupc++ \
--with-mysqld-ldflags=-lsupc++
2003-12-28 17:17:50 -05:00
.endif
. if ${MACHINE_ARCH} == "i386"
CONFIGURE_ARGS+= --enable-assembler
.endif
2001-07-22 16:35:29 -04:00
MULTI_PACKAGES= -server -tests
SUBPACKAGE?=
.if ${SUBPACKAGE} == "-server"
2006-01-05 19:13:26 -05:00
RUN_DEPENDS= :mysql-client-5.0.*:databases/mysql \
2003-12-30 15:42:48 -05:00
:p5-DBD-mysql-*:databases/p5-DBD-mysql
2005-01-25 11:01:07 -05:00
WANTLIB+= wrap
.elif empty(SUBPACKAGE)
WANTLIB+= ncurses readline
.endif
.if defined(PACKAGING) && ${SUBPACKAGE} == "-tests"
PKG_ARCH= *
2005-01-25 11:01:07 -05:00
WANTLIB=
.endif
DOCS= manual.html manual.ps manual_toc.html manual.txt
post-install:
2005-12-26 16:32:00 -05:00
cd ${PREFIX}/lib && \
ln -sf mysql/libmysqlclient.so.${LIBmysqlclient_VERSION} . && \
ln -sf mysql/libmysqlclient_r.so.${LIBmysqlclient_r_VERSION} .
2002-02-08 19:50:14 -05:00
do-regress:
@cd ${WRKSRC}/mysql-test && ./mysql-test-run --force
2002-02-08 19:50:14 -05:00
.include <bsd.port.mk>