diff --git a/android/android.toolchain.cmake b/android/android.toolchain.cmake index ece2c9dc6f..35900b3de0 100644 --- a/android/android.toolchain.cmake +++ b/android/android.toolchain.cmake @@ -989,13 +989,23 @@ endif() if( EXISTS "${__libstl}" OR EXISTS "${__libsupcxx}" ) set( CMAKE_CXX_CREATE_SHARED_LIBRARY " -o ") set( CMAKE_CXX_CREATE_SHARED_MODULE " -o ") + set( CMAKE_CXX_LINK_EXECUTABLE " -o " ) if( EXISTS "${__libstl}" ) set( CMAKE_CXX_CREATE_SHARED_LIBRARY "${CMAKE_CXX_CREATE_SHARED_LIBRARY} \"${__libstl}\"") set( CMAKE_CXX_CREATE_SHARED_MODULE "${CMAKE_CXX_CREATE_SHARED_MODULE} \"${__libstl}\"") + set( CMAKE_CXX_LINK_EXECUTABLE "${CMAKE_CXX_LINK_EXECUTABLE} \"${__libstl}\"") endif() if( EXISTS "${__libsupcxx}" ) set( CMAKE_CXX_CREATE_SHARED_LIBRARY "${CMAKE_CXX_CREATE_SHARED_LIBRARY} \"${__libsupcxx}\"") set( CMAKE_CXX_CREATE_SHARED_MODULE "${CMAKE_CXX_CREATE_SHARED_MODULE} \"${__libsupcxx}\"") + set( CMAKE_CXX_LINK_EXECUTABLE "${CMAKE_CXX_LINK_EXECUTABLE} \"${__libsupcxx}\"") + # C objects: + set( CMAKE_C_CREATE_SHARED_LIBRARY = " -o " ) + set( CMAKE_C_CREATE_SHARED_MODULE = " -o " ) + set( CMAKE_C_LINK_EXECUTABLE = " -o " ) + set( CMAKE_C_CREATE_SHARED_LIBRARY "${CMAKE_C_CREATE_SHARED_LIBRARY} \"${__libsupcxx}\"") + set( CMAKE_C_CREATE_SHARED_MODULE "${CMAKE_C_CREATE_SHARED_MODULE} \"${__libsupcxx}\"") + set( CMAKE_C_LINK_EXECUTABLE "${CMAKE_C_LINK_EXECUTABLE} \"${__libsupcxx}\"") endif() endif()