Android-build
[Android12][android-s-preview-1] build error libartservice/Android.bp:36:1[]
问题描述:
同步完android代码后编译出现下面错误
android_trunk$ make -j32
build/make/core/soong_config.mk:193: warning: BOARD_PLAT_PUBLIC_SEPOLICY_DIR has been deprecated. Use SYSTEM_EXT_PUBLIC_SEPOLICY_DIRS instead..
build/make/core/soong_config.mk:194: warning: BOARD_PLAT_PRIVATE_SEPOLICY_DIR has been deprecated. Use SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS instead..
============================================
PLATFORM_VERSION_CODENAME=S
PLATFORM_VERSION=S
TARGET_PRODUCT=aosp_arm64
TARGET_BUILD_VARIANT=eng
TARGET_BUILD_TYPE=release
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-a
TARGET_CPU_VARIANT=generic
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv8-a
TARGET_2ND_CPU_VARIANT=generic
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=linux
HOST_OS_EXTRA=Linux-4.4.0-101-generic-x86_64-Ubuntu-14.04.3-LTS
HOST_CROSS_OS=windows
HOST_CROSS_ARCH=x86
HOST_CROSS_2ND_ARCH=x86_64
HOST_BUILD_TYPE=release
BUILD_ID=AOSP.MASTER
OUT_DIR=out
PRODUCT_SOONG_NAMESPACES=device/generic/goldfish device/generic/goldfish-opengl hardware/google/camera hardware/google/camera/devices/EmulatedCamera
============================================
[ 98% 222/225] out/soong/.bootstrap/bin/soong_build out/soong/build.ninja
FAILED: out/soong/build.ninja
out/soong/.bootstrap/bin/soong_build -t -l out/.module_paths/Android.bp.list -b out/soong -n out -d out/soong/build.ninja.d -globFile out/soong/.bootstrap/build-globs.ninja -o out/soong/build.ninja Android.bp
error: art/libartservice/Android.bp:36:1: module "artservice" variant "android_common": depends on //libcore:art.module.api.annotations.for.system.modules which is not visible to this module
You may need to add "//art/libartservice" to its visibility
17:07:59 soong bootstrap failed with: exit status 1#### failed to build some targets (03:50 (mm:ss)) ####
解决方法
合入google下笔patch
https://android-review.googlesource.com/c/platform/libcore/+/1596234
libcore/JavaLibrary.bp
// A library that contains annotations that define API surfaces (core
// platform, intra core and the hidden API) along with some supporting
// constants. The annotations are source only and do not introduce any runtime
// dependencies. Specially built for use in system modules definitions to
// avoid introducing compile time cycles.
java_library {name: "art.module.api.annotations.for.system.modules",visibility: ["//art/libartservice",],srcs: [":api_surface_annotation_files",],installable: false,sdk_version: "none",system_modules: "api-annotations-system-modules",patch_module: "java.base",
}
Android-build相关推荐
- 理解 Android Build 系统
Android Build 系统是用来编译 Android 系统,Android SDK 以及相关文档的一套框架.众所周知,Android 是一个开源的操作系统.Android 的源码中包含了许许多多 ...
- android build获取ext,android – 如何在Gradle中获取当前构建类型
我的问题非常直接且易于理解. 题 在Gradle中,有什么办法可以在运行时获取当前的构建类型.例如,在运行assembleDebug任务时,build.gradle文件中的任务是否可以根据此任务与调试 ...
- gradle wrapper 版本与 android build tool 版本匹配要求
android build tool 指的就是gradle plugin (gradle插件)两者对用关系 如图:
- java.lang.NoClassDefFoundError: com/android/build/gradle/internal/ToolingRegistryProvider
执行 linux机器上 执行gradle 构建 [root@uranuspreapp30 app]# gradle clean build --info > /opt/test1.txtFAIL ...
- gradle-com.android.build.api.transform.TransformException:Error while generating the main dex list
问题 What went wrong: Execution failed for task >':app:transformClassesWithMultidexlistForYm1000001 ...
- Unity Hub安装Android Build Support报错:Failed to delete old Unity Android Supprtinstallation files
安装失败: 解决方法: 需要先安装 Android Build Support ,再安装 Android SDK & NDK Tools 和 OpenJDK 其他情况: 如果已经安装了Andr ...
- Android 系统(200)---Android build.prop参数详解
Android build.prop参数详解 前言 build.prop是Android系统中的一个重要的属性文件,它记录了Android系统运行的很多配置信息,当程序运行时需要某种系统状态时,会到该 ...
- Android 系统(95)---Android build.prop参数详解
Android build.prop参数详解 前言 build.prop是Android系统中的一个重要的属性文件,它记录了Android系统运行的很多配置信息,当程序运行时需要某种系统状态时,会到该 ...
- Android build.gradle文件详解(转述自《Android第一行代码》第二版)
Android build.gradle文件详解 1. 最外层目录下的build.gradle文件 1.1 repostories 1.2 dependencies 2. app目录下的build.g ...
- 深入分析Android (build/core/*.mk脚本)
深入分析Android (build/core/*.mk脚本) 文档简要整理Android的make脚本的内容.以供备忘和参考. 1. Build Layers Build Layers描述的是 ...
最新文章
- 实例规格 ECS (共享计算型)和 (通用型-原独享)性能上有什么区别?...
- 美观实用!Star 过万,用 Python 做交互式图形的这款工具火了!
- abaqus中元素过度失真是什么意思_Abaqus三维多晶体脚本建模Voronoi多面体建模
- JSP的7个动作include,forward,useBean。。。
- macOS下Apache+nginx+mysql+php多版本切换的配置
- 架构师速成4.6-软技能和硬技能
- php 自定义菜单 openid,微信公众平台开发(99) 自定义菜单获取OpenID
- 一步一步详解高斯日记
- asp.net中大文件下载
- 从程序员到项目经理(15):项目管理三大目标
- 数据库小知识点(一直更新)
- java day45【JQuery 高级:动画,遍历,事件绑定,案例,插件】
- 《演讲之禅》迷你书免费下载 每小时30000美元的秘诀
- 49 html鼠标事件(在线测试)
- 河南省第四届ACM程序设计大赛(共八道,目前只做两道。待续)
- MyEclipse豆沙绿颜色设置
- 日更第1天:Linux常用命令之dnf用法
- word文档密码破解
- Kali metasploit 更新以及问题 Unable to find a spec satisfying metasploit-framework (>= 0) in the set.
- Linux命令行与shell脚本(17)--正则表达式