CMake: #根据编译的位选择库目录 if("${CMAKE_SIZEOF_VOID_P}" STREQUAL "4") set (EXTRA_LIBS_DIR ${EXTRA_LIBS_DIR} ${lib}/Curl/armeabi-v7a) else() set (EXTRA_LIBS_DIR ${EXTRA_LIBS_DIR} ${lib}/Curl/arm64-v8a) endif()
link_directories(${EXTRA_LIBS_DIR}) ##包含库目录
build.gradie:
defaultConfig { ...... ...... ndk { abiFilters 'arm64-v8a', 'armeabi-v7a' } }