The project 'BaiduMapsApiASDemo' may be using a version of Gradle that does not contain the method.
解决方法:
http://stackoverflow.com/questions/23359572/android-studio-execution-failed-for-task-appmergedebugresources-if-project
I experienced this problem recently, and it is caused by the path length restriction I think it´s 256 characters maximun.
Relocate your Project and the build will succeed.
项目路径太长了,导致编译报错。所以只需要把存储路径改短一点就OK了