How can I run the iOS 7.1 Simulator in Xcode 7.0 beta 2?
Asked Answered
U

5

32

I have installed latest Xcode 7 beta 2 version, when I am trying to run the application in iOS 7.1 Simulator its giving this error message:

The iOS 7.1 simulator runtime is not available.

Unable to open liblaunch_sim.dylib. Try reinstalling Xcode or the simulator runtime.

Could you please let me know how to resolve this error?

Ultima answered 25/6, 2015 at 17:12 Comment(0)
D
16

You can't (At least in an Official way).

Taken from Xcode Beta 2 Documentation (Page 7).

Hope it helps.

EDIT SEPT - 2015:

Thanks Cœur for the info, now you can use previous versions of ios simulator.

Distributee answered 25/6, 2015 at 17:16 Comment(3)
Further to this: I've tried to find any sort of official or semi-official statement on whether this is likely to be the case after beta. I've failed.Unparliamentary
Link is dead. iOS 8.1 to 8.4 Simulators are supported. Spelling mistake at 'Docummentation'.Galicia
Not sure if this would still be relevant but iOS 7 simulator was working fine on the XCode 7.0 (final). After upgrade to 7.1 I get the same exact error msg as OP.Gratulant
C
35

Took a lot of browsing but I finally found a solution that worked for me (tried Gend's answer but didn't work). Execute the following lines:

sudo mv "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib"{,.bak}

sudo ln -sf "/Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/host/liblaunch_sim.dylib" "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib"

Source: https://gist.github.com/leecade/83b4e710d7c741152527

Calbert answered 6/8, 2015 at 8:48 Comment(13)
In XCode 7 beta 6 I don't see this error, but I can't launch app because it stuck in loading state.Cutback
One of my computers has no "/Library/Developer/", the other has an empty "/Library/Developer/CoreSimulator/Profiles/Runtimes/" folder.Galicia
I don't have a CoreSimulator folder in /Library/Developer.Telespectroscope
I got this to work under Xcode 7.0 release too, just had to change "Xcode-beta.app" into "Xcode.app".Hype
The IPC protocol used by the iOS 7.1 and iOS 8+ liblaunch_sim.dylib are not the same. You will run into issues doing this.Onfre
@mike have u managed to launch an app on ios7 sim in xcode 7?Combings
@JeremyHuddlestonSequoia do you have an alternative suggestion to this? Where do we find the iOS 8+ liblaunch_sim.dylib?Bathsheba
@Combings yes, it worked in Xcode 7 beta 1, afterwards iOS7 simulator disappeared. So for now there is no way to test it but on a device.Burro
Couldn't run 7.1 simulator on XCode 7.1 official with same error. I updated the commands to sudo mv "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib"{,.bak} ...then sudo ln -sf "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/host/liblaunch_sim.dylib" "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib". Runs, but no output logPollywog
7.1 simulator appears in xcode 7.1.1 and xcode is able to install apps, but they have to be run manually. debugging not working eitherCombings
unable to boot simulatorImplicative
@Prcela try to close all and the run it or even a restart, I had problems at first as well, so I tried many combination and finally it worked.Pathoneurosis
For Xcode 7.2.1 it ends up with "unable to boot simulator" alert. As before, I can't run iOS 7 simulator, but now alert message is different.Royo
D
16

You can't (At least in an Official way).

Taken from Xcode Beta 2 Documentation (Page 7).

Hope it helps.

EDIT SEPT - 2015:

Thanks Cœur for the info, now you can use previous versions of ios simulator.

Distributee answered 25/6, 2015 at 17:16 Comment(3)
Further to this: I've tried to find any sort of official or semi-official statement on whether this is likely to be the case after beta. I've failed.Unparliamentary
Link is dead. iOS 8.1 to 8.4 Simulators are supported. Spelling mistake at 'Docummentation'.Galicia
Not sure if this would still be relevant but iOS 7 simulator was working fine on the XCode 7.0 (final). After upgrade to 7.1 I get the same exact error msg as OP.Gratulant
D
6

First, find the target file:

/Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/host/liblaunch_sim.dylib

You need make backup liblaunch_sim.dylib (Just in case). Second, copied to destination (Remember to backup)

/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib

And If need it to: iOS 8.1.simruntime iOS 8.2.simruntime iOS 8.3.simruntime All done.

Hope it helps.

Diatomic answered 30/6, 2015 at 18:58 Comment(4)
I can't find the CoreSimulator folder under /Library/Developer. Why is that?Telespectroscope
@Telespectroscope I find CorseSimulator but Profiles doesn't appear, just "Devices". Tell me if you find it ! And I will tell you if I find :)Gervais
@Viny76 I ended up placing the liblaunc_sim.dylib after getting the iOS 7.1 simulator SDK from my old xcode located: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk/usr/lib/system/host/liblaunch_sim.dylib now it worksTelespectroscope
Now I get "Unable to boot the Simulator."Twana
M
2

When you are using sudo command and terminal says: "Command not found" Then use command like below.

sudo su (enter)

$ sudo mv "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 8.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib"{,.bak}(enter)

$ sudo mv "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib"{,.bak}(enter)

$ sudo ln -sf "/Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/host/liblaunch_sim.dylib" "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 8.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib"(enter)

$ sudo ln -sf "/Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/host/liblaunch_sim.dylib" "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib"(enter) Exit(enter)

Now relaunch Xcode 7 if open earlier.you will be able to run simulators.

Majesty answered 16/10, 2015 at 6:37 Comment(1)
when I try the above, for 7.1, I get mv: rename /Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib to /Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/system/host/liblaunch_sim.dylib.bak: No such file or directoryRecombination
T
1

In Xcode 7 beta 6 this seems to be possible now.

http://adcdownload.apple.com/Developer_Tools/Xcode_7_beta_6/Xcode_7_beta_6_Release_Notes.pdf

Xcode 7.0 beta now supports downloadable legacy simulators. (20699475)

I haven't found a place to download these yet though. I will update when/if I find them.

Tum answered 2/9, 2015 at 9:23 Comment(2)
Any update? I'd love to know where to download these!Toxic
The only thing I've found so far is Gend's answer above and pulling them out of the previous Xcode. Per this thread forums.developer.apple.com/thread/17108 it looks like there isn't going to be an official way to do this.Tum

© 2022 - 2024 — McMap. All rights reserved.