diff options
author | Tor Didriksen <tor.didriksen@oracle.com> | 2013-06-14 10:52:23 +0200 |
---|---|---|
committer | Tor Didriksen <tor.didriksen@oracle.com> | 2013-06-14 10:52:23 +0200 |
commit | a040586cceab693b5b689afff841c785afa38e53 (patch) | |
tree | 635f7a3d45ec27024d2f7e63e79da82fdeb47273 /mysys | |
parent | 9f7043ab91197decf382553e156aabc87d5f7451 (diff) | |
download | mariadb-git-a040586cceab693b5b689afff841c785afa38e53.tar.gz |
Bug#16729109: FIX COMPILATION WARNINGS WITH GCC 4.8
Backport to 5.5
(external Bug#69407 Build warnings with mysql)
Diffstat (limited to 'mysys')
-rw-r--r-- | mysys/CMakeLists.txt | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/mysys/CMakeLists.txt b/mysys/CMakeLists.txt index 814f093c2d6..95d3e568be7 100644 --- a/mysys/CMakeLists.txt +++ b/mysys/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (c) 2006, 2011, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2006, 2013, Oracle and/or its affiliates. All rights reserved. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -69,6 +69,11 @@ TARGET_LINK_LIBRARIES(mysys dbug strings ${ZLIB_LIBRARY} ${LIBNSL} ${LIBM} ${LIBRT}) DTRACE_INSTRUMENT(mysys) +# Need explicit pthread for gcc -fsanitize=address +IF(CMAKE_USE_PTHREADS_INIT AND CMAKE_C_FLAGS MATCHES "-fsanitize=") + TARGET_LINK_LIBRARIES(mysys pthread) +ENDIF() + ADD_EXECUTABLE(thr_lock thr_lock.c) TARGET_LINK_LIBRARIES(thr_lock mysys) SET_TARGET_PROPERTIES(thr_lock PROPERTIES COMPILE_FLAGS "-DMAIN") |