编译 OGRE 教程示例时遇到问题。

发布于 2024-12-08 08:23:26 字数 1774 浏览 2 评论 0原文

我已经使用 Code::Blocks 构建并安装了 Ogre 到我的 Debian。接下来,我尝试编译教程应用程序,但出现以下错误:

obj/Debug/BaseApplication.o: In function `BaseApplication':
/home/ver/projects/testogre/BaseApplication.cpp:34: undefined reference to `Ogre::StringUtil::BLANK'

/home/ver/projects/testogre/BaseApplication.cpp:34: undefined reference to `Ogre::StringUtil::BLANK'
obj/Debug/BaseApplication.o: In function `~BaseApplication':

/home/ver/projects/testogre/BaseApplication.cpp:45: undefined reference to `Ogre::WindowEventUtilities::removeWindowEventListener(Ogre::RenderWindow*, Ogre::WindowEventListener*)'

/home/ver/projects/testogre/BaseApplication.cpp:47: undefined reference to `Ogre::Root::~Root()'
obj/Debug/BaseApplication.o: In function `BaseApplication::configure()':

/home/ver/projects/testogre/BaseApplication.cpp:56: undefined reference to `Ogre::Root::showConfigDialog()'

/home/ver/projects/testogre/BaseApplication.cpp:60: undefined reference to `Ogre::StringUtil::BLANK'

/home/ver/projects/testogre/BaseApplication.cpp:60: undefined reference to `Ogre::Root::initialise(bool, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'

obj/Debug/BaseApplication.o: In function `BaseApplication::chooseSceneManager()':
/home/ver/projects/testogre/BaseApplication.cpp:73: undefined reference to `Ogre::StringUtil::BLANK'
/home/ver/projects/testogre/BaseApplication.cpp:73: undefined reference to `Ogre::Root::createSceneManager(unsigned short, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'

我添加了 /usr/local/include/OGRE 和 /usr/local/lib/OGRE 但这没有帮助。 =(

I have built and installed Ogre to my Debian with Code::Blocks. Next, I tried to compile a tutorial application but I'm getting these errors:

obj/Debug/BaseApplication.o: In function `BaseApplication':
/home/ver/projects/testogre/BaseApplication.cpp:34: undefined reference to `Ogre::StringUtil::BLANK'

/home/ver/projects/testogre/BaseApplication.cpp:34: undefined reference to `Ogre::StringUtil::BLANK'
obj/Debug/BaseApplication.o: In function `~BaseApplication':

/home/ver/projects/testogre/BaseApplication.cpp:45: undefined reference to `Ogre::WindowEventUtilities::removeWindowEventListener(Ogre::RenderWindow*, Ogre::WindowEventListener*)'

/home/ver/projects/testogre/BaseApplication.cpp:47: undefined reference to `Ogre::Root::~Root()'
obj/Debug/BaseApplication.o: In function `BaseApplication::configure()':

/home/ver/projects/testogre/BaseApplication.cpp:56: undefined reference to `Ogre::Root::showConfigDialog()'

/home/ver/projects/testogre/BaseApplication.cpp:60: undefined reference to `Ogre::StringUtil::BLANK'

/home/ver/projects/testogre/BaseApplication.cpp:60: undefined reference to `Ogre::Root::initialise(bool, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'

obj/Debug/BaseApplication.o: In function `BaseApplication::chooseSceneManager()':
/home/ver/projects/testogre/BaseApplication.cpp:73: undefined reference to `Ogre::StringUtil::BLANK'
/home/ver/projects/testogre/BaseApplication.cpp:73: undefined reference to `Ogre::Root::createSceneManager(unsigned short, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'

I have added /usr/local/include/OGRE and /usr/local/lib/OGRE but that did not help. =(

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

何时共饮酒 2024-12-15 08:23:26

当你编译时,你必须将 OgreMain 库链接到你的可执行文件。

when you compile you have to link OgreMain library to your executable.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文