iphonesim
iphonesim copied to clipboard
Does not work with xCode 4.3 and newer
Since xCode 4.3 Apple has changed its location to /Applications/Xcode.app Due to those changes I'm unable to use the "iphonesim" tool (see the log below).
Please update your code base to keep up with the latest xCode.
Oleksandrs-Mac-mini:Release-iphonesimulator dodikk$ ls CoreDataBooks.app CoreDataBooks.app.dSYM
Oleksandrs-Mac-mini:Release-iphonesimulator dodikk$ iphonesim launch "/Users/dodikk/projects/research/zucchini/CoreDataBooks/build/Release-iphonesimulator/CoreDataBooks.app" 5.0 iphone dyld: Library not loaded: @rpath/DevToolsFoundation.framework/Versions/A/DevToolsFoundation Referenced from: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/PrivateFrameworks/iPhoneSimulatorRemoteClient.framework/Versions/A/iPhoneSimulatorRemoteClient Reason: image not found Trace/BPT trap: 5
dodikk : have you find any solution for this???
Take a look at UIAutomation based approach here : https://github.com/farcaller/ios-tdd/tree/master/Tests/Jasmine
It works with gh-unit just fine. Consider using OCUnit instead. At the moment it's capable of of being debugged and handling bundles.
Anyway, last commit in this repo is 2 years old. The project looks abandoned.
In my opinion, there is no point to bring "iphonesim" back to life as approaches, mentioned above are good enough for most users ( including myself ).
how did you solve this? I would like to try iphonesim, as I don't have success with ios-sim...
I have not solved this. I used the other approach based on apple's UIAutomation. (consider the link above)
iphonesim does not work with "xCode 4.3" and newer. And I don't think it will ever get fixed.
hi, I got a idea from http://developer.appcelerator.com/question/132298/an-ios-sdk-is-missing and solved the problem on xcode 4.3 by setting the correct rpath in project settings.
-
open iphonesim.xcodeproj in Xcode 4.3
-
go to the project settings, select target "iphonesim"
-
in "build phases", add the following framework to "Link Binary With Libraries"
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/PrivateFrameworks/iPhoneSimulatorRemoteClient.framework
-
in "build settings", remove all original setting in "Other Linker Flag" and set it as follow:
-Wl,-rpath -Wl,$(DEVELOPER_DIR)/Platforms/iPhoneSimulator.platform/Developer/Library/PrivateFrameworks -Wl,-rpath -Wl,$(DEVELOPER_DIR)/../OtherFrameworks
-
build the project, it should be ok now.
hi guys , i find a fork of this repo at https://github.com/Fingertips/ios-sim , it has additional features and support Xcode 4.3
both doesn't work for me, unfortunately; ios-sim give a session-timeout (http://stackoverflow.com/questions/10408389/ios-sim-doesnt-start-app-correctly-in-simulator) and iphonesim can't build with the changes:
ld: in /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/PrivateFrameworks, can't map file, errno=22 for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation)
oylbin, do you have a fork/pull request with your idea implementation?
P.S. When I fixed path to the iPhoneSimulatorRemoteClient.framework I was still getting a runtime crash.
Was in the same boat as you guys.
Abit more digging shows https://jira.appcelerator.org/browse/TISTUD-1196
Retrying with pegli's branch works: https://github.com/pegli/ios-sim
git clone https://github.com/pegli/ios-sim.git
Good luck :D
I've finally got it working. https://github.com/EmbeddedSources/iphonesim/ The solution has been based on "moredip/iphonesim" work.
By default it does not wait for tests completion. I've fixed that in "EmbeddedSources/iphonesim" fork, which now has both "iphonesim launch" and "iphonesim launch-async" capabilities.
Summarizing the discussion above, we have the following working ways to launch an app in the simulator :
- "pegli/ios-sim" - checked by @mcCuppaT
- "moredip/iphonesim" --> "EmbeddedSources/iphonesim" - checked by @dodikk
- UIAutomation approach by @farcaller -- https://github.com/farcaller/ios-tdd/tree/master/Tests/Jasmine
- www.zucchiniframework.org
Thanks everyone.