drogonframework / drogonframework/drogon
Problem with find_package(MySQL) and cmake
- Dominant language
- C++
- Stars
- 14.3k
- Forks
- 1.4k
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 14
Description
I have built Mariadb connector and then tried to build drogon from head passing -DBUILD_MYSQL=ON in cmake command line. MySQL_ROOT environment variable is pointing to Mariadb installation location and yet find_package(MySQL) fails in drogon. I can't figure out what is wrong.
Update:
I was able to set environment variables:
export CMAKE_INCLUDE_PATH=$MySQL_ROOT/include/mariadb:$CMAKE_INCLUDE_PATH
export CMAKE_LIBRARY_PATH=$MySQL_ROOT/lib/mariadb:$CMAKE_LIBRARY_PATH
to have FinMySQL.cmake work with mariadb (I guess the subdirectory mariadb under include and lib makes this a requirement), but I next encountered another error:
None of the example clients would link properly as mariadb was built with libzstd and I guess drogon doesn't link with libzstd. So the workaround was to remove libzstd from mariadb module and then use that module to build drogon examples.
Contributor guide
Assessment
This issue has not been assessed yet.