title: Build android failed processDebugResources gradlew cdvBuildDebug
body: <p>I am using ionic framework, until now for months the command <code>ionic build android</code> worked great, and now i see this message:</p>
  
  <p><img src="https://i.stack.imgur.com/FlxRG.png" alt="Error Command Prompt"></p>
  
  <p>I really don't know what is the problem, i searched so much and tried many things.. Thank you!</p>
  
  <p>Edit: 18/05/2016</p>
  
  <p>so i updated my sdk manager and build again with stacktrace flag and thats the exception i got:</p>
  
  <pre><code>  Executing tasks: [clean, :CordovaLib:generateDebugSources, :CordovaLib:generateDebugAndroidTestSources, :CordovaLib:compileDebugSources, :CordovaLib:compileDebugAndroidTestSources, :generateDebugSources, :generateDebugAndroidTestSources, :compileDebugSources, :compileDebugAndroidTestSources]
  
  Configuration on demand is an incubating feature.
  :clean
  :CordovaLib:clean
  :CordovaLib:preBuild UP-TO-DATE
  :CordovaLib:preDebugBuild UP-TO-DATE
  :CordovaLib:checkDebugManifest
  :CordovaLib:prepareDebugDependencies
  :CordovaLib:compileDebugAidl
  :CordovaLib:compileDebugRenderscript
  :CordovaLib:generateDebugBuildConfig
  :CordovaLib:generateDebugAssets UP-TO-DATE
  :CordovaLib:mergeDebugAssets
  :CordovaLib:generateDebugResValues UP-TO-DATE
  :CordovaLib:generateDebugResources
  :CordovaLib:packageDebugResources
  :CordovaLib:processDebugManifest
  :CordovaLib:processDebugResources
  :CordovaLib:generateDebugSources
  :CordovaLib:preDebugAndroidTestBuild UP-TO-DATE
  :CordovaLib:prepareDebugAndroidTestDependencies
  :CordovaLib:compileDebugAndroidTestAidl
  :CordovaLib:compileDebugNdk UP-TO-DATE
  :CordovaLib:compileLint
  :CordovaLib:copyDebugLint UP-TO-DATE
  :CordovaLib:mergeDebugProguardFiles UP-TO-DATE
  :CordovaLib:packageDebugRenderscript UP-TO-DATE
  :CordovaLib:compileDebugJavaWithJavac
  Note: Some input files use or override a deprecated API.
  Note: Recompile with -Xlint:deprecation for details.
  
  :CordovaLib:processDebugJavaRes UP-TO-DATE
  :CordovaLib:transformResourcesWithMergeJavaResForDebug
  :CordovaLib:transformClassesAndResourcesWithSyncLibJarsForDebug
  :CordovaLib:mergeDebugJniLibFolders
  :CordovaLib:transformNative_libsWithMergeJniLibsForDebug
  :CordovaLib:transformNative_libsWithSyncJniLibsForDebug
  :CordovaLib:bundleDebug
  :CordovaLib:compileDebugSources
  :CordovaLib:assembleDebug
  :CordovaLib:processDebugAndroidTestManifest
  :CordovaLib:compileDebugAndroidTestRenderscript
  :CordovaLib:generateDebugAndroidTestBuildConfig
  :CordovaLib:generateDebugAndroidTestAssets UP-TO-DATE
  :CordovaLib:mergeDebugAndroidTestAssets
  :CordovaLib:generateDebugAndroidTestResValues UP-TO-DATE
  :CordovaLib:generateDebugAndroidTestResources
  :CordovaLib:mergeDebugAndroidTestResources
  :CordovaLib:processDebugAndroidTestResources
  :CordovaLib:generateDebugAndroidTestSources
  :CordovaLib:compileDebugAndroidTestJavaWithJavac
  :CordovaLib:compileDebugAndroidTestNdk UP-TO-DATE
  :CordovaLib:compileDebugAndroidTestSources
  :preBuild UP-TO-DATE
  :preDebugBuild UP-TO-DATE
  :checkDebugManifest
  :prepareAndroidCordovaLibUnspecifiedDebugLibrary
  :prepareDebugDependencies
  :compileDebugAidl
  :compileDebugRenderscript
  :generateDebugBuildConfig
  :generateDebugAssets UP-TO-DATE
  :mergeDebugAssets
  :generateDebugResValues UP-TO-DATE
  :generateDebugResources
  :mergeDebugResources
  :processDebugManifest
  :processDebugResources FAILED
  
  FAILURE: Build failed with an exception.
  
  * What went wrong:
  Execution failed for task ':processDebugResources'.
  &gt; com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Users\shay\AppData\Local\Android\sdk\build-tools\23.0.3\aapt.exe'' finished with non-zero exit value 1
  
  * Try:
  Run with --info or --debug option to get more log output.
  
  * Exception is:
  org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':processDebugResources'.
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:69)
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:46)
      at org.gradle.api.internal.tasks.execution.PostExecutionAnalysisTaskExecuter.execute(PostExecutionAnalysisTaskExecuter.java:35)
      at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:64)
      at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:58)
      at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:42)
      at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:52)
      at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:53)
      at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43)
      at org.gradle.api.internal.AbstractTask.executeWithoutThrowingTaskFailure(AbstractTask.java:305)
      at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.executeTask(AbstractTaskPlanExecutor.java:79)
      at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.processTask(AbstractTaskPlanExecutor.java:63)
      at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.run(AbstractTaskPlanExecutor.java:51)
      at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.process(DefaultTaskPlanExecutor.java:23)
      at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter.execute(DefaultTaskGraphExecuter.java:88)
      at org.gradle.execution.SelectedTaskExecutionAction.execute(SelectedTaskExecutionAction.java:29)
      at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:62)
      at org.gradle.execution.DefaultBuildExecuter.access$200(DefaultBuildExecuter.java:23)
      at org.gradle.execution.DefaultBuildExecuter$2.proceed(DefaultBuildExecuter.java:68)
      at org.gradle.execution.DryRunBuildExecutionAction.execute(DryRunBuildExecutionAction.java:32)
      at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:62)
      at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:55)
      at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:149)
      at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:106)
      at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:86)
      at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.run(InProcessBuildActionExecuter.java:80)
      at org.gradle.tooling.internal.provider.BuildModelAction.run(BuildModelAction.java:43)
      at org.gradle.tooling.internal.provider.BuildModelAction.run(BuildModelAction.java:30)
      at org.gradle.tooling.internal.provider.ConfiguringBuildAction.run(ConfiguringBuildAction.java:119)
      at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:36)
      at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:26)
      at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:47)
      at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:34)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:35)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:24)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.StartStopIfBuildAndStop.execute(StartStopIfBuildAndStop.java:33)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:71)
      at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:69)
      at org.gradle.util.Swapper.swap(Swapper.java:38)
      at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:69)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:60)
      at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:34)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:70)
      at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:34)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.DaemonHygieneAction.execute(DaemonHygieneAction.java:39)
      at org.gradle.launcher.daemon.server.exec.DaemonCommandExecution.proceed(DaemonCommandExecution.java:119)
      at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:46)
      at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:246)
      at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.java:64)
  Caused by: java.lang.RuntimeException: com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Users\shay\AppData\Local\Android\sdk\build-tools\23.0.3\aapt.exe'' finished with non-zero exit value 1
      at com.android.build.gradle.tasks.ProcessAndroidResources.doFullTaskAction(ProcessAndroidResources.java:147)
      at com.android.build.gradle.internal.tasks.IncrementalTask.taskAction(IncrementalTask.java:98)
      at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:63)
      at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$IncrementalTaskAction.doExecute(AnnotationProcessingTaskFactory.java:235)
      at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:211)
      at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$IncrementalTaskAction.execute(AnnotationProcessingTaskFactory.java:222)
      at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:200)
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:80)
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:61)
      ... 55 more
  Caused by: com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Users\shay\AppData\Local\Android\sdk\build-tools\23.0.3\aapt.exe'' finished with non-zero exit value 1
      at com.android.build.gradle.internal.process.GradleProcessResult.assertNormalExitValue(GradleProcessResult.java:42)
      at com.android.builder.core.AndroidBuilder.processResources(AndroidBuilder.java:919)
      at com.android.build.gradle.tasks.ProcessAndroidResources.doFullTaskAction(ProcessAndroidResources.java:138)
      ... 63 more
  Caused by: org.gradle.process.internal.ExecException: Process 'command 'C:\Users\shay\AppData\Local\Android\sdk\build-tools\23.0.3\aapt.exe'' finished with non-zero exit value 1
      at org.gradle.process.internal.DefaultExecHandle$ExecResultImpl.assertNormalExitValue(DefaultExecHandle.java:365)
      at com.android.build.gradle.internal.process.GradleProcessResult.assertNormalExitValue(GradleProcessResult.java:40)
      ... 65 more
  
  
  BUILD FAILED
  
  Total time: 16.588 secs
  </code></pre>
  
  <p>Problem solved!! :)
  went to project directory with cmd and wrote the command  <code>gradlew.bat assembleDebug -info</code> under the line:</p>
  
  <pre><code>Successfully started process 'command '/usr/local/opt/android-sdk/build-tools/21.1.2/aapt''
  </code></pre>
  
  <p>i found there was a pdf file in one of the resources directories. android gradle didn't recognize this file and threw exception.. probably i downloaded to this directory some pdf file.. thank you anyway:)</p>