Update 2: August 17, 2011 The TechExxpert guide has been updated to fully allow Xcode 4.1 to work. Sorry that the past fixes did not work. Thanks for the comments! Please let me know if this guide works/doesn't work.
Update: This guide has been modified to the latest updates as of August 2, 2011 including the latest Xcode 4.1 and OS X Lion 10.7.
Apple has been adamantly refusing to create an iPhone SDK support for Windows-based machines. Luckily, there is a work around to be able to fully run the iOS SDK and Xcode support for most all PC's.
The following steps involve installing a virtual machine on your PC, updating the virtual machine to 10.7 , then running the machine and downloading and installing the iOS SDK and Xcode on to the virtual machine.
There are other ways to install OS X on your machine but they involve creating a new partition and installing the Operating System directly to your hard drive. Those ways are much harder and have more confusing steps that could potentially damage your computer. This method is easier and safer to use.
The process will take 2-3 hours, but most of the time is consumed by large downloads. There's no software to buy or developer fees to pay.
Instructions1. Follow the steps
here to download and install a virtualized version of OS X Lion on your PC.
2. If you don't have a free Apple Dev Account, create one
here. You'll need this to be able to download Xcode 4.1 for free. In OS X, open the
App Store and download
Xcode. You can view progress of the download under the
Purchases tab.
3. Once the progress bar is finished, it will say it is installed but it really isn't. Open the
Applications folder from
Finder. Double-click on the
Install Xcode icon.
4. Follow the on-screen directions then wait for the installation to finish.
6. Once it's done, it should open by itself. If it doesn't, you will
NOT find the iPhone SDK in your dock. You will need to open your
hard drive. Then Click on
Developer, then on
Applications.
7. You will now see an icon for Xcode, click it and you can start coding applications.
If the icons don't show up, you may not have enough virtual hard drive space to fit the program. Make sure you have at least 10 GB of free memory in the virtual machine. Restarting your machine may be another way to make the icon appear.
Now you can start coding an app for your personal use. The language you will be coding in is Objective-C. If you don't have any experience with Objective-C, TheNewBoston provides free tutorials on
Xcode and
Xcode iPhone development. I recommend following the Objective-C tutorials
first.
You will be able to test your app on the iPhone simulator in Xcode but you will not be able to add the app to your own device. To add an app that you've created to your device, see the two options below.
Option 1: If you want to submit your app to the App Store, you will need to pay Apple $100 for
an official Developers Certificate. This will allow you to sell your app to a very large audience but Apple does place large restrictions on its approval of submissions.
Option 2: If you don't want to pay the $100, you can develop your application for Cydia (similar to the App Store). This option will also allow you to place your app on to your iPhone, not just only in the Xcode simulator.
Cydia is the unofficial App Store for users who have jailbroken and want to sell/share their apps. There are almost no restrictions as to what kind of apps that can be added to Cydia.
To develop for Cydia, you will need to have your device jailbroken (
How do I jailbreak?) and before you start developing your app, you will need to follow
these steps to create an alternate Certificate.