Skip to content

Commit

Permalink
Added armeabi-v7a-hard-softfp with NEON for jni
Browse files Browse the repository at this point in the history
  • Loading branch information
sh1r0 committed Jan 1, 2016
1 parent 41a08f0 commit 20adf29
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions android.toolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ if( NOT DEFINED ANDROID_STANDALONE_TOOLCHAIN_SEARCH_PATH )
endif()

# known ABIs
set( ANDROID_SUPPORTED_ABIS_arm "armeabi-v7a;armeabi;armeabi-v7a with NEON;armeabi-v7a-hard with NEON;armeabi-v7a with VFPV3;armeabi-v6 with VFP" )
set( ANDROID_SUPPORTED_ABIS_arm "armeabi-v7a;armeabi;armeabi-v7a with NEON;armeabi-v7a-hard-softfp with NEON;armeabi-v7a-hard with NEON;aarmeabi-v7a with VFPV3;armeabi-v6 with VFP" )
set( ANDROID_SUPPORTED_ABIS_arm64 "arm64-v8a" )
set( ANDROID_SUPPORTED_ABIS_x86 "x86" )
set( ANDROID_SUPPORTED_ABIS_x86_64 "x86_64" )
Expand Down Expand Up @@ -712,6 +712,15 @@ elseif( ANDROID_ABI STREQUAL "armeabi-v7a with NEON" )
set( CMAKE_SYSTEM_PROCESSOR "armv7-a" )
set( VFPV3 true )
set( NEON true )
elseif( ANDROID_ABI STREQUAL "armeabi-v7a-hard-softfp with NEON" )
set( ARMEABI_V7A_HARD_SOFTFP true )
set( ARMEABI_V7A_HARD true )
set( ANDROID_NDK_ABI_NAME "armeabi-v7a-hard" )
set( ANDROID_ARCH_NAME "arm" )
set( ANDROID_LLVM_TRIPLE "armv7-none-linux-androideabi" )
set( CMAKE_SYSTEM_PROCESSOR "armv7-a" )
set( VFPV3 true )
set( NEON true )
elseif( ANDROID_ABI STREQUAL "armeabi-v7a-hard with NEON" )
set( ARMEABI_V7A_HARD true )
set( ANDROID_NDK_ABI_NAME "armeabi-v7a-hard" )
Expand Down Expand Up @@ -1255,7 +1264,10 @@ endif()

# ABI-specific flags
if( ARMEABI_V7A_HARD )
set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -march=armv7-a -mfloat-abi=hard -mhard-float -D_NDK_MATH_NO_SOFTFP=1" )
set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -march=armv7-a -mfloat-abi=hard -mhard-float" )
if (NOT ARMEABI_V7A_HARD_SOFTFP)
set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -D_NDK_MATH_NO_SOFTFP=1" )
endif()
if( NEON )
set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -mfpu=neon" )
elseif( VFPV3 )
Expand Down

0 comments on commit 20adf29

Please sign in to comment.