Details
-
Bug
-
Status: In Review (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.6, 10.11, 11.4, 11.8
-
None
-
Q3/2026 Server Maintenance, Q4/2026 Server Maintenance
Description
Apparently, it breaks when used with vcpkg.
There are more intelligent ways to handle that now: e.g create MariaDB::zlib library, which points (in sense of cmake ALIAS or INTERFACE library) either to standard ZLIB:ZLIB, or to own compiled zlib, and use it consistently instead of ${ZLIB_LIBRARIES}.
target_include_directories should be set consistently, and then it will help eliminate multiple ZLIB_INCLUDE_DIRS sprinkled around the code.
Do the same with OpenSSL , i.e create MariaDB::OpenSSL which points to either OpenSSL or WolfSSL, define it well (so that users pick up correct target_link_libraries and target_include_directories) and use it consistently in the code
Do the same with PCRE2, and other things that can be either system or bundled , where "bundled" can often mean ExternalProject_Add.
That is, for such targets use interface and alias libraries, MariaDB::lib points to correct library, and carries include directory dependency, and it is not necessary to add anything but target_link_library() to use it.
Attachments
Issue Links
- relates to
-
MDEV-36657 add ${PCRE_LIBRARY_PATH} to link directories
-
- Stalled
-