[NDK_PROJECT_PATH=null]。无法从与 PARALLEL-SPACE 相关的示例项目中解决 Android-NDK 错误
Posted
技术标签:
【中文标题】[NDK_PROJECT_PATH=null]。无法从与 PARALLEL-SPACE 相关的示例项目中解决 Android-NDK 错误【英文标题】:[NDK_PROJECT_PATH=null]. Not able to resolve Android-NDK error from a sample project related to PARALLEL-SPACE 【发布时间】:2021-07-30 22:53:16 【问题描述】:错误日志
外部原生生成 JSON 发布:执行 ndkBuild Executable : /Users/nidhinagvanshi/Library/android/sdk/ndk/20.0.5594570/ndk-build 参数:NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/nidhinagvanshi/Downloads/VirtualApp-master-2/VirtualApp/lib/src/main/jni/Android.mk NDK_APPLICATION_MK=/Users/nidhinagvanshi/Downloads/VirtualApp-master-2/VirtualApp/lib/src/main/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=0 APP_PLATFORM=android-16 NDK_OUT=/Users/nidhinagvanshi/Downloads/VirtualApp-master-2/VirtualApp/lib/build/intermediates/ndkBuild/release/obj NDK_LIBS_OUT=/Users/nidhinagvanshi/Downloads/VirtualApp-master-2/VirtualApp/lib/build/intermediates/ndkBuild/release/lib APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false
-n jvmArgs:
/Users/nidhinagvanshi/Library/Android/sdk/ndk/20.0.5594570/build/core/add-application.mk:178: *** Android NDK:不再支持 APP_STL gnustl_static。请切换到 c++_static 或 c++_shared。看 https://developer.android.com/ndk/guides/cpp-support.html 了解更多 信息。 .停止。外部原生生成 JSON 发布:使用 ABI ARMEABI_V7A 平台版本 16 和最小 SDK 版本 14 外部原生生成 JSON 发布:重建 JSON /Users/nidhinagvanshi/Downloads/VirtualApp-master-2/VirtualApp/lib/.externalNativeBuild/ndkBuild/release/armeabi-v7a/android_gradle_build.json 由于:外部原生生成 JSON 版本:- 预期的 json /Users/nidhinagvanshi/Downloads/VirtualApp-master-2/VirtualApp/lib/.externalNativeBuild/ndkBuild/release/armeabi-v7a/android_gradle_build.json 文件不存在,将删除陈旧的 json 文件夹 外部原生 生成 JSON 版本:- 缺少以前的命令文件 /Users/nidhinagvanshi/Downloads/VirtualApp-master-2/VirtualApp/lib/.externalNativeBuild/ndkBuild/release/armeabi-v7a/ndkBuild_build_command.txt, 将删除陈旧的 json 文件夹
Android.mk
LOCAL_PATH := $(call my-dir)
MAIN_LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := va++
LOCAL_CFLAGS := -Wno-error=format-security -fpermissive -DLOG_TAG=\"VA++\"
LOCAL_CFLAGS += -fno-rtti -fno-exceptions
LOCAL_C_INCLUDES += $(MAIN_LOCAL_PATH)
LOCAL_C_INCLUDES += $(MAIN_LOCAL_PATH)/Foundation
LOCAL_C_INCLUDES += $(MAIN_LOCAL_PATH)/Jni
LOCAL_SRC_FILES := Jni/VAJni.cpp \
Foundation/IOUniformer.cpp \
Foundation/VMPatch.cpp \
Foundation/SymbolFinder.cpp \
Foundation/Path.cpp \
Foundation/SandboxFs.cpp \
Substrate/hde64.c \
Substrate/SubstrateDebug.cpp \
Substrate/SubstrateHook.cpp \
Substrate/SubstratePosixMemory.cpp \
LOCAL_LDLIBS := -llog -latomic
LOCAL_STATIC_LIBRARIES := fb
include $(BUILD_SHARED_LIBRARY)
include $(MAIN_LOCAL_PATH)/fb/Android.mk
local.properties
#Sat May 08 22:01:39 IST 2021 sdk.dir=/Users/nidhinagvanshi/Library/Android/sdk ndk.dir=/Users/nidhinagvanshi/Library/Android/sdk/ndk/20.0.5594570
【问题讨论】:
那么你修复了它在这里抱怨的问题:“APP_STL gnustl_static 不再受支持。请切换到c++_static 或c++_shared”?跨度> 【参考方案1】:我通过降级 NDK 解决了这个错误。 local.properties 中更改了以下行:
ndk.dir=/Users/nidhinagvanshi/Library/Android/sdk/ndk/17.2.4988734
【讨论】:
以上是关于[NDK_PROJECT_PATH=null]。无法从与 PARALLEL-SPACE 相关的示例项目中解决 Android-NDK 错误的主要内容,如果未能解决你的问题,请参考以下文章