我加入谷歌播放服务,在我的当前项目的依赖。
如果我救了C上的项目:盘我获得以下错误,同时同步建立项目
错误:未能执行任务:应用程序:mergeDebugResources。
错误:无法运行命令: C:\ Program Files文件(x86)的\机器人\机器人工作室\ SDK \集结TOOLS \的Android 4.4.2 \ aapt.exe小号-i C:\ Users \用户ashokp \桌面\工作室\ AndroidV2SDK_AndroidStudioFormat \谷歌播放Services\SampleApplication\AndroidV2SDKSampleApp_GooglePlayServices\app\build\exploded-aar\com.google.android.gms\play-services\4.3.23\res\drawable-hdpi\common_signin_btn_text_focus_light.9.png -o C:\ Users \用户ashokp \桌面\工作室\ AndroidV2SDK_AndroidStudioFormat \谷歌播放Services\SampleApplication\AndroidV2SDKSampleApp_GooglePlayServices\app\build\res\all\debug\drawable-hdpi\common_signin_btn_text_focus_light.9.png 错误code: 42
此问题只发生如果项目被保存在C:?drive.If我将它保存到它的工作原理perfectly.Can别人一些其他驱动器,请让我知道如果他们也面临着同样的问题。
感谢:)
解决方案
最近,我遇到过这个问题,它是由路径长度的限制造成的,我认为it's 256个字符最高可。
重新定位你的项目和建设将取得成功。
I am adding Google Play services as a dependency in my current project.
If I saved the project on C: drive I get following errors while syncing up the project.
Error:Execution failed for task ':app:mergeDebugResources'.
Error: Failed to run command: C:\Program Files (x86)\Android\android-studio\sdk\build-tools\android-4.4.2\aapt.exe s -i C:\Users\ashokp\Desktop\Studio\AndroidV2SDK_AndroidStudioFormat\Google Play Services\SampleApplication\AndroidV2SDKSampleApp_GooglePlayServices\app\build\exploded-aar\com.google.android.gms\play-services\4.3.23\res\drawable-hdpi\common_signin_btn_text_focus_light.9.png -o C:\Users\ashokp\Desktop\Studio\AndroidV2SDK_AndroidStudioFormat\Google Play Services\SampleApplication\AndroidV2SDKSampleApp_GooglePlayServices\app\build\res\all\debug\drawable-hdpi\common_signin_btn_text_focus_light.9.png Error Code: 42
This issue only happens If project is saved on c: drive.If I save it to some other drive it works perfectly.Can somebody please let me know If they are also facing the same issue?
Thanks :)
解决方案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.