I'm trying to purse a XML file with TBXML I have done to following steps to use TBXML
- Click on your project main folder inside of XCode 4.0
- Click on the target
- Open tab called "Build Phases"
- Open up "Link Binaries With Libraries"
- Click "+" find the libz.dylib file
- Copy the needed files (TBXML.h, TBXML.m, NSDataAdditions.h, NSDataAdditions.m) into a group in my project
- added the #import "TBXML.h" on top of the page I'm going to use the library
after I add the following line (taken from the TBXML Guides) it comes up with an error that I should not use retain if I'm using Automatic Reference Counting.
TBXML * tbxml = [[TBXML tbxmlWithURL:[NSURL URLWithString:@"http://www.w3schools.com/XML/note.xml"]] retain];
After I remove the retain I end up with
TBXML * tbxml = [TBXML tbxmlWithURL:[NSURL URLWithString:@"http://www.w3schools.com/XML/note.xml"]];
When I try to run the App it shows the Following Errors:
"_OBJC_CLASS_$_TBXML", referenced from:
objc-class-ref in ViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
What should I do and how can I fix it?
Thank you