File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- # Copyright (c) 2006, 2014 , Oracle and/or its affiliates. All rights reserved.
1+ # Copyright (c) 2006, 2016 , Oracle and/or its affiliates. All rights reserved.
22#
33# This program is free software; you can redistribute it and/or modify
44# it under the terms of the GNU General Public License as published by
@@ -235,11 +235,17 @@ IF(NOT DISABLE_SHARED)
235235 VERSION "${OS_SHARED_LIB_VERSION} "
236236 SOVERSION "${SHARED_LIB_MAJOR_VERSION} " )
237237 CONFIGURE_FILE (libmysql.ver.in ${CMAKE_CURRENT_BINARY_DIR} /libmysql.ver )
238+
239+ GET_TARGET_PROPERTY (libmysql_link_flags libmysql LINK_FLAGS )
240+ IF (NOT libmysql_link_flag)
241+ SET (libmysql_link_flags)
242+ ENDIF ()
243+ SET (libmysql_link_flags
244+ "${CMAKE_SHARED_LIBRARY_C_FLAGS} ${libmysql_link_flags} " )
245+ SET_TARGET_PROPERTIES (libmysql
246+ PROPERTIES LINK_FLAGS "${libmysql_link_flags} " )
247+
238248 IF (LINK_FLAG_NO_UNDEFINED)
239- GET_TARGET_PROPERTY (libmysql_link_flags libmysql LINK_FLAGS )
240- IF (NOT libmysql_link_flag)
241- SET (libmysql_link_flags)
242- ENDIF ()
243249 SET (libmysql_link_flags
244250 "${libmysql_link_flags} ${LINK_FLAG_NO_UNDEFINED} " )
245251 SET (libmysql_link_flags
Original file line number Diff line number Diff line change 11#! /bin/sh
2- # Copyright (c) 2000, 2014 , Oracle and/or its affiliates. All rights reserved.
2+ # Copyright (c) 2000, 2016 , Oracle and/or its affiliates. All rights reserved.
33#
44# This program is free software; you can redistribute it and/or modify
55# it under the terms of the GNU General Public License as published by
113113# We intentionally add a space to the beginning and end of lib strings, simplifies replace later
114114libs=" $ldflags -L$pkglibdir @RPATH_OPTION@ -lmysqlclient @ZLIB_DEPS@ @NON_THREADED_LIBS@"
115115libs=" $libs @openssl_libs@ @STATIC_NSS_FLAGS@ "
116+ libs=" $libs @QUOTED_CMAKE_C_LINK_FLAGS@"
116117libs_r=" $ldflags -L$pkglibdir @RPATH_OPTION@ -lmysqlclient @ZLIB_DEPS@ @CLIENT_LIBS@ @openssl_libs@ "
118+ libs_r=" $libs_r @QUOTED_CMAKE_C_LINK_FLAGS@"
117119embedded_libs=" $ldflags -L$pkglibdir @RPATH_OPTION@ -lmysqld @LIBDL@ @ZLIB_DEPS@ @LIBS@ @WRAPLIBS@ @openssl_libs@ "
118120embedded_libs=" $embedded_libs @QUOTED_CMAKE_CXX_LINK_FLAGS@"
119121
Original file line number Diff line number Diff line change 1- # Copyright (c) 2006, 2015 , Oracle and/or its affiliates. All rights reserved.
1+ # Copyright (c) 2006, 2016 , Oracle and/or its affiliates. All rights reserved.
22#
33# This program is free software; you can redistribute it and/or modify
44# it under the terms of the GNU General Public License as published by
@@ -419,6 +419,8 @@ IF(WIN32 OR HAVE_DLOPEN AND NOT DISABLE_SHARED)
419419 ELSE ()
420420 # udf_example is using safemutex exported by mysqld
421421 TARGET_LINK_LIBRARIES (udf_example mysqld )
422+ SET_TARGET_PROPERTIES (udf_example
423+ PROPERTIES LINK_FLAGS "${CMAKE_SHARED_LIBRARY_C_FLAGS} " )
422424 ENDIF ()
423425ENDIF ()
424426
You can’t perform that action at this time.
0 commit comments