Sharing code in iPhone applications

Posted by lorenb on 7/16/2009 in game development, iphone |

There are two schools of though on iPhone application development.

Some people spend a lot of time/money on developing an iPhone application. I’ve posted articles about that before, people spending upwards of $100,000 on an app and making back a fraction of that.

Going away for 1-2 years and developing something in secret is a dead development model in my opinion. Coming from an Open Source background I prefer release early/often.

On the iPhone, rather than put 100% of all our effort/resources into a single app, we are planning to release multiple titles. The purpose to keep developing/learning, get feedback from users and act upon it.

For a specific app this will come in the form of updates. If you bought MMATracker 1.0 for example, you’ve seen numerous revisions and increased functionality. A lot that was driven by user feedback.

If an application completely bombs, we take the lessons learned and incorporate into the next app. We keep developing and pushing forward. We can do this because we are not spending tens of thousands on each application.

Writing multiple applications can be difficult and it’s in your interests to re-use code where possible. Otherwise you’ll never be able to manage all the code.

Normally this is done via a shared library. This would allow multiple apps to use the same code. Problem is that Apple doesn’t allow custom shared libraries on the iPhone.

The only way around this is to use a static library. For some reason, Apple/XCode makes this more difficult than it really has to be. I was having some trouble yesterday with one project and found this great article, Easy, Modular Code Sharing Across iPhone Apps: Static Libraries and Cross-Project References

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Copyright © 2004-2010 LB Technology Services Blog All rights reserved.
Desk Mess Mirrored v1.7 theme from BuyNowShop.com.