Hello,
we just finished to get the MySQL/MariaDB plugin building on FreeBSD
packaging systems. Please find the cmake patch attached. In our case,
check_library_exists did not find the installed mysqlclient shared object.
Therefore check_library_exists got replaced by a different cmake
construct that goes through a list of paths to find the mysqlclient
shared object.
find_library looks for the mysqlclient shared object, then the library
gets linked by check_library_exists to see if the "mysql_init" symbol
exists. If so, the pathname from that specific shared objects gets
extracted and added to link_directories. Status is logged.
(Positive) example:
-- Looking for mysql.h
-- Looking for mysql.h - found
-- Looking for mysql_init in /usr/local/lib/mysql/libmysqlclient.so
-- Looking for mysql_init in /usr/local/lib/mysql/libmysqlclient.so - found
We would be happy to receive feedback from people building the
MySQL/MariaDB plugin for other targets with this patch applied. Most
probably the list of paths to search through needs to be extended until
we come up with a version that detects and respects installation
prefixes of shared libraries and their includes on supported platforms.
Regards
Frank
patch-Resources_CMake_MariaDBConfiguration.cmake (989 Bytes)