在真机上调试时,无法正常启动程序,出现问题launching remote program: failed to get the task for process XXX
(1)在Xcode的File菜单上,New File -> iOS -> Resource -> Property List -> Entitlements,新建了一个“Entitlements.plist”点Finish,然后打开此文件,设置一个“Can be debugged”属性为YES,保存。
(2)切换到项目的“Tagets”,在"Build Settings"设置:CODE SIGN ENTITLEMENTS = Entitlements.plist。