Skip to content

Commit

Permalink
cmake: Remove unneeded -Wl,--allow-multiple-definition since libandro…
Browse files Browse the repository at this point in the history
…id_support is no longer used

Signed-off-by: Andrew Gunnerson <[email protected]>
  • Loading branch information
chenxiaolong committed Jul 3, 2018
1 parent c2cecab commit d369387
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 22 deletions.
1 change: 0 additions & 1 deletion bootimgtool/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ foreach(variant ${variants})
)
endif()
elseif(${variant} STREQUAL static)
android_link_allow_multiple_definitions(${bin_target})
unix_link_executable_statically(${bin_target})
endif()

Expand Down
13 changes: 0 additions & 13 deletions cmake/CompilerFlags.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -199,19 +199,6 @@ if(NOT MSVC)
)
endif()

# https://github.com/android-ndk/ndk/issues/17
function(android_link_allow_multiple_definitions first_target)
if(ANDROID AND "${ANDROID_STL}" STREQUAL "c++_static")
foreach(target "${first_target}" ${ARGN})
set_property(
TARGET "${target}"
APPEND_STRING
PROPERTY LINK_FLAGS " -Wl,--allow-multiple-definition"
)
endforeach()
endif()
endfunction()

function(unix_link_executable_statically first_target)
if(UNIX)
foreach(target "${first_target}" ${ARGN})
Expand Down
1 change: 0 additions & 1 deletion libmbbootimg/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ if(variants AND MBP_ENABLE_TESTS)
)

if(ANDROID)
android_link_allow_multiple_definitions(mbbootimg_tests)
unix_link_executable_statically(mbbootimg_tests)
endif()

Expand Down
1 change: 0 additions & 1 deletion libmbcommon/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,6 @@ if(variants AND MBP_ENABLE_TESTS)
)

if(ANDROID)
android_link_allow_multiple_definitions(mbcommon_tests)
unix_link_executable_statically(mbcommon_tests)
endif()

Expand Down
1 change: 0 additions & 1 deletion libmbdevice/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@ if(variants AND MBP_ENABLE_TESTS)
)

if(ANDROID)
android_link_allow_multiple_definitions(mbdevice_tests)
unix_link_executable_statically(mbdevice_tests)
endif()

Expand Down
1 change: 0 additions & 1 deletion libmbsign/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ if(variants AND MBP_ENABLE_TESTS)
)

if(ANDROID)
android_link_allow_multiple_definitions(mbsign_tests)
unix_link_executable_statically(mbsign_tests)
endif()

Expand Down
1 change: 0 additions & 1 deletion libmbsparse/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ if(variants AND MBP_ENABLE_TESTS)
)

if(ANDROID)
android_link_allow_multiple_definitions(mbsparse_tests)
unix_link_executable_statically(mbsparse_tests)
endif()

Expand Down
1 change: 0 additions & 1 deletion mbbootui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ target_include_directories(
${CMAKE_SOURCE_DIR}/external/flatbuffers/include
)

android_link_allow_multiple_definitions(mbbootui)
unix_link_executable_statically(mbbootui)

target_link_libraries(
Expand Down
1 change: 0 additions & 1 deletion mbtool/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,6 @@ if(${MBP_BUILD_TARGET} STREQUAL android-system)
-DRECOVERY
)

android_link_allow_multiple_definitions(mbtool mbtool_recovery)
unix_link_executable_statically(mbtool mbtool_recovery)

target_link_libraries(
Expand Down
1 change: 0 additions & 1 deletion odinupdater/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ if(${MBP_BUILD_TARGET} STREQUAL android-system)
Fuse::Fuse
)

android_link_allow_multiple_definitions(odinupdater fuse-sparse)
unix_link_executable_statically(odinupdater fuse-sparse)

install(
Expand Down

0 comments on commit d369387

Please sign in to comment.