ports/58415: [PATCH] Support for Mysql4client and OpenSSL crypto
Melvyn Sopacua
mdev at idg.nl
Thu Oct 23 08:10:14 UTC 2003
>Number: 58415
>Category: ports
>Synopsis: [PATCH] Support for Mysql4client and OpenSSL crypto
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Thu Oct 23 01:10:11 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator: Melvyn Sopacua
>Release: FreeBSD 4.8-RELEASE-p13 i386
>Organization:
IDG.nl
>Environment:
System: FreeBSD server22.idg.nl 4.8-RELEASE-p13 FreeBSD 4.8-RELEASE-p13 #0: Mon Oct 13 08:57:29 CEST 2003 root at server22.idg.nl:/usr/obj/usr/src/sys/SERVER22 i386
>Description:
Currently Proftpd port cannot be built with OpenSSL support to
facilitate stronger password hashes in authentication modules.
Additionally the mod_sql_mysql dependency is hardcoded to the
"older" release (in terms of mysql releases) of mysql 3.
>How-To-Repeat:
(cd /usr/ports/ftp/proftpd && make -DWITH_MYSQL)
>Fix:
The following patch adds a switch for Mysql 4 selection and adds
a switch to allow Openssl integration.
As indicated I've made this a generic construct, so that additional
dependencies may be added in the same way. I currently do not have
any knowledge of such dependencies, but the proftpd configure.in
script, makes provisions for these at line 105:
AC_ARG_VAR(LIBS, [linker flags, e.g. -l<lib>.{a,so} if you have nonstandard libraries to link])
It also allows custom modules to be integrated fairly easy, by
modifying CFLAGS and PROFTPD_LIBS.
--- Makefile.orig Thu Oct 23 09:26:45 2003
+++ Makefile Thu Oct 23 09:18:28 2003
@@ -53,13 +53,24 @@
LIBDIRS:=${LIBDIRS}:${PREFIX}/lib
.endif
-.if defined(WITH_MYSQL)
+.if defined(WITH_MYSQL) && !defined(WITH_MYSQL4)
MODULES:=${MODULES}:mod_sql:mod_sql_mysql
LIB_DEPENDS+= mysqlclient.10:${PORTSDIR}/databases/mysql323-client
INCLUDEDIRS:=${INCLUDEDIRS}:${PREFIX}/include
LIBDIRS:=${LIBDIRS}:${PREFIX}/lib/mysql
.endif
+.if defined(WITH_MYSQL4) && !defined(WITH_MYSQL)
+MODULES:=${MODULES}:mod_sql:mod_sql_mysql
+LIB_DEPENDS+= mysqlclient.12:${PORTSDIR}/databases/mysql40-client
+INCLUDEDIRS:=${INCLUDEDIRS}:${PREFIX}/include
+LIBDIRS:=${LIBDIRS}:${PREFIX}/lib/mysql
+.endif
+
+.if defined(WITH_MYSQL4) && defined(WITH_MYSQL)
+CONFLICT+= "Cannot use 2 mysql libs"
+.endif
+
.if defined(WITH_POSTGRES)
POSTGRESQL_PORT?= databases/postgresql7
MODULES:=${MODULES}:mod_sql:mod_sql_postgres
@@ -79,6 +90,15 @@
.if !empty(LIBDIRS)
CONFIGURE_ARGS+= --with-libraries=${LIBDIRS}
.endif
+
+.if defined(WITH_OPENSSL)
+CFLAGS+= -DHAVE_OPENSSL
+USE_OPENSSL= yes
+PROFTPD_LIBS+= -lssl -lcrypto
+.endif
+
+# Keep this here below, in case similar constructs need to be made
+CONFIGURE_ENV+= "LIBS=${PROFTPD_LIBS}"
pre-configure:
@${ECHO_MSG} "==> Configuring with ${MODULES}"
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list