Pointers to resolve compiler errors

For help with general CEGUI usage:
- Questions about the usage of CEGUI and its features, if not explained in the documentation.
- Problems with the CMAKE configuration or problems occuring during the build process/compilation.
- Errors or unexpected behaviour.

Moderators: CEGUI MVP, CEGUI Team

Bickleigh
Just popping in
Just popping in
Posts: 2
Joined: Sun Jun 30, 2013 17:41

Pointers to resolve compiler errors

Postby Bickleigh » Sun Jun 30, 2013 18:44

Hi,
I am a new member. I will say straight off the bat that I am a Python rather than a c++ programmer. I can find my way round a compiler (in this case VS10) but I will admit that the black art that you guys practice is sometimes a bit beyond me :?

I am involved in a project which requires a more exotic gui UI instead of the vanilla flavors you get with wxpython. A friend suggested I try CEGUI which he said comes with a python wrapper.
I am building using the instructions in the wiki :rofl: and from other sources and have overcome the various gotya's that always seem to accompany these types of builds. :hammer: But I have hit a wall and I am going to need some of your magic.
The problem is link errors specifcally lnk2019

I am only getting errors from one specific package: PYCEGUIOpenGLRenderer.

Here are the errors:

Code: Select all

1>     Creating library d:/Desktop/working/cegui/build/lib/PyCEGUIOpenGLRenderer_d.lib and object d:/Desktop/working/cegui/build/lib/PyCEGUIOpenGLRenderer_d.exp
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: void __thiscall CEGUI::OpenGL3Shader::unbind(void)const " (?unbind@OpenGL3Shader@CEGUI@@QBEXXZ) referenced in function "void __cdecl register_OpenGL3Shader_class(void)" (?register_OpenGL3Shader_class@@YAXXZ)
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: void __thiscall CEGUI::OpenGL3Shader::link(void)" (?link@OpenGL3Shader@CEGUI@@QAEXXZ) referenced in function "void __cdecl register_OpenGL3Shader_class(void)" (?register_OpenGL3Shader_class@@YAXXZ)
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: bool __thiscall CEGUI::OpenGL3Shader::isCreatedSuccessfully(void)" (?isCreatedSuccessfully@OpenGL3Shader@CEGUI@@QAE_NXZ) referenced in function "void __cdecl register_OpenGL3Shader_class(void)" (?register_OpenGL3Shader_class@@YAXXZ)
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: unsigned int __thiscall CEGUI::OpenGL3Shader::getUniformLocation(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)const " (?getUniformLocation@OpenGL3Shader@CEGUI@@QBEIABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function "void __cdecl register_OpenGL3Shader_class(void)" (?register_OpenGL3Shader_class@@YAXXZ)
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: unsigned int __thiscall CEGUI::OpenGL3Shader::getAttribLocation(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)const " (?getAttribLocation@OpenGL3Shader@CEGUI@@QBEIABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function "void __cdecl register_OpenGL3Shader_class(void)" (?register_OpenGL3Shader_class@@YAXXZ)
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: void __thiscall CEGUI::OpenGL3Shader::bindFragDataLocation(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (?bindFragDataLocation@OpenGL3Shader@CEGUI@@QAEXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function "void __cdecl register_OpenGL3Shader_class(void)" (?register_OpenGL3Shader_class@@YAXXZ)
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: void __thiscall CEGUI::OpenGL3Shader::bind(void)const " (?bind@OpenGL3Shader@CEGUI@@QBEXXZ) referenced in function "void __cdecl register_OpenGL3Shader_class(void)" (?register_OpenGL3Shader_class@@YAXXZ)
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: __thiscall CEGUI::OpenGL3Shader::~OpenGL3Shader(void)" (??1OpenGL3Shader@CEGUI@@QAE@XZ) referenced in function __unwindfunclet$??$?0U?$reference_to_value@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@objects@python@boost@@U0123@@?$value_holder@VOpenGL3Shader@CEGUI@@@objects@python@boost@@QAE@PAU_object@@U?$reference_to_value@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@123@1@Z$0
1>OpenGL3Shader.pypp.obj : error LNK2019: unresolved external symbol "public: __thiscall CEGUI::OpenGL3Shader::OpenGL3Shader(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (??0OpenGL3Shader@CEGUI@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@0@Z) referenced in function "public: __thiscall boost::python::objects::value_holder<class CEGUI::OpenGL3Shader>::value_holder<class CEGUI::OpenGL3Shader><struct boost::python::objects::reference_to_value<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &>,struct boost::python::objects::reference_to_value<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &> >(struct _object *,struct boost::python::objects::reference_to_value<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &>,struct boost::python::objects::reference_to_value<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &>)" (??$?0U?$reference_to_value@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@objects@python@boost@@U0123@@?$value_holder@VOpenGL3Shader@CEGUI@@@objects@python@boost@@QAE@PAU_object@@U?$reference_to_value@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@123@1@Z)
1>d:\Desktop\working\cegui\build\bin\PyCEGUIOpenGLRenderer_d.pyd : fatal error LNK1120: 9 unresolved externals


I have tried to backtrack through the code to see if there is anything obvious but it's like walking into a briar patch :? so I thought I would turn to you guys who I hope can give me a few pointers on where to look.

Development environment:
Windows Vista (x86)
VS 2010
WINDOWS SDK
Directx SDK
Python 2.7
Boost 1.51

Summarised steps followed so far:
- Installed Boost
- ran cmake on dependancies package
- Built dependancies package
- Build successful
- Copied dependancies package over to main package
- Ran cmake against CEGUI package
- Attempted build of CEGUI.sln
- Build failed trying to link PYCEGUIOpenGLRenderer

Any help solving this would be appreciated.

Many thanks in advance

Bick

User avatar
Kulik
CEGUI Team
Posts: 1382
Joined: Mon Jul 26, 2010 18:47
Location: Czech Republic
Contact:

Re: Pointers to resolve compiler errors

Postby Kulik » Mon Jul 01, 2013 12:03

Make sure you enable both OpenGLRenderer and OpenGL3Renderer. That is the official temporary workaround.

I am aware of this issue but had no time to fix things yet.

Bickleigh
Just popping in
Just popping in
Posts: 2
Joined: Sun Jun 30, 2013 17:41

Re: Pointers to resolve compiler errors

Postby Bickleigh » Mon Jul 01, 2013 14:46

Thanks for the quick reply.

On my system when cmake finds the opengl lib it enables both the options you mention by default. I have tried all combinations and I get the same type of errors except when it is openglrenderer only I get link errors relating to that package.

If you can give me some pointers as to were to look i.e do you think it may be in the python modules, cegui, boost, cmake? I will have a poke around tonight and see if I can break something... :lol:

Thanks
Bick

CABAListic
Just popping in
Just popping in
Posts: 5
Joined: Thu Sep 10, 2009 10:45

Re: Pointers to resolve compiler errors

Postby CABAListic » Sat Aug 03, 2013 23:28

Hi,
I just stumbled upon the same error. The problem is that the OpenGL3Shader class is not publically exported in the OpenGLRenderer, and therefore the Python module cannot find its implementations during linking. I filed a bug report with solution here: http://www.cegui.org.uk/mantis/view.php?id=993


Return to “Help”

Who is online

Users browsing this forum: No registered users and 22 guests