Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Jul 2003 13:29:57 +0200
From:      "Clement Laforet" <sheepkiller@cultdeadsheep.org>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        Clement Laforet <sheepkiller@cultdeadsheep.org>
Subject:   ports/55044: [update] mail/perdition: update mysql hack to "lastest revision".
Message-ID:  <20030730112953.B7A1743FCB@mx1.FreeBSD.org>
Resent-Message-ID: <200307301130.h6UBUAnW005717@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         55044
>Category:       ports
>Synopsis:       [update] mail/perdition: update mysql hack to "lastest revision".
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jul 30 04:30:10 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator:     Clement Laforet
>Release:        FreeBSD 5.1-CURRENT i386
>Organization:
cotds.org
>Environment:
System: FreeBSD chuck.cultdeadsheep.org 5.1-CURRENT FreeBSD 5.1-CURRENT #0: Mon Jul 14 03:00:24 CEST 2003 clement@chuck.cultdeadsheep.org:/usr/obj/usr/src/sys/CHUCK i386


	
>Description:
	Add simplisitic MySQL auto detection hack to perdition.
>How-To-Repeat:
	N/A.
>Fix:

	

--- perdition.diff begins here ---
diff -Nru perdition.orig/Makefile perdition/Makefile
--- perdition.orig/Makefile	Wed Jul 30 11:14:31 2003
+++ perdition/Makefile	Wed Jul 30 11:17:46 2003
@@ -7,6 +7,7 @@
 
 PORTNAME=	perdition
 PORTVERSION=	1.11
+PORTREVISION=	1
 CATEGORIES=	mail net security
 MASTER_SITES=	http://www.vergenet.net/linux/perdition/download/${PORTVERSION}/
 
@@ -34,14 +35,6 @@
 
 INSTALLS_SHLIB=	yes
 
-# Dirty hack :)
-MYSQL323_LIBVER=10
-MYSQL40_LIBVER=	12
-MYSQL41_LIBVER=	14
-
-MYSQL_VER?=	323
-LDAP_VER?=	21
-
 # Available knobs:
 # WITHOUT_SSL: Disable OpenSSL support
 # WITHOUT_POSIX_REGEX: Disable native regex support
@@ -49,10 +42,35 @@
 # WITH_NIS: Enable NIS database backend
 # WITH_GDBM: Enable gdbm database backend
 # WITH_MYSQL: Enable MySQL database backend
+# WITH_MYSQL_VER:
+#		- 323 use MySQL 3.23.x
+#		- 40 use MySQL 4.0.x
+#		- 41 use MySQL 4.1.x
 # WITH_PGSQL: Enable PostgreSQL database backend
 # WITH_OPENLDAP: Enable OpenLDAP database backend
 # WITH_ODBC: Enable ODBC database backend
 
+LDAP_VER?=	21
+
+# MySQL deps hack (revision 2)
+MYSQL323_LIBVER=10
+MYSQL40_LIBVER= 12
+MYSQL41_LIBVER= 14
+
+.include <bsd.port.pre.mk>
+
+.if defined(WITH_MYSQL_VER)
+MYSQL_VER=	${WITH_MYSQL_VER}
+.elif exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.${MYSQL_323_LIBVER})
+MYSQL_VER=	323
+.elif exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.${MYSQL40_LIBVER})
+MYSQL_VER=	40
+.elif exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.${MYSQL41_LIBVER})
+MYSQL_VER=	41
+.else
+MYSQL_VER=	40
+.endif
+
 .if !defined(WITHOUT_SSL)
 CONFIGURE_ARGS+=	--enable-ssl
 USE_OPENSSL=		yes
@@ -146,4 +164,4 @@
 	@${ECHO_MSG} "/********************************************************/"
 	@${ECHO_MSG} ""
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
--- perdition.diff ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030730112953.B7A1743FCB>