Date: Sun, 29 Jan 2017 13:50:07 -0600 From: John Marino <freebsd.contact@marino.st> To: Bernard Spil <brnrd@FreeBSD.org>, ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: Re: svn commit: r432458 - in head/databases: mysql56-client mysql56-client/files mysql56-server mysql56-server/files Message-ID: <796ba016-0c35-f368-5115-3a8a1ec4cfec@marino.st> In-Reply-To: <201701251907.v0PJ78fZ061674@repo.freebsd.org> References: <201701251907.v0PJ78fZ061674@repo.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 1/25/2017 13:07, Bernard Spil wrote: > Author: brnrd > Date: Wed Jan 25 19:07:08 2017 > New Revision: 432458 > URL: https://svnweb.freebsd.org/changeset/ports/432458 > > Log: > databases/mysql56-server: Fix OpenSSL linking > > - Force dynamic linking with OpenSSL > > MFH: 2017Q1 > > Added: > head/databases/mysql56-client/files/patch-cmake_ssl.cmake (contents, props changed) > head/databases/mysql56-server/files/patch-cmake_ssl.cmake (contents, props changed) > Modified: > head/databases/mysql56-client/Makefile > head/databases/mysql56-server/Makefile > > Modified: head/databases/mysql56-client/Makefile > ============================================================================== > --- head/databases/mysql56-client/Makefile Wed Jan 25 18:59:23 2017 (r432457) > +++ head/databases/mysql56-client/Makefile Wed Jan 25 19:07:08 2017 (r432458) > @@ -2,7 +2,7 @@ > # $FreeBSD$ > > PORTNAME= mysql > -PORTREVISION?= 0 > +PORTREVISION?= 1 > PKGNAMESUFFIX= 56-client > > COMMENT= Multithreaded SQL database (client) > > Added: head/databases/mysql56-client/files/patch-cmake_ssl.cmake > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/databases/mysql56-client/files/patch-cmake_ssl.cmake Wed Jan 25 19:07:08 2017 (r432458) > @@ -0,0 +1,11 @@ > +--- cmake/ssl.cmake.orig 2016-11-28 13:36:22 UTC > ++++ cmake/ssl.cmake > +@@ -176,7 +176,7 @@ MACRO (MYSQL_CHECK_SSL) > + IF(OPENSSL_INCLUDE_DIR AND > + OPENSSL_LIBRARY AND > + CRYPTO_LIBRARY AND > +- OPENSSL_MAJOR_VERSION STREQUAL "1" > ++ OPENSSL_MAJOR_VERSION VERSION_GREATER_EQUAL "1" > + ) > + SET(OPENSSL_FOUND TRUE) > + ELSE() > > Modified: head/databases/mysql56-server/Makefile > ============================================================================== > --- head/databases/mysql56-server/Makefile Wed Jan 25 18:59:23 2017 (r432457) > +++ head/databases/mysql56-server/Makefile Wed Jan 25 19:07:08 2017 (r432458) > @@ -3,7 +3,7 @@ > > PORTNAME?= mysql > PORTVERSION= 5.6.35 > -PORTREVISION?= 2 > +PORTREVISION?= 3 > CATEGORIES= databases ipv6 > MASTER_SITES= MYSQL/MySQL-5.6 > PKGNAMESUFFIX?= 56-server > @@ -54,6 +54,9 @@ CMAKE_ARGS+= -DINSTALL_LAYOUT=FREEBSD \ > -DWITH_LIBEVENT=system \ > -DWITH_LZ4=system \ > -DWITH_ZLIB=system \ > + -DWITH_SSL=${OPENSSLBASE} \ > + -DCRYPTO_LIBRARY=${OPENSSLLIB}/libcrypto.so \ > + -DOPENSSL_LIBRARY=${OPENSSLLIB}/libssl.so \ > -DINSTALL_MYSQLTESTDIR=0 > > SHEBANG_FILES= scripts/*.pl* scripts/*.sh > @@ -129,12 +132,6 @@ PERFSCHM_SUB_LIST_OFF+= PERFSCHEMRC="--s > > .include <bsd.port.pre.mk> > > -.if ${SSL_DEFAULT} == base > -CMAKE_ARGS+= -DWITH_SSL=system > -.else > -CMAKE_ARGS+= -DWITH_SSL=${OPENSSLBASE} > -.endif > - > post-patch: > @${REINPLACE_CMD} 's/*.1/${MMAN1}/' ${WRKSRC}/man/CMakeLists.txt > > > Added: head/databases/mysql56-server/files/patch-cmake_ssl.cmake > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/databases/mysql56-server/files/patch-cmake_ssl.cmake Wed Jan 25 19:07:08 2017 (r432458) > @@ -0,0 +1,11 @@ > +--- cmake/ssl.cmake.orig 2016-11-28 13:36:22 UTC > ++++ cmake/ssl.cmake > +@@ -176,7 +176,7 @@ MACRO (MYSQL_CHECK_SSL) > + IF(OPENSSL_INCLUDE_DIR AND > + OPENSSL_LIBRARY AND > + CRYPTO_LIBRARY AND > +- OPENSSL_MAJOR_VERSION STREQUAL "1" > ++ OPENSSL_MAJOR_VERSION VERSION_GREATER_EQUAL "1" > + ) > + SET(OPENSSL_FOUND TRUE) > + ELSE() > Interestingly, this actually broke several ports for us: benchmarks sysbench databases apq-mysql databases mysql-connector-c++ mail qmail-mysql security pam-mysql typical message: /usr/libexec/binutils227/elf/ld.gold: error: cannot find -lssl /usr/libexec/binutils227/elf/ld.gold: error: cannot find -lcrypto I think mysql_config is to blame: checking for mysql_config... /usr/local/bin/mysql_config checking MySQL C flags... -I/usr/local/include/mysql -isystem /usr/local/include -fno-strict-aliasing -g -fno-omit-frame-pointer -fno-strict-aliasing checking MySQL linker flags... -L/usr/local/lib/mysql -lmysqlclient_r -pthread -lz -lm -lexecinfo -lssl -lcrypto It's not adding -L/usr/local/lib for ports' openssl ports. John --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?796ba016-0c35-f368-5115-3a8a1ec4cfec>