【发布时间】:2014-12-14 03:40:41
【问题描述】:
我正在尝试在 mac os x 上使用 SFML 编译最小项目。我正在使用以下命令:
g++ -o rj -framework SFML -lsfml-graphics -lsfml-audio -lsfml-window -lsfml-system main.cpp
使用以下代码:
# include <SFML/Graphics.hpp>
int main()
{
sf::RenderWindow App(sf::VideoMode(800, 600, 32), "test");
return 0;
}
并得到一个错误:
Undefined symbols for architecture x86_64:
"sf::String::String(char const*, std::__1::locale const&)", referenced from:
_main in main-15430b.o
ld: symbol(s) not found for architecture x86_64
我做错了什么?
【问题讨论】: