mirror of
https://github.com/nyanmisaka/mpp.git
synced 2026-01-24 04:30:40 +01:00
[android]: fix android binary runtime error due to error bionic libc linking
git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@992 6e48237b-75ef-9749-8fc9-41990f28c85a
This commit is contained in:
parent
92ba46a86b
commit
7965f5dfd9
2 changed files with 6 additions and 6 deletions
|
|
@ -1301,10 +1301,10 @@ endif()
|
|||
|
||||
# add crt object to executable link list for Android SDK build
|
||||
# ----------------------------------------------------------------------------
|
||||
#set( ANDROID_CRT_BEGIN "${ANDROID_SYSROOT}/usr/lib/crtbegin_dynamic.o")
|
||||
#set( ANDROID_CRT_END "${ANDROID_SYSROOT}/usr/lib/crtend_android.o")
|
||||
#set( CMAKE_C_LINK_EXECUTABLE "${CMAKE_C_LINK_EXECUTABLE} ${ANDROID_CRT_BEGIN} ${ANDROID_CRT_END}" )
|
||||
#set( CMAKE_CXX_LINK_EXECUTABLE "${CMAKE_CXX_LINK_EXECUTABLE} ${ANDROID_CRT_BEGIN} ${ANDROID_CRT_END}" )
|
||||
set( ANDROID_CRT_BEGIN "${ANDROID_SYSROOT}/usr/lib/crtbegin_dynamic.o")
|
||||
set( ANDROID_CRT_END "${ANDROID_SYSROOT}/usr/lib/crtend_android.o")
|
||||
set( CMAKE_C_LINK_EXECUTABLE "${CMAKE_C_LINK_EXECUTABLE} ${ANDROID_CRT_BEGIN} ${ANDROID_CRT_END}" )
|
||||
set( CMAKE_CXX_LINK_EXECUTABLE "${CMAKE_CXX_LINK_EXECUTABLE} ${ANDROID_CRT_BEGIN} ${ANDROID_CRT_END}" )
|
||||
|
||||
# ----------------------------------------------------------------------------
|
||||
# ----------------------------------------------------------------------------
|
||||
|
|
@ -1406,7 +1406,7 @@ endif()
|
|||
# ----------------------------------------------------------------------------
|
||||
# add nostdlib for Android SDK build
|
||||
# ----------------------------------------------------------------------------
|
||||
set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -nostdlib -ldl" )
|
||||
set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -nostdlib -ldl -lc" )
|
||||
|
||||
# cache flags
|
||||
set( CMAKE_CXX_FLAGS "" CACHE STRING "c++ flags" )
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ add_library(osal STATIC
|
|||
if(ANDROID)
|
||||
add_definitions(-static)
|
||||
# in Android pthread is in libc, also need liblog
|
||||
target_link_libraries(osal log stdc++ m c )
|
||||
target_link_libraries(osal log stdc++ m)
|
||||
else()
|
||||
target_link_libraries(osal pthread)
|
||||
endif()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue