This question already has answers here:
Closed 13 years ago.
Possible Duplicates:
How can I develop for iPhone using a Windows development machine?
I'm looking to build an iPhone app for my wife's phone, but am not interested in buying a Mac as a development platform for a one-off piece of work. The app:
should run standalone on the iPhone (i.e. without network connectivity)
would be perfectly acceptable with a GUI created using one of the iPhone Javascript libraries that are around
will do some database IO to read and update data
has no commercial value and will never be used by anyone else
Here's my thinking:
jailbreak the iPhone
install Ruby + Sinatra on the iPhone
write the app using Sinatra, hitting a database (SQLite?) on the iPhone
To access the app on the iPhone:
start the Sinatra app in the
background (is this possible?)
start a Safari browser session
navigate to the Sinatra app at e.g. http://localhost:12345
etc.
This seems like a strange approach, but I can't think of a simpler way of writing a standalone iPhone app without buying a Mac. Is there a better way of doing this?
The only reliable info I could find is at the always-excellent MetaFilter
http://ask.metafilter.com/110466/Anyway-to-develop-iPhoneiTouch-apps-without-investing-in-a-Mac
The answer is apparently no.
You absolutely need an Intel Mac of some description.
The entire iPhone build process is too deeply ingrained in XCode to build elsewhere; and the only other Objective-C compiler I know is gcc, which doesn't support any Apple's additions to the language (nor their libraries).
And, in direct opposition to what people are saying above, Objective-C is absolutely my favorite native, compiled language. Elegant, small (only a few changes from C), late-binding, dynamic, straightforward. It's what C++ should have been.
Lots of people recommend picking up a secondhand Intel (remember, must be Intel!) Mac Mini as the cheapest "port of entry".
What you have described is a viable solution, however you should consider using the open toolchain for the iphone.
You don't need a mac then, only need to jailbreak the phone to make sure your app will work.
For all those who say it can't be done, this was the only way to make Apps for the iphone before the SDK was out :)
Also if you are after a guide to using the open toolchain then I highly recomend this book
If you're considering creating a GUI using a javascript library anyway, why don't you just write a web app instead of an iPhone-native one? It seems like overkill to jailbreak the device just so that you can install a ruby + sinatra web app on it. Can't you just put the ruby web app on a server and create a Safari shortcut to it on the home screen? If you don't have a server, you could always run the website off a PC in your home...
Jailbreaking the OS and running a ruby app onto it would be technically cool, don't get me wrong - I just think it'd end up being a time sink.
Just my 2c!
Depends on what your time is worth, I guess. That seems like a terribly convoluted way to get what is otherwise a simple app on the phone to avoid the US$400 purchase of a used Mac Mini.
There is the hackintosh route, which may work on your existing hardware, but again one has to put a price on time. It's what got me started before I dropped big coin on a Macbook Pro, an MSI Wind then a home-built. It's of questionable legality (the right thing to do is fork over US$129 for Leopard regardless), but you are already talking about jailbreaking. :-)
Get someone else to do it, or rent the resources that you need.
Another option is to find nearby iPhone developer who has it all setup and either get him to write the app or do it together, he provides development environment you code the solution or code it together.
The only problem is that you wont be able to update maintain it.
I would still consider getting older gen Mac or Mac mini - all the other options sound more complicated.
If you are going to be stubborn about not using a mac, but you want an app that will work offline with the iPhone / iPod Touch and Android devices, then I would use HTML 5 to create an offline app.
You can do a lot now with HTML 5 - Google have an email client that uses HTML 5 for the iPhone now and it can work offline etc. If you do this and get the user to add a bookmark to their home screen for your app - it will be almost as good.
If I was you I'd fork out for a mac - or look to see if you could borrow one - or time-share with someone - you will not create a very good quality app without it.
You can jailbreak the phone and install Python. There are some sample applications in Cydia for it (it's called iPhone/Python. Search for Python in cydia).
Then you will have a "native" app, not a web application and you can use the entire iPhone UI library (the part of it that is accessible via py-objc anyway) and you don't need to run a web server in the background.
You can do your development on the phone itself via SSH or you can use an iPod Touch for it. Packaging is also easy (should you need it), just create your own Cydia repository and host your package(s) in there.
Look at iPhone applications in Python for more information.
Come on, just look on eBay for the cheapest intel mac mini you can find. Even a Mac laptop with a busted screen (that you could hook to an external display) would work. You're talking just a few hundred dollars probably and then you can maintain it as her phone/Touch is upgraded.
there's some special meta tags you can put in a webpage to make your web app savable and full screenable to the iphone hard drive. (so it can work offline) Here's an example : http://mrgan.tumblr.com/post/125490362/glyphboard2
There's also frameworks like phonegap that let you access cocoa apis from javascript, but it sounds like you don't need that.
Does your wife enrolled in any kind of data plan? If so, you can simply write a small webapp which runs on some cheap webspace and access it via MobileSafari.
If you need a full grown iPhone application, you better look after one of the first intel-based mac minis on eBay, should be to expensive, in my opinion. And as a plus you avoid the hassle of a jailbreak.
Related
I have developed an app on monotouch-5.2.5 evaluation version.
Now i want to deploy on Apple Store and to do it i have bought a full monotouch version (5.2.10) and i have installed all certificate and provisioning profile.
When try to build my app i have the following problem:
mtouch exited with code 99
i have this configuration:
monodevelop 2.8.6.5
mac os x version 10.6.7 (is an HACKINTOSH)
Do could it be a incompatibity problem beetween HACKINTOSH and MonoTouch?
...This it'll seem strange because i've develop on it without problems.
The Xamarin.Mac / Xamarin.Ios licencing does some kind of hash of the Mac hardware to give your machine a unique ID. This locks the MonoTouch licence to your machine.
I know previously when people have changed hard drives etc. it has broken the key, this is because they use the Hard drives serial number as part of the hash. They may also use hardware MAC addresses and other IDs.
I imagine something they use in a Genuine Mac is not available in your Hackintosh.
Xamarin states on their website they do not support Hackintosh. They claim it is too hard to ensure their compiler works properly in such a system, but they do not stop there. They also make it impossible to install a key on a Hackintosh or on a Mac running in a VM!
I can understand they wont provide support for issues happening in such an environment, but to force developers to buy a Mac is a bad move. Especially considering a lot of their customers choose Monotouch exactly because they are comfortable with Windows/.net already and are not eager to migrate 100% to Mac OS, it is pretty obvious many prefer to work in a VM or use their existing PC hardware.
I used the trial version in a VM without any issues whatsoever, so whatever technical issues they might be worried about seems irrelevent. So I think this is more a political issue than a technical one.
I can only hope they will change their policy, or that someone gets annoyed enough to crack their compiler so that we can all use it the way we prefer.
I have a Hackintosh, I just encountered the same problem, and I also can not login app store, because ethernet card not built-in, I modified the DSDT to complete built-in, it is OK.
It is obvious that you need to contact Xamarin Support because they know better whether this is the exact problem or not. but....
A Statement in Xamarin Page demonstrated that it is impossible to use MonoDevelop/MonoTouch on Hackintosh.
I have some misunderstands that I need to know:
1. What do you mean building? (Bundle/Deploy to device/Build on Simulator)
2. Did you tried deploying to device?
I googled this issue and there are many that had this error code, but their problem was MonoTouch Activation, I think you can reactivate MonoTouch to make sure. (if you want to build on device)
But I do not attribute this error code to Hackintosh, because one of my friends-who is working with Unity (Mono) on Hackintosh, can easily build on device.
Regards,
Peyman Mortazavi
Is it possible to port mac source code to ios (iphone and ipad) easily. The mac application is using both C and Objective C languages. What i asssume is to create xib files for mac nib files, and port the code for ios. Any suggestions???
Cheers
Yes, it's possible. How hard it is depends on how heavily your desktop app relies on a keyboard, mouse and a large screen. In general, porting an app from the desktop to a mobile device is far from trivial, for reasons that have nothing to do with the portability of APIs and project files.
Essentially, you're correct about what you need to do. Since Objective C is a strict superset of C, your code should run fine, although you'll obviously need to change the API calls to iOS-oriented ones. The main task would likely be to recreate your interface and how it hooks into your code, but that shouldn't be too much of a problem for a well-designed MVC application. You may also need to give consideration to your application's lifecycle - compared to Mac applications, iOS apps tend to be used for much shorter periods, and can be quit with little or no notice, so they need to keep a lot more of their state in persistent storage (or be ready to save it quickly and automatically on exit), rather than relying on the user triggering an explicit save.
Without knowing more about your application, I can't give you any more than this general advice. I can only recommend that you give it a shot - the simulator is free.
From the recent news from the Apple, I learned that one has to use C/C++/Objective-C for iPhone App. Accordingly, it's not possible to use MacPython or similar to make iPhone App.
But as the python/ruby interpreter itself is written in C, isn't it OK to make python/ruby interpreter for iPhone to run the scripts on iphone?
Is this possible? Does Apple support this? Or does someone implemented this? Or, the user should hack to do this?
Added
I don't distribute the python script, I just use it for my own utility. Even in this case, do I need a jailbreak? I mean, can I compile the python with Xcode to get the binary? Or, I expect someone has already done this.
Apple recently changed their policy on this and allowed a python interpreter App called Python for iOS to be put up on the App store:
http://itunes.apple.com/us/app/python-for-ios/id485729872?mt=8&uo=4
Full disclosure: I am the sole creator/developer of Python for iOS.
At present not at all. Apple licenses forbid to run any intepreter on it, and this is even before iPhone OS 4. You can make an intepreter by jailbreaking it but it won't be official and you won't be able to distribute it.
I don't distribute the python script, I just use it for my own utility. Even in this case, do I need a jailbreak?
No, you don't. You can compile a Python interpreter and run it on your own iPhone, as long as you have a developer license.
Maybe you can use ad-hoc distribution (according to Apple, you can distribute your app to 100 devices by yourself, outside of the app store) ?
See here
I want to make my iphone run application in the background.I know there is a program called "backgrounder",but it isn't I want.What should I do?
This is flat out not allowed... period.
You may want to look into the development community for jailbroken phones. I think there are projects like that there, although you are severely cutting off your userbase.
As title; is there any function that can achieve this?
Officially, no. Official apps must be compiled and signed on an OS X machine.
In practice, sort of - if you don't mind jailbreaking. For jailbroken phones, gcc and signing tools are available that run on the iPhone. So on jailbroken phones you could have an application that generated new applications. Apple wouldn't let you sell such an app in the App Store, though.
Theoretically maybe, practically no. If you want to sell it in the App store double no.
I would take a look at this link which quotes the SDK in saying:
3.3.2. [..] No interpreted code may be downloaded and used in an Application
except for code that is interpreted
and run by Apple’s Published APIs and
built-in interpreter(s).
and
3.3.3 Without Apple’s prior written approval, an Application may not
provide, unlock or enable additional
features or functionality through
distribution mechanisms other than the
App Store.
between those two restrictions I think it would be practically impossible to dynamically create any kind of application on the fly (with the possible exception of the pure JavaScript/HTML app concept mentioned in the article).
If your iPhone is jailbroken, install "CallMe" from Cydia.
That does exactly what you want: It generates small applications with the icon of a contact, and if you launch one of those small apps, that'll launch the phone app and call the phone number of the contact.