No such module Parse using Swift in Xcode 7.1 - ios

There are several questions addressing this issue already, but all of them (I think) are in reference to earlier versions of Parse using an objective-C bridging header to connect the framework. I am using the latest version of Parse that has support for Swift directly, which is a different setup process.
I've downloaded and added Parse to Xcode in the Build Phases -> Link Binary With Libraries. The directions on their website are extremely straightforward...download the SDK, add it to Xcode, import it, and done.
Parse seems to be added properly everywhere it should be:
But alas, when I use import Parse, I get a no such module error. I've tried adding the framework search path $(PROJECT_DIR) under Build Settings both recursively and non-recursively, and a few other recommendations from the other questions addressing this issue, but with no luck.
I'm wondering if this could be an issue with Parse or the Xcode beta, since both are extremely new, but I'm assuming the error is on my end, just not exactly sure where to look since the quickstart guide on Parse.com seemed so simple.

Apparently if you drag the Parse library to the 'Link with Binary Libraries' section, you will continue to get this error.
You have to drag Parse to the project navigator for it to properly import.
Since it should work regardless of where you drag it into Xcode, it is possible this could be a problem with the Xcode 7.1 beta or the updated Parse API for Swift support. I'm not entirely sure, but either way, it's a really simple fix, so not a big deal.

Related

Updating Xcode cause fail in loading frameworks

I have updated my Xcode Client to 10.0 and installed all components. Now i have 9 errors in my project (a Swift project, that needs to be converted to Swift 4.2).
I use Facebook and Vuforia framework, and it seems like the problem lies there. I have tried to update the Pods, but this make no difference.
It is like the frameworks cant be read properly, because they are not converted yet. But i cant convert to Swift 4.2 as long as the build faild. Do i need to update the frameworks somehow?

Is there any way to hack into static framework for Swift Project?

So, plenty of issues have been posted around this like:
Stack Overflow Question
Google Code Issue Report.
The problem in few words is the following: GoogleMaps SDK has an error when updating to XCode 7 GM (consequently using Swift 2), because when loading the bundle resources, apparently it can't find/read the '.mom'/'.omo' file.
'CoreData: Failed to load optimized model at path '.../APP_NAME/GoogleMaps.bundle/GMSCacheStorage.momd/Storage.omo'
This answer explains a workaround if I were to load the resources mannually or if using a POD, but my problem is that I'm linking to the static library manually to support iOS 7.x (long story, Pods on swift only work with dynamic libraries and iOS 7 doesn't support them, but it worked perfectly until XCode 7/Swift 2). Maybe someone knows a way to hack into the GoogleMaps.bundle inside the framework file...
I'm thinking of something like -> (right-click GoogleMaps.bundle + Show Package Contents + 'maybe change some file paths/extensions?')
Apart from the Log Error, Google Maps functionality (at least the features I'm using) work fine in the app. The problem is when uploading to the App Store, I receive an error because of this.
This issue is fixed in the new update of Google maps
https://developers.google.com/maps/documentation/ios-sdk/releases?hl=en
Check this Link and update your local repositories

Adding Mapbox to iOS project

So, ... I went through the tutorial, using the binary steps to go through this.
I went through some answers here and that's where it gets confusing as there are even more variations on which linker flags to add and header paths, etc.
I tried these: MapBox iOS SDK within your own Xcode no help.
The project doesn't find the classes/headers.
The only project I found that works is their sample XCode project. I replicated all those dependencies, no luck.
I could put all my code into the iOS example, but it over a year old and not indicated to include the latest version 1.6.1.
I hate cocoapods as they add too much setting up into the project and if I get the same issue with other 3rd party frameworks, (there's plenty ill documented out there) how woudl I add that?
So, anyone else having those issues of the Mapbox tutorial not working and what was your solution?

write an iOS 5.1 app that uses a web service

I am fairly new to iOS programming and I'm trying to make an iOS 5.1 app that communicates with a server to receive information from a database. I got the server returning the needed information from the database by following this tutorial:
http://www.raywenderlich.com/2941/how-to-write-a-simple-phpmysql-web-service-for-an-ios-app
But then I tried to follow a the other half of the tutorial by the same guy:
http://www.raywenderlich.com/2965/how-to-write-an-ios-app-that-uses-a-web-service
In this one we use JSON, ASIHTTPRequest and MBProgressHUD, but I get a lot of errors when I run this because ASIHTTPRequest is no longer supported in iOS 5.1.
Can anyone point me in the right direction here? I you can show me another tutorial that works for iOS 5.1 that would be great. I have looked but I can't find any.
Thanks
ASIHTTPRequest is most likely returning errors in your iOS 5.1 app because you're using ARC. ASIHTTPRequest wasn't written in ARC, which is why it's throwing tons of errors. But there's an easy workaround:
In Xcode 4's groups and files pane, select your project file at the top of the list.
Select your target towards the left hand panel.
You should now see a list of all the implementation (.m) files referenced and compiled throughout the course of the program.
Double click the implementation files for ASIHTTPRequest and add the following linker flag: -fno-objc-arc. This linker flag acts as a crossbridge between the old non-ARC files and your ARC-based project.
Although there may be residual warnings left, this trick should remove all other error messages associated with ASIHTTPRequest.
When I followed that same tutorial I got a lot of errors. and the build kept failing until I reliased it was because libz.1.2.3.dylib wasnt there. If you go to Build Phases, remove that from the list and add libz.1.2.5.dylib all mine worked first and I got the app working fully :)

How to build against the RestKit framework in Xcode 4.2?

I am trying to follow this tutorial for integrating RestKit into my project but I am running into some problems. When I add a target dependencies the dialog that popup does not have the bulls eye. I still select the RestKit one (this has a little building next to that's white. Then when I click on Link with Libraries, and I dont get the choices to add the libraries for restkit. Ive tried this in my current project, a blank project, and nothing seems to work. Any ideas what I am doing wrong?
That tutorial is a little out of date. They updated the way Restkit builds (simplified it). There's a thread about it on the Restkit mailing list.
That said, here's what it would look like with the latest Xcode:
So for iOS you'd select the first on the list, with the little house-looking graphic. For Mac you'd choose the framework.
I found the tutorial at https://github.com/RestKit/RestKit/wiki/Installing-RestKit-in-Xcode-4.x to work with Xcode4.2. Make sure you follow all the directions. But, here's the catch. I couldn't get it to work with a project that I convert from xcode3. Probably could have but gave up. I made a new project in 4, dropped all my sources in it, then followed the directions in the above tutorial.
You can just drag the libRestKit.a file from the Products Group of the RestKit project into the Link with Libraries Build Phase of the build target that needs it.

Resources