File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -265,8 +265,11 @@ if(BUILD_SHARED_LIBS)
265
265
set (CMAKE_REQUIRED_LINK_OPTIONS "-Wl,--version-script=${CMAKE_CURRENT_BINARY_DIR} /libcurl.vers" )
266
266
check_c_source_compiles ("int main(void) { return 0; }" HAVE_VERSIONED_SYMBOLS )
267
267
if (HAVE_VERSIONED_SYMBOLS )
268
- # Superseded by LINK_OPTIONS in CMake 3.13 and later.
269
- set_target_properties (${LIB_SHARED} PROPERTIES LINK_FLAGS "${CMAKE_REQUIRED_LINK_OPTIONS} " )
268
+ if (CMAKE_VERSION VERSION_GREATER_EQUAL 3.13 )
269
+ set_target_properties (${LIB_SHARED} PROPERTIES LINK_OPTIONS "${CMAKE_REQUIRED_LINK_OPTIONS} " )
270
+ else ()
271
+ set_target_properties (${LIB_SHARED} PROPERTIES LINK_FLAGS "${CMAKE_REQUIRED_LINK_OPTIONS} " )
272
+ endif ()
270
273
else ()
271
274
message (WARNING "Versioned symbols requested, but not supported by the toolchain." )
272
275
endif ()
You can’t perform that action at this time.
0 commit comments