diff --git a/CMakeLists.txt b/CMakeLists.txt index df0eb0126f4..96d427c1817 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -59,6 +59,7 @@ find_package(PCHSupport) find_package(OpenSSL REQUIRED) find_package(Threads REQUIRED) find_package(ZMQ REQUIRED) +find_package(MySQL) include(ConfigureBoost) diff --git a/src/server/database/CMakeLists.txt b/src/server/database/CMakeLists.txt index ad1074496ce..5a53899f4cb 100644 --- a/src/server/database/CMakeLists.txt +++ b/src/server/database/CMakeLists.txt @@ -8,7 +8,9 @@ # WITHOUT ANY WARRANTY, to the extent permitted by law; without even the # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -find_package(MySQL REQUIRED) +if (NOT MYSQL_FOUND) + message(SEND_ERROR "MySQL wasn't found on your system but it's required to build the servers!") +endif() if( USE_COREPCH ) include_directories(${CMAKE_CURRENT_BINARY_DIR})