設置 | 登錄 | 註冊

目前共有50篇帖子。

Android Studio 3.5.3下载地址

31樓 巨大八爪鱼 2025-8-18 19:49

logcat窗格:

32樓 巨大八爪鱼 2025-8-18 19:57

Terminal窗格在XP系统下不可用,但在win7系统下可用。

33樓 巨大八爪鱼 2025-8-21 20:50
关于Native C++项目Sync时报错:

ERROR: Cause: executing external native build for cmake F:\Projects\AndroidStudioProjects\MyApplication3\app\src\main\cpp\CMakeLists.txt

解决办法:

在SDK Tools里面勾选下面的Show Package Details,然后勾选安装NDK (Side by side) 21.0.6113669版本。


装完后,点击File -> Project Structure菜单,在SDK Location里面设置安卓SDK和NDK的路径。

注意路径里面不能有空格,默认的路径C:\Documents and Settings\Administrator\AppData\Local\Android\Sdk是有空格的,要把这个文件夹手动复制到没有空格的地方(比如F:\test),然后把SDK路径改成F:\test\Sdk,NDK路径改成F:\test\Sdk\ndk\21.0.6113669。改完后工程就可以成功Sync和Make Project了。

巨大八爪鱼工程没Sync的情况下,Tools菜单下是没有SDK Manager命令的,只能从File -> Settings菜单打开。
从File -> Settings菜单打开Settings for New Projects窗口后,左边展开Apperance & Behavior -> System Settings -> Android SDK。
右边打开SDK Tools选项卡,勾选下面的Show Package Details,然后勾选安装NDK (Side by side) 21.0.6113669版本。
————————————————
版权声明:本文为CSDN博主「巨大八爪鱼」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/ZLK1214/article/details/150590936
巨大八爪鱼最新版NDK29.0.13846066与Android Studio 3.5.3版本不匹配,必须要降级到21.0.6113669才能用。
34樓 巨大八爪鱼 2025-8-21 20:50
35樓 巨大八爪鱼 2025-8-21 21:13

目前2025年最新版CMake3.10.2.4988404是可以用的。

36樓 巨大八爪鱼 2025-8-22 09:48
成功编译并在手机上运行Native C++程序。
37樓 巨大八爪鱼 2025-8-22 10:58

Android Studio 3.5.3可以成功导入oboe-1.9.0,但无法成功导入最新版的oboe-1.9.3。

https://github.com/google/oboe/archive/refs/tags/1.9.0.zip (Jun 26, 2024)

https://github.com/google/oboe/archive/refs/tags/1.9.3.zip (Dec 18, 2024)

target_link_libraries( # Specifies the target library.
native-lib

# Links the target library to the log library
# included in the NDK.
${log-lib} oboe)

# Set the path to the Oboe directory.
set (OBOE_DIR "D:\\My Documents\\Downloads\\oboe-1.9.0\\oboe-1.9.0")

# Add the Oboe library as a subdirectory in your project.
# add_subdirectory tells CMake to look in this directory to
# compile oboe source files using oboe's CMake file.
# ./oboe specifies where the compiled binaries will be stored
add_subdirectory (${OBOE_DIR} ./oboe)

# Specify the path to the Oboe header files.
# This allows targets compiled with this CMake (application code)
# to see public Oboe headers, in order to access its API.
include_directories (${OBOE_DIR}/include)

38樓 巨大八爪鱼 2025-8-22 11:15
39樓 巨大八爪鱼 2025-8-22 14:01

最好还是找一个没有空格的文件夹放oboe源码,否则代码编辑器里面会有很多红线。

set (OBOE_DIR F:/test/oboe-1.9.0)

add_subdirectory (${OBOE_DIR} ./oboe)

include_directories (${OBOE_DIR}/include)

巨大八爪鱼用双反斜杠也可以:set (OBOE_DIR F:\\test\\oboe-1.9.0)
40樓 巨大八爪鱼 2025-8-22 14:14

內容轉換:

回覆帖子
內容:
用戶名: 您目前是匿名發表。
驗證碼:
看不清?換一張
©2010-2025 Purasbar Ver3.0 [手機版] [桌面版]
除非另有聲明,本站採用知識共享署名-相同方式共享 3.0 Unported許可協議進行許可。