How to fix com.android.builder.internal.aapt.AaptException: Failed to crunch file?

后端 未结 7 1648
青春惊慌失措
青春惊慌失措 2021-02-01 16:09

I have the latest version of Android Studio (as of Sep 21, 2016). When I create a brand new project in Android Studio and try to build it, I am getting this build error:

7条回答
  •  死守一世寂寞
    2021-02-01 16:37

    There is a workaround. If you add the following to the project build.gradle file, inside the allprojects section, it will move the Build output files to this folder. Meaning the app will now build.:

    buildDir = "C:/tmp/${rootProject.name}/${project.name}"
    

    It does give you an additional app module at the root of the project but this is a much more convenient option than moving whole Project folder path.

提交回复
热议问题