大家好,我的android studio有问题 错误是:
`Android资源链接失败 输出:
/Users/omar_sameh/Desktop/CarzyOS/app/src/main/res/layout/activity_main.xml:9: error: 'RecyclerView' is incompatible with attribute id (attr) reference.
error: failed linking file resources.
Command: /Users/omar_sameh/.gradle/caches/transforms-1/files-1.1/aapt2-3.2.0-4818971-osx.jar/7761ac785c77afbee7829c87129e0c02/aapt2-3.2.0-4818971-osx/aapt2 link -I\
/Users/omar_sameh/Library/Android/sdk/platforms/android-27/android.jar\
--manifest\
/Users/omar_sameh/Desktop/CarzyOS/app/build/intermediates/merged_manifests/debug/processDebugManifest/merged/AndroidManifest.xml\
-o\
/Users/omar_sameh/Desktop/CarzyOS/app/build/intermediates/processed_res/debug/processDebugResources/out/resources-debug.ap_\
-R\
@/Users/omar_sameh/Desktop/CarzyOS/app/build/intermediates/incremental/processDebugResources/resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
/Users/omar_sameh/Desktop/CarzyOS/app/build/generated/not_namespaced_r_class_sources/debug/processDebugResources/r\
--custom-package\
com.example.omar_sameh.carzyos\
-0\
apk\
--output-text-symbols\
/Users/omar_sameh/Desktop/CarzyOS/app/build/intermediates/symbols/debug/R.txt\
--no-version-vectors
Daemon: AAPT2 aapt2-3.2.0-4818971-osx Daemon #0
`
有什么建议吗?
答案 0 :(得分:0)
根据您的xml文件,attr元素无效
activity_main.xml:9: error: 'RecyclerView' is incompatible with attribute id (attr) reference. error: failed linking file resources.