简体   繁体   English

iOS AdHoc应用程序可在模拟器中完美运行,拒绝在设备上启动

[英]iOS AdHoc app works perfectly in simulator, refuses to launch on device

The app, which is for personal use, has worked perfectly for one year on my device. 该应用程序供个人使用,已在我的设备上完美运行了一年。

Suddenly it stopped working. 突然它停止工作了。 It would show the startup image briefly, and then quit immediately. 它将短暂显示启动映像,然后立即退出。 That didn't surprise me, because the same thing happened with my other app, as my provisioning profile was expired. 这并不令我感到惊讶,因为当我的配置文件过期时,其他应用程序也发生了同样的事情。 On the other app, I fixed it by rebuilding the app in Xcode, and it worked again. 在另一个应用程序上,我通过在Xcode中重建该应用程序对其进行了修复,然后它又可以正常工作。 On the app that doesn't work, I can build it with Xcode and run in the simulator only, but if I try to run it on the device, either via Xcode or by archiving and exporting, the same thing happens: Launch image shown briefly, then it quits immediately. 在无法运行的应用程序上,我可以使用Xcode生成它并仅在模拟器中运行,但是如果我尝试通过Xcode或通过归档和导出在设备上运行它,则会发生相同的情况:启动显示的图像短暂地,然后立即退出。 Xcode gives this error message: Xcode给出此错误消息:

Unable to launch /private/var/containers/Bundle/Application/AD405D63-426C-401B-8678-726D60BCB6F8/QuickDict.app

I have not been able to find any more diagnostics information. 我还找不到更多诊断信息。 I notice that for my other app, the one that worked, Xcode uses a provisioning profile with a full app identifier, as in "com.domain.AppName", whereas for the app that doesn't work, it uses a profile with a wildcard app identifier. 我注意到,对于我的另一个应用程序(工作正常),Xcode使用带有完整应用程序标识符的配置配置文件,例如“ com.domain.AppName”,而对于不起作用的应用程序,它使用带有配置文件的配置文件。通配符应用程序标识符。 However, I need no capabilities for this one app that I know of. 但是,对于我所知道的这个应用程序,我不需要任何功能。 I let Xcode handle signing automatically. 我让Xcode自动处理签名。

On the device, the app won't run neither when launching via Xcode nor when trying to install the app via iTunes. 在设备上,通过Xcode启动或尝试通过iTunes安装应用程序时,该应用程序都不会运行。

  • Xcode version: 8.3.3 (8E3004b) Xcode版本:8.3.3(8E3004b)
  • Deployment target: iPhone iOS 9.2 部署目标:iPhone iOS 9.2
  • Device: iPhone 5s 设备:iPhone 5s

It is not guaranteed that the reason has to do with provisioning profiles, because some code has been changed after it was last deployed. 由于某些代码在上次部署后已更改,因此不能保证原因与配置文件有关。 However, it works perfectly in the simulator. 但是,它可以在模拟器中完美运行。


EDIT: I saw that my app was set up to run with release build in Xcode. 编辑:我看到我的应用程序被设置为与Xcode中的发布版本一起运行。 I tried running the debug build instead, and got a new equally "informative" error message: 我尝试运行调试版本,但收到一条同样“提示性”的新错误消息:

Could not launch "QuickDict"
process launch failed: Unspecified

EDIT2: In this case I had a different domain name available, and was able to get the app to work simply by changing the (domain name in the) app identifier. EDIT2:在这种情况下,我可以使用其他域名,并且只需更改(应用程序中的域名)应用程序标识符即可使应用程序正常工作。 Clearly Xcode had an expired provisioning profile in the system which it insisted on using. 显然,Xcode在其坚持使用的系统中具有过期的配置文件。 This is not an ideal solution for others, so I will not write it as an answer, although the problem now no longer exists for me. 对于其他人来说,这不是一个理想的解决方案,因此尽管我现在不再存在此问题,但我不会将其作为答案。

You have chosen adhoc based provisioning profile ,you have to choose development based provisioning profile . 您选择了基于临时的配置文件,而必须选择基于开发的配置文件。 Go to developer.apple and download your app development provisioning profile then choose in Xcode build setting -> code signing tab then launch I am sure you will able to launch your app as well. 转到developer.apple并下载您的应用程序开发配置文件,然后在Xcode构建设置->代码签名选项卡中进行选择,然后启动我相信您也将能够启动您的应用程序。

Thanks. 谢谢。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Monotouch App不会在Device上启动,但在Simulator中工作正常 - Monotouch App will not launch on Device but works fine in Simulator iOS应用程序在模拟器中以后台模式工作,但在设备中不工作吗? - iOS app works in background mode in simulator but not in device? 应用程序在设备上崩溃但在模拟器 iOS 上工作 - App crash on device but works on simulator iOS iOS-应用程式可在装置上运作,但无法在模拟器上运作(不再) - iOS - app works on device but not on simulator (anymore) iOS应用可在模拟器上运行,但不能在真实设备上运行 - iOS app works on simulator but not on real device 应用程序在设备上崩溃 - 在Simulator上完美运行 - Application crashes on device - works perfectly on Simulator 仅使用LLDB()启动时iOS应用程序崩溃(该应用程序在模拟器中运行) - iOS App Crash On Launch With Only LLDB() (The App Works In Simulator) 应用程序适用于模拟器但不适用于设备 - App works on simulator but not on device 仅在调试时在没有启动设备时iOS App崩溃-不在模拟器中或在正常启动设备应用程序时崩溃 - iOS App crashes on launch no device while debugging only - not in simulator or during normal device app launch 在iOS模拟器上可以使用,但在iOS设备上不能使用吗? - Works on iOS Simulator but not on iOS device?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM