I'm new to Objective-C and Xcode.
I'm trying to parse a YAML file from my .mm file. I decided to use the yaml-cpp library to accomplish this task.
I downloaded the source and added all the header files to my project. I can include the yaml.h header file in my .mm file and it successfully builds.
#include <yaml-cpp/yaml.h>
...
When I try to execute the sample code, with the following statement:
std::ifstream yamlReader("vmap3_styleattrs.yaml");
YAML::Parser yamlParser(yamlReader);
I get the following error:
Undefined symbols for architecture x86_64:
"YAML::Parser::Parser(std::__1::basic_istream<char, std::__1::char_traits<char> >&)", referenced from:
-[StyleSheetTests testGeoCSSTestAPIPrototype] in StyleSheetTests.o
"YAML::Parser::~Parser()", referenced from:
-[StyleSheetTests testGeoCSSTestAPIPrototype] in StyleSheetTests.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
The funny thing is, it compiled the first time, but every successive attempt since then, the build has failed with the message above.
I'm wondering whether this question is related to my situation, although I'm not sure.
I'd appreciate any inputs.