添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

I’m trying to build my android game and the build crashes:

Resource ‘style/Theme.AppCompat.NoActionBar’ not found in AndroidManifest.xml:21

Configure project :launcher
WARNING: The option setting ‘android.enableR8=false’ is deprecated.
It will be removed in version 5.0 of the Android Gradle plugin.
You will no longer be able to disable R8

Task :launcher:preBuild UP-TO-DATE
Task :unityLibrary:preBuild UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:preBuild UP-TO-DATE
Task :launcher:preReleaseBuild UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:preReleaseBuild UP-TO-DATE
Task :unityLibrary:preReleaseBuild UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:compileReleaseAidl NO-SOURCE
Task :unityLibrary:packageReleaseRenderscript NO-SOURCE
Task :unityLibrary:compileReleaseAidl NO-SOURCE
Task :launcher:generateReleaseBuildConfig UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:packageReleaseRenderscript NO-SOURCE
Task :launcher:compileReleaseAidl NO-SOURCE
Task :unityLibrary:generateReleaseResValues UP-TO-DATE
Task :launcher:compileReleaseRenderscript NO-SOURCE
Task :unityLibrary:compileReleaseRenderscript NO-SOURCE
Task :unityLibrary:xrmanifest.androidlib:compileReleaseRenderscript NO-SOURCE
Task :unityLibrary:generateReleaseResources UP-TO-DATE
Task :launcher:javaPreCompileRelease UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:generateReleaseResValues UP-TO-DATE
Task :launcher:generateReleaseResValues UP-TO-DATE
Task :launcher:generateReleaseResources UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:generateReleaseResources UP-TO-DATE
Task :launcher:createReleaseCompatibleScreenManifests UP-TO-DATE
Task :unityLibrary:packageReleaseResources UP-TO-DATE
Task :launcher:extractDeepLinksRelease UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:packageReleaseResources UP-TO-DATE
Task :unityLibrary:extractDeepLinksRelease UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:extractDeepLinksRelease UP-TO-DATE
Task :unityLibrary:processReleaseManifest UP-TO-DATE
Task :unityLibrary:compileReleaseLibraryResources UP-TO-DATE
Task :launcher:mergeReleaseResources UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:processReleaseManifest UP-TO-DATE
Task :unityLibrary:parseReleaseLocalResources UP-TO-DATE
Task :launcher:processReleaseManifest UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:parseReleaseLocalResources UP-TO-DATE
Task :unityLibrary:generateReleaseBuildConfig UP-TO-DATE
Task :unityLibrary:javaPreCompileRelease UP-TO-DATE
Task :launcher:prepareLintJar UP-TO-DATE
Task :unityLibrary:prepareLintJarForPublish UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:generateReleaseRFile UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:compileReleaseLibraryResources UP-TO-DATE
Task :launcher:checkReleaseDuplicateClasses UP-TO-DATE
Task :launcher:desugarReleaseFileDependencies UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:generateReleaseBuildConfig UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:javaPreCompileRelease UP-TO-DATE
Task :launcher:mergeExtDexRelease UP-TO-DATE
Task :unityLibrary:generateReleaseRFile UP-TO-DATE
Task :launcher:mergeReleaseShaders UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:compileReleaseJavaWithJavac UP-TO-DATE
Task :unityLibrary:mergeReleaseShaders UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:bundleLibCompileToJarRelease UP-TO-DATE
Task :unityLibrary:compileReleaseShaders NO-SOURCE
Task :unityLibrary:xrmanifest.androidlib:prepareLintJarForPublish UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:bundleLibRuntimeToJarRelease UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:mergeReleaseShaders UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:compileReleaseShaders NO-SOURCE
Task :unityLibrary:xrmanifest.androidlib:generateReleaseAssets UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:packageReleaseAssets UP-TO-DATE
Task :unityLibrary:compileReleaseJavaWithJavac UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:processReleaseJavaRes NO-SOURCE
Task :unityLibrary:xrmanifest.androidlib:bundleLibResRelease NO-SOURCE
Task :unityLibrary:bundleLibCompileToJarRelease UP-TO-DATE
Task :unityLibrary:bundleLibRuntimeToJarRelease UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:mergeReleaseJniLibFolders UP-TO-DATE
Task :unityLibrary:generateReleaseAssets UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:mergeReleaseNativeLibs UP-TO-DATE
Task :unityLibrary:xrmanifest.androidlib:stripReleaseDebugSymbols NO-SOURCE
Task :unityLibrary:xrmanifest.androidlib:copyReleaseJniLibsProjectOnly UP-TO-DATE
Task :unityLibrary:packageReleaseAssets
Task :unityLibrary:processReleaseJavaRes UP-TO-DATE
Task :unityLibrary:bundleLibResRelease UP-TO-DATE
Task :unityLibrary:mergeReleaseJniLibFolders UP-TO-DATE
Task :unityLibrary:mergeReleaseNativeLibs UP-TO-DATE
Task :unityLibrary:stripReleaseDebugSymbols UP-TO-DATE
Task :unityLibrary:copyReleaseJniLibsProjectOnly UP-TO-DATE
Task :launcher:processReleaseResources FAILED
52 actionable tasks: 2 executed, 50 up-to-date

UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

Warning: Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
Warning: Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/03 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/02 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/03 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/03 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/02 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ‘:launcher:processReleaseResources’.
  • A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
    Android resource linking failed
    C:\Users\Administrator.gradle\caches\transforms-2\files-2.1\59a3791746385651986bccd6ead1dc67\GfxPluginCardboard\AndroidManifest.xml:21:9-25:66: AAPT: error: resource style/Theme.AppCompat.NoActionBar (aka com.DefaultCompany.gvrtest:style/Theme.AppCompat.NoActionBar) not found.

    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

    Get more help at https://help.gradle.org

    BUILD FAILED in 1s
    Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8

    UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

    I tried manually chaning the theme in AndroidManifest.xml but it didn’t work.
    Reinstalled the SDK but it didn’t work either.

    I’m making a game using the Cardbord SDK.

    elenafloreo:

    I had this issue as well, and the fix ended up being following the instructions in the Google Cardboard quickstart : upgrading the Android SDK to 33 and following the instructions to create custom gradle manifests in the publishing settings.

    Thanks i will try it now. I forgot what was i even working on since i have opened this thread a month ago and ditched the project because of this error. :wink:

    elenafloreo:

    I had this issue as well, and the fix ended up being following the instructions in the Google Cardboard quickstart : upgrading the Android SDK to 33 and following the instructions to create custom gradle manifests in the publishing settings.

    Thanks it actually worked. Thank The Lord. Amen.