ports/138469: [ PATCH ] databases/mysql51-{server|client} bad dependency
Dan Lukes
dan at obluda.cz
Wed Sep 2 03:00:18 UTC 2009
>Number: 138469
>Category: ports
>Synopsis: [ PATCH ] databases/mysql51-{server|client} bad dependency
>Confidential: no
>Severity: serious
>Priority: high
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Wed Sep 02 03:00:17 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator: Dan Lukes
>Release: FreeBSD 7.2-STABLE i386
>Organization:
Obludarium
>Environment:
System: FreeBSD 7.2-STABLE
but exact OS version is not relevant
databases/mysql51-server/Makefile,v 1.252 2009/08/28 08:23:35
>Description:
Please note - althougth such PR is dedicated to databases/mysql51-{server|client}
the MySQL 5.4 and MySQL 6.0 may be affected as well
--------- A -------------
The configure script try to detect ncurses/termcap libraries
On the virgin installation of FreeBSD the system's libncurses is used.
Unfortunatelly, when devel/ncurses present then it's
autodetected by configure. The mysql is linked against port's libncursesw
and libtinfow
Such dependency is not recorded. It cause problem when devel/ncurses
removed later or when installed elsewhere from package.
--------- B -------------
The port doesn't honor global option NOPORTDOCS
--------- C -------------
Starting from v5.1 when WITH_OPENSSL used, the port is compiled and
linked with YASSL instead of OpenSSL.
MySQL 5.9 and older is linked against OpenSSL when WITH_OPENSSL used
OpenSSL based client can't connect to YASSL based server and vice-versa
Changed behavior make problem in mixed 5.0/5.1 environment
(especially MASTER v5.0 with one or more SLAVE v5.1)
>How-To-Repeat:
--------- A -------------
Install devel/ncurses
Compile & install databases/mysql51-client
Uninstall devel/ncurses
Try to run 'mysql' (missing libncursesw.so.5.7)
--------- B -------------
Compile & install with -DNOPORTDOCS
Documentation still compilled & installed
--------- C -------------
Compile databases/mysql50-server and databases/mysql51-server
Both compilation -DWITH_OPENSSL
Install MySQL 5.0 on two machines, configure MASTER-SLAVE replication
using SSL. When you have working environment upgrade the MASTER to 5.1
SLAVE can no longer connect to MASTER because YASSL/ssl and OPENSSL/ssl
are not fully interoperable
>Fix:
--------- A -------------
As the system libraries are sufficient, we can skip the
auto-configure logic and force use of base-system libraries:
--with-named-curses-libs=-ltermcap
--------- B -------------
Use --without-doc when necesarry
--------- C -------------
Restore the pre-5.1 behavior, please: WITH_OPENSSL compile against
OpenSSL. Use WITH_YASSL when YASSL requested.
--- patch-MYSQL begins here ---
--- databases/mysql51-server/Makefile.orig 2009-08-28 10:23:35.000000000 +0200
+++ databases/mysql51-server/Makefile 2009-09-02 04:08:56.000000000 +0200
@@ -30,6 +30,7 @@
--with-libwrap \
--with-low-memory \
--with-comment='FreeBSD port: ${PKGNAME}' \
+ --with-named-curses-libs=-ltermcap \
--enable-thread-safe-client
.ifdef USE_MYSQL
@@ -42,7 +43,13 @@
.if defined(WITH_XCHARSET) && ${WITH_XCHARSET} != ""
CONFIGURE_ARGS+=--with-extra-charsets=${WITH_XCHARSET}
.endif
+.if defined(NOPORTDOCS)
+CONFIGURE_ARGS+=--without-doc
+.endif
.if defined(WITH_OPENSSL)
+USE_OPENSSL= yes
+CONFIGURE_ARGS+=--with-ssl=${OPENSSLBASE}
+.elif defined(WITH_YASSL)
CONFIGURE_ARGS+=--with-ssl=bundled
.endif
.if defined(WITH_FAST_MUTEXES)
--- patch-MYSQL ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list