# 9 minutes timeout for the tests, Travis timeouts on 10min if there is no
# output and I do not want some tests to be skipped because of one test. Like
-# the qpainter test - it does a lot of tests and can (and sometimes it does)
-# take more then 10min.
+# the qpainter test - it does a lot of tests and can take more then 10min.
set(CTEST_TEST_TIMEOUT 540)
if(NOT CMAKE_VERSION VERSION_LESS "3.3.0")
OUTPUT_VARIABLE MYSQL_LIBRARIES
OUTPUT_STRIP_TRAILING_WHITESPACE
)
- # just in case
+ execute_process(
+ COMMAND ${MYSQL_CONFIG} --version
+ RESULT_VARIABLE proceerror3
+ OUTPUT_VARIABLE MYSQL_VERSION
+ OUTPUT_STRIP_TRAILING_WHITESPACE
+ )
+ # just in case, MYSQL_VERSION is not critical
if(NOT procerror1 STREQUAL "0" OR NOT proceerror2 STREQUAL "0")
set(MYSQL_INCLUDES)
set(MYSQL_LIBRARIES)
+ set(MYSQL_VERSION)
endif()
endif()
endif()
include(FindPackageHandleStandardArgs)
-find_package_handle_standard_args(MySQL DEFAULT_MSG MYSQL_INCLUDES MYSQL_LIBRARIES)
+find_package_handle_standard_args(MySQL
+ VERSION_VAR MYSQL_VERSION
+ REQUIRED_VARS MYSQL_INCLUDES MYSQL_LIBRARIES
+)
mark_as_advanced(MYSQL_INCLUDES MYSQL_LIBRARIES)