Added an iOS target framework and restructured code to support that.