Skip to content

Commit 321e772

Browse files
committed
Add C++11 requirement in cmake package configuration script.
Connector public headers require C++11 at least. For some compilers this is not enabled by default (e.g. Apple clang). This patch specifies the requirement so that cmake will add the appropriate `-std` flag if not already set.
1 parent ef96fbd commit 321e772

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

mysql-concpp-config.cmake.in

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -433,6 +433,8 @@ function(add_connector_target which tgt base_name)
433433

434434
add_library(mysql::${tgt} ${type} IMPORTED GLOBAL)
435435

436+
target_compile_features(mysql::${tgt} INTERFACE cxx_std_11)
437+
436438
set_target_properties(mysql::${tgt} PROPERTIES
437439
INTERFACE_INCLUDE_DIRECTORIES "${MYSQL_CONCPP_INCLUDE_DIR}"
438440
)

0 commit comments

Comments
 (0)