我从gradle迁移,并且我在我的android项目中使用public.xml,它可以正常使用gradle,但是当我使用bazel构建它时,它失败并出现以下错误:
Error: /var/folders/th/cxy34j2x0vq9zzdh8qstx5jr0000gn/T/android_resources_tmp2185237642135735709/merged_resources/values/values.xml:6772: error: Public symbol drawable/skin_at declared here is not defined.
Error: /var/folders/th/cxy34j2x0vq9zzdh8qstx5jr0000gn/T/android_resources_tmp2185237642135735709/merged_resources/values/values.xml:6774: error: Public symbol drawable/skin_at_click declared here is not defined.
Error: /var/folders/th/cxy34j2x0vq9zzdh8qstx5jr0000gn/T/android_resources_tmp2185237642135735709/merged_resources/values/values.xml:6776: error: Public symbol drawable/skin_face declared here is not defined.
Error: /var/folders/th/cxy34j2x0vq9zzdh8qstx5jr0000gn/T/android_resources_tmp2185237642135735709/merged_resources/values/values.xml:6778: error: Public symbol drawable/skin_face_click declared here is not defined.
Error: /var/folders/th/cxy34j2x0vq9zzdh8qstx5jr0000gn/T/android_resources_tmp2185237642135735709/merged_resources/values/values.xml:6780: error: Public symbol drawable/skin_keyboard declared here is not defined.
Error: /var/folders/th/cxy34j2x0vq9zzdh8qstx5jr0000gn/T/android_resources_tmp2185237642135735709/merged_resources/values/values.xml:6782: error: Public symbol drawable/skin_keyboard_click declared here is not defined.
我该怎么做才能解决这个问题?
非常感谢您的帮助!
答案 0 :(得分:1)
Bazel 0.4.5(撰写本文时的当前版本)不支持私有资源和public.xml文件。这是因为这个功能是由Gradle实现的,而不是底层工具(aapt)。有一个开放功能请求让Bazel在这里重新实现Gradle的这个功能:https://github.com/bazelbuild/bazel/issues/2124。