certik / yaml-cpp

Automatically exported from code.google.com/p/yaml-cpp
MIT License
0 stars 0 forks source link

clang++ -stdlib=libc++ linker error #266

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Compiles fine if not using libc++

clang++ -stdlib=libc++  t.cpp  -L. -lyaml-cpp
/tmp/t-eed552.o: In function `main':
t.cpp:(.text+0x79): undefined reference to 
`YAML::LoadFile(std::__1::basic_string<char, std::__1::char_traits<char>, 
std::__1::allocator<char> > const&)'
clang: error: linker command failed with exit code 1 (use -v to see invocation)

<t.cpp>

#include "include/yaml-cpp/yaml.h"

int main(void)
{
    YAML::Node config = YAML::LoadFile("config.yaml");
    return 0;
}

</t.cpp>

Original issue reported on code.google.com by dgalli...@gmail.com on 26 Nov 2014 at 2:55

GoogleCodeExporter commented 9 years ago
I think you'll have to have built yaml-cpp using libc++. Can you describe how 
you built yaml-cpp?

Original comment by jbe...@gmail.com on 24 Dec 2014 at 6:40