How should I launch app installed iPhone device by terminal? - iphone

I would like to launch app installed at iPhone device from terminal for development and testing.
I watched the below question and answer.
Launching instruments from command line with iPhone simulator
However I am using Mountain Lion and there are no such below file or path.
/Developer/Platforms/iPhoneOS.platform/Developer/Library/Instruments/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate
Would you tell me about how to use such automation launching of Instruments?

I had the very same problem a couple of days ago. Seems that starting from Xcode 4.4 Apple moved it to /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Instruments/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate
But in Xcode 4.5 I didn't find this directory as well. So I continued my search and found tracetemplate file in /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate
BTW, there's a nice shell script which automates running stuff. All you need is to replace INSTRUMENTS_TEMPLATE with a proper path in automation.sh

Related

Can't install an application on device via iPhone Configuration Utility

Something's changed recently with iPhone Configuration Utility, and I can't install an application on the device. It used to work well, but everything's changed (I suppose) after I updated iTunes to 11.0.2 and iPhone to 6.1.2.
The symptoms are:
Every time I start iTunes I got "Unknown error (-42110)" message.
iPhone Configuration Utility often lags and freezes.
iPhone Configuration Utility shows error "Could not transfer application to device. Error: kAMDUndefinedEror."
Any ideas how to solve it?
PS: Mac mini, Windows 7 Home Premium 64 bit
UPD: Fixed iTunes "Unknown error (-42110)" issue by removing C:\ProgramData\Apple Computer\iTunes\SC Info folder. But iPhone Configuration Utility still can't install an application.
Ohh.. you have updated your device to 6.1.2 so i think you need a Mountain Lion OS for MAC. since it is not able to work with lion 10.7.5 also. Update your system to mountain lion. it will be fine again.

not able run .app in mac lion os but no source code [duplicate]

This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
Unable to run an ipad application
I have an .app file built for ipad. Can i run it in mac lion os? I tried to run it on mac but i got a message box with following error.
"You can't open the application appname.app because it is not supported on this type of mac"
Please guide me how to run an .app file in mac lion os, xcode and in a simulator on mac os.
Thanks!
No, you can't run it. iOS and OSX apps are completely different types of apps, and an app designated for one can't be run on the other. They are different architectures, and would require a rewrite of an application to run it on the other.
Man, that is an iPad app. You need to run it in an iPad.

automate installation + running of iphone app in simulator outside of xcode

I'd like to install + run my app built outside of xcode (through xcodebuild) through a similar sort of command line tool. How could I get it on the simulator?
I've looked at a few related posts:
Where does the iPhone Simulator store its data?
Cleaning up the iPhone simulator
None of these posts describe what that UUID is, nor what the other files are in that directory.
So how I could I replicate XCode's installation + starting the app through a command line tool?

Is it possible to run iOS simulator on a Mac without Xcode installed?

There are a few questions relating to this topic but nothing quite the same when it comes down to the details:
We would like to use the iOS Simulator without installing the rest of XCode on a macbook. It is an in-house laptop, and will be used by employees, but not engineers.
We already know how to run applications on the simulator without the source code and compiling required, but it would be nice to be able to install a 100MB app and application support that can run our in-house distribution app as opposed to a 2.4GB XCode installation. Any ideas? Thanks.
The Simulator app requires several other large directories from the Xcode distribution in order to work at all. The only official way to install all of those properly is to install the entire SDK from the dmg. Then you can experiment with deleting the hopefully "unneeded" directories. Be prepared to start over if you delete something that the Simulator requires.
You would have to extract the Simulator pkg from the Xcode DMG. The only thing is that the Simulator depends on having an SDK installed, that way it knows which iOS to run the app in.
Simulators are not available as separate/stand alone downloads.
No, you can't download ios simulator stand-alone

Can't build a new project with xcode on my MacPro

I've installed on my MacPro (intel) Xcode 3.2.1 (iPhone SDK 3.1.2) and Snow Leopard
I made a new project (called Untitled) for iPhone OS, when I try to build, it returns an error:
*file not found:
*/Users/user/Documents/Untitled/build/Untitled.build/Debug-iphonesimulator/Untitled.build/Objects-normal/i386/main.o
*/Users/user/Documents/Untitled/build/Untitled.build/Debug-iphonesimulator/Untitled.build/Objects-normal/i386/UntitledAppDelegate.o*
*Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2 failed with exit code 1*
and doesn't go over!!
what i've to do to fix?
thank you for your answers
"Untitled" is a common place holder so it's possible that the using that as the project name has caused a problem with one of the build scripts. Try another project with a more unique name.
Other possible problems: (1) Permissions problem with the build directories (2) if you messed with the build settings you might have switched off the creation of the executable.
Edit01:
(Response to comment)
It sounds like you have a nasty corruption problem for some reason. Some things to try.
(1) Create a new user and try to run Xcode from that account. That will tell you if the problem is with the developer install or if its some kind of preferences or other file in the user's home directory. Xcode and the other dev apps dynamically create a lot of directories and files that an reinstall will not affect.
(2) You can do a complete uninstall of the developer tools from the command line.
sudo /Developer/Library/uninstall-devtools --mode=all
(3) Xcode is just a face application for a full suit of unix command line development tools. If you installed different versions of these tool e.g. gcc, gdb etc, you might have altered something critical.
(4) Xcode plug-ins can cause problems. Make sure you remove all of them.
I had a crash in Xcode once, and afterwards I could never get Xcode to run under that user account. I spent nearly two days trying to troubleshoot before giving up and moving to another account. That turned out to be a good thing because it allowed me to create an account focused solely on development without all the distractions of my normal account.
Doesn't Xcode 3.2 (not 3.1.2) ship with Snow Leopard? If you're using Snow Leopard, you should be using the appropriate version of Xcode for Snow Leopard, which is the 3.2 series.