0.7dev Compilation error
« on: 06 October 2014, 16:30:32 »
1>------ Build started: Project: ZERO_CHECK, Configuration: Debug Win32 ------
2>------ Build started: Project: tgui, Configuration: Debug Win32 ------
2>  Button.cpp
2>  Canvas.cpp
2>  ChatBox.cpp
2>ChatBox.cpp(586): warning C4244: 'return' : conversion from 'double' to 'float', possible loss of data
2>  Checkbox.cpp
2>  ComboBox.cpp
2>  Container.cpp
2>C:\Users\User\Documents\RKN\ext\tgui\TGUI-0.7-dev\include\TGUI/TextBox.hpp(412): error C2664: 'std::vector<sf::String,std::allocator<_Ty>>::vector(std::initializer_list<sf::String>,const std::allocator<_Ty> &)' : cannot convert argument 1 from 'const char [1]' to 'const std::allocator<_Ty> &'
2>          with
2>          [
2>              _Ty=sf::String
2>          ]
2>          Reason: cannot convert from 'const char [1]' to 'const std::allocator<_Ty>'
2>          with
2>          [
2>              _Ty=sf::String
2>          ]
2>          No constructor could take the source type, or constructor overload resolution was ambiguous
2>C:\Users\User\Documents\RKN\ext\tgui\TGUI-0.7-dev\include\TGUI/Gui.hpp(469): error C2783: 'std::shared_ptr<_Ty> std::make_shared(_Types &&...)' : could not deduce template argument for '_Ty'
2>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\memory(1000) : see declaration of 'std::make_shared'
2>  EditBox.cpp
2>  Gui.cpp
2>C:\Users\User\Documents\RKN\ext\tgui\TGUI-0.7-dev\include\TGUI/Gui.hpp(469): error C2783: 'std::shared_ptr<_Ty> std::make_shared(_Types &&...)' : could not deduce template argument for '_Ty'
2>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\memory(1000) : see declaration of 'std::make_shared'
2>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\memory(1000) : see declaration of 'std::make_shared'
2>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\memory(1000) : see declaration of 'std::make_shared'
2>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\memory(1000) : see declaration of 'std::make_shared'
2>  Knob.cpp
2>  Layout.cpp
2>C:\Users\User\Documents\RKN\ext\tgui\TGUI-0.7-dev\include\TGUI/Gui.hpp(469): error C2783: 'std::shared_ptr<_Ty> std::make_shared(_Types &&...)' : could not deduce template argument for '_Ty'
2>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\memory(1000) : see declaration of 'std::make_shared'
2>  Picture.cpp
2>  ProgressBar.cpp
2>  RadioButton.cpp
2>  Scrollbar.cpp
2>Scrollbar.cpp(673): warning C4244: 'argument' : conversion from 'int' to 'float', possible loss of data
2>Scrollbar.cpp(675): warning C4244: 'argument' : conversion from 'int' to 'float', possible loss of data
2>Scrollbar.cpp(677): warning C4244: 'argument' : conversion from 'int' to 'float', possible loss of data
2>Scrollbar.cpp(679): warning C4244: 'argument' : conversion from 'int' to 'float', possible loss of data
2>  Signal.cpp
2>  Slider.cpp
2>Slider.cpp(204): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
2>Slider.cpp(209): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
2>  TextBox.cpp
2>C:\Users\User\Documents\RKN\ext\tgui\TGUI-0.7-dev\include\TGUI/TextBox.hpp(412): error C2664: 'std::vector<sf::String,std::allocator<_Ty>>::vector(std::initializer_list<sf::String>,const std::allocator<_Ty> &)' : cannot convert argument 1 from 'const char [1]' to 'const std::allocator<_Ty> &'
2>          with
2>          [
2>              _Ty=sf::String
2>          ]
2>          Reason: cannot convert from 'const char [1]' to 'const std::allocator<_Ty>'
2>          with
2>          [
2>              _Ty=sf::String
2>          ]
2>          No constructor could take the source type, or constructor overload resolution was ambiguous
2>C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\algorithm(4141): warning C4244: 'argument' : conversion from 'float' to 'const unsigned int', possible loss of data
2>TextBox.cpp(342): warning C4244: 'argument' : conversion from 'float' to 'const unsigned int', possible loss of data
2>TextBox.cpp(420): warning C4244: '=' : conversion from 'float' to 'unsigned int', possible loss of data
2>  TextureManager.cpp
2>  ThemeFileParser.cpp
2>  Tooltip.cpp
2>  Generating Code...
2>c:\users\user\documents\rkn\ext\tgui\tgui-0.7-dev\src\tgui\combobox.cpp(209): fatal error C1001: An internal error has occurred in the compiler.
2>  (compiler file 'f:\dd\vctools\compiler\utc\src\p2\ehexcept.c', line 956)
2>   To work around this problem, try simplifying or changing the program near the locations listed above.
2>  Please choose the Technical Support command on the Visual C++
2>   Help menu, or open the Technical Support help file for more information
3>------ Build started: Project: ALL_BUILD, Configuration: Debug Win32 ------
3>  Build all projects
4>------ Skipped Build: Project: INSTALL, Configuration: Debug Win32 ------
4>Project not selected to build for this solution configuration
========== Build: 2 succeeded, 1 failed, 0 up-to-date, 1 skipped ==========


Unfortunately I am not a template guy, can you figure out what's wrong?

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #1 on: 06 October 2014, 16:59:37 »
Apparently my code doesn't compile in visual studio. I can't test nor fix it from my linux, so I will boot my windows later to look at this (and then I can immediately fix those conversion warnings as well).

For now you can change line 412 in TextBox.hpp from
Code: [Select]
std::vector<sf::String> m_lines = {""};to
Code: [Select]
std::vector<sf::String> m_lines;
Obviously that may break the TextBox, but at least then you can continue with the rest of tgui.
Or you can wait a few hours until I have fixed this issue and then get the latest version again (I'll post here when it's done).

Re: 0.7dev Compilation error
« Reply #2 on: 06 October 2014, 17:03:48 »
Sounds great, thank you.

Re: 0.7dev Compilation error
« Reply #3 on: 06 October 2014, 17:19:38 »
I saw ther was an update for VS last month. After installation the error vanishes. However:

2>Layout.cpp(145): error C2797: 'tgui::Layout1d::m_bindings': list initialization inside member initializer list or non-static data member initializer is not implemented


I guess you are to cutting edge for MSVC2013 Update 3

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #4 on: 06 October 2014, 17:23:40 »
Ok, I guess I will have to fix more than one line then.

I do want to keep VS2013 supported, if possible even without any updates, so this definitely has to be fixed asap.

Its just stupid that both gcc and clang already have excellent c++14 support while visual studio doesn't even support c++11 fully.

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #5 on: 06 October 2014, 19:17:35 »
I'm seriously pissed right now. Not only did my VS2013 compiler simply errored during compilation of a simple list initializer (which they claim to support), but even with update 3 I am going to have to remove functionality from tgui in order to support VS2013.

I'll try to get something working in the next few hours, but right now I'm not really happy with the only solution that I find.

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #6 on: 06 October 2014, 20:17:51 »
Pfff, I solved the problems. The latest version should compile fine.

But I'm walking on very thin ice with the VS support. I'm actually relying on that the compiler in VS being broken in such a way that my code still works.

Re: 0.7dev Compilation error
« Reply #7 on: 06 October 2014, 22:34:05 »
Quickly tested it, library compiles fine. Compiling fullexample.cpp with the library throws unresolved externals at me however. I did link against tgui-d.lib correctly. On a sidenote, tgui-d.lib is much smaller (110kb) than the previous version (372kb), this stems from your code revisions, right? Maybe the error is on my side, it is late.

1>------ Build started: Project: tguitest, Configuration: Debug Win32 ------
1>  FullExample.cpp
1>FullExample.cpp(24): warning C4244: 'argument' : conversion from 'unsigned int' to 'float', possible loss of data
1>FullExample.cpp(200): warning C4244: 'argument' : conversion from 'unsigned int' to 'float', possible loss of data
1>FullExample.obj : error LNK2019: unresolved external symbol "class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __cdecl tgui::toLower(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?toLower@tgui@@YA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V23@@Z) referenced in function "protected: void __thiscall tgui::SignalWidgetBase::connectInternal<class <lambda_ac1a379fafdc65c61d25b71a944ca7ca> >(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class <lambda_ac1a379fafdc65c61d25b71a944ca7ca>)" (??$connectInternal@V<lambda_ac1a379fafdc65c61d25b71a944ca7ca>@@$$$V@SignalWidgetBase@tgui@@IAEXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V<lambda_ac1a379fafdc65c61d25b71a944ca7ca>@@@Z)
1>FullExample.obj : error LNK2019: unresolved external symbol "protected: class std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > __thiscall tgui::SignalWidgetBase::extractSignalNames(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" (?extractSignalNames@SignalWidgetBase@tgui@@IAE?AV?$vector@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V?$allocator@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@2@@std@@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@@Z) referenced in function "public: unsigned int __thiscall tgui::SignalWidgetBase::connect<class <lambda_ac1a379fafdc65c61d25b71a944ca7ca> >(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class <lambda_ac1a379fafdc65c61d25b71a944ca7ca>)" (??$connect@V<lambda_ac1a379fafdc65c61d25b71a944ca7ca>@@$$$V@SignalWidgetBase@tgui@@QAEIABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V<lambda_ac1a379fafdc65c61d25b71a944ca7ca>@@@Z)
1>FullExample.obj : error LNK2019: unresolved external symbol "public: __thiscall tgui::Layout1d::Layout1d(class tgui::Layout1d const &)" (??0Layout1d@tgui@@QAE@ABV01@@Z) referenced in function "public: __thiscall tgui::Layout::Layout(class tgui::Layout1d const &,class tgui::Layout1d const &)" (??0Layout@tgui@@QAE@ABVLayout1d@1@0@Z)
1>FullExample.obj : error LNK2019: unresolved external symbol "public: __thiscall tgui::Layout::~Layout(void)" (??1Layout@tgui@@QAE@XZ) referenced in function "public: void __thiscall tgui::Transformable::setPosition(class tgui::Layout1d const &,class tgui::Layout1d const &)" (?setPosition@Transformable@tgui@@QAEXABVLayout1d@2@0@Z)
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Label> __cdecl tgui::Label::create(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 &)" (?create@Label@tgui@@SA?AV?$shared_ptr@VLabel@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Label::setText(class sf::String const &)" (?setText@Label@tgui@@QAEXABVString@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Label::setTextSize(unsigned int)" (?setTextSize@Label@tgui@@QAEXI@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Picture> __cdecl tgui::Picture::create(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,bool)" (?create@Picture@tgui@@SA?AV?$shared_ptr@VPicture@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@_N@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Button> __cdecl tgui::Button::create(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 &)" (?create@Button@tgui@@SA?AV?$shared_ptr@VButton@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Button::setText(class sf::String const &)" (?setText@Button@tgui@@QAEXABVString@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::RadioButton> __cdecl tgui::RadioButton::create(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 &)" (?create@RadioButton@tgui@@SA?AV?$shared_ptr@VRadioButton@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::RadioButton::setText(class sf::String const &)" (?setText@RadioButton@tgui@@QAEXABVString@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Checkbox> __cdecl tgui::Checkbox::create(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 &)" (?create@Checkbox@tgui@@SA?AV?$shared_ptr@VCheckbox@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::EditBox> __cdecl tgui::EditBox::create(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 &)" (?create@EditBox@tgui@@SA?AV?$shared_ptr@VEditBox@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::EditBox::setTextSize(unsigned int)" (?setTextSize@EditBox@tgui@@QAEXI@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Slider> __cdecl tgui::Slider::create(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 &)" (?create@Slider@tgui@@SA?AV?$shared_ptr@VSlider@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Scrollbar> __cdecl tgui::Scrollbar::create(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 &)" (?create@Scrollbar@tgui@@SA?AV?$shared_ptr@VScrollbar@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Scrollbar::setMaximum(unsigned int)" (?setMaximum@Scrollbar@tgui@@QAEXI@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Scrollbar::setLowValue(unsigned int)" (?setLowValue@Scrollbar@tgui@@QAEXI@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::ProgressBar> __cdecl tgui::ProgressBar::create(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 &)" (?create@ProgressBar@tgui@@SA?AV?$shared_ptr@VProgressBar@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::ProgressBar::setValue(unsigned int)" (?setValue@ProgressBar@tgui@@QAEXI@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Tab> __cdecl tgui::Tab::create(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 &)" (?create@Tab@tgui@@SA?AV?$shared_ptr@VTab@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: unsigned int __thiscall tgui::Tab::add(class sf::String const &,bool)" (?add@Tab@tgui@@QAEIABVString@sf@@_N@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Tab::setTabHeight(float)" (?setTabHeight@Tab@tgui@@QAEXM@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::MenuBar> __cdecl tgui::MenuBar::create(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 &)" (?create@MenuBar@tgui@@SA?AV?$shared_ptr@VMenuBar@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::MenuBar::addMenu(class sf::String const &)" (?addMenu@MenuBar@tgui@@QAEXABVString@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: bool __thiscall tgui::MenuBar::addMenuItem(class sf::String const &,class sf::String const &)" (?addMenuItem@MenuBar@tgui@@QAE_NABVString@sf@@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::ChatBox> __cdecl tgui::ChatBox::create(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 &)" (?create@ChatBox@tgui@@SA?AV?$shared_ptr@VChatBox@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::ChatBox::addLine(class sf::String const &,class sf::Color const &)" (?addLine@ChatBox@tgui@@QAEXABVString@sf@@ABVColor@4@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::ChatBox::setTextSize(unsigned int)" (?setTextSize@ChatBox@tgui@@QAEXI@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::Canvas> __cdecl tgui::Canvas::create(class sf::Vector2<float> const &)" (?create@Canvas@tgui@@SA?AV?$shared_ptr@VCanvas@tgui@@@std@@ABV?$Vector2@M@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Canvas::clear(class sf::Color const &)" (?clear@Canvas@tgui@@QAEXABVColor@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Canvas::draw(class sf::Drawable const &,class sf::RenderStates const &)" (?draw@Canvas@tgui@@QAEXABVDrawable@sf@@ABVRenderStates@4@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Canvas::display(void)" (?display@Canvas@tgui@@QAEXXZ) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: static class std::shared_ptr<class tgui::ChildWindow> __cdecl tgui::ChildWindow::create(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 &)" (?create@ChildWindow@tgui@@SA?AV?$shared_ptr@VChildWindow@tgui@@@std@@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@4@0@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::ChildWindow::setTitle(class sf::String const &)" (?setTitle@ChildWindow@tgui@@QAEXABVString@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: __thiscall tgui::Gui::Gui(class sf::RenderWindow &)" (??0Gui@tgui@@QAE@AAVRenderWindow@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: bool __thiscall tgui::Gui::handleEvent(class sf::Event)" (?handleEvent@Gui@tgui@@QAE_NVEvent@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Gui::draw(void)" (?draw@Gui@tgui@@QAEXXZ) referenced in function _main
1>FullExample.obj : error LNK2019: unresolved external symbol "public: void __thiscall tgui::Gui::add(class std::shared_ptr<class tgui::Widget> const &,class sf::String const &)" (?add@Gui@tgui@@QAEXABV?$shared_ptr@VWidget@tgui@@@std@@ABVString@sf@@@Z) referenced in function _main
1>FullExample.obj : error LNK2001: unresolved external symbol "protected: static unsigned int tgui::SignalWidgetBase::m_lastId" (?m_lastId@SignalWidgetBase@tgui@@1IA)
1>C:\Users\User\Documents\RKN\ext\tgui\TGUI-0.7-dev\examples\full_example\Debug\tguitest.exe : fatal error LNK1120: 41 unresolved externals
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #8 on: 06 October 2014, 22:47:38 »
While fixing the compilation on VS2013 I made a few changes with the placing of TGUI_API (which is a windows specific define that every library has to implement in order to use dlls) so I hope I didn't do anything wrong.

I'll test the example code myself soon. I don't like these windows specific issues because I can't really test them quickly. If it were reproducible on a linux it would be solved in a matter of minutes.

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #9 on: 06 October 2014, 23:23:12 »
I don't have any problems with building the example code.
But my tgui-d.lib is 412kb so something seems wrong with your file.

I suggest you clear the cmake cache and try to rebuild the library, maybe that solves it.

Re: 0.7dev Compilation error
« Reply #10 on: 06 October 2014, 23:44:51 »
Just did that. (deleted the whole folder, downloaded anew, reran cmake, compiled tgui). Still, it is 110KB. What could I be doing wrong? I also tried the release configuration. Same result.

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #11 on: 06 October 2014, 23:48:29 »
Could you send me the whole tgui folder that you currently have, with the build libraries included. And also the sfml folder (including headers and libraries) which you use to build tgui. You could also include the project that you have to build the example code. (e.g. on dropbox)

I'm not sure if I'm going to find anything since I wouldn't even know where to start, but I can at least try to look for some difference.

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #12 on: 06 October 2014, 23:53:51 »
Ouch, the problem is probably on my end. I seem to have swapped some files and I apparently ended up testing v0.6 instead of v0.7-dev.

I was about to send you the version which I compiled earlier when I found out that it was 0.6.

So I will have to change my include directories and stuff again and run another test. I will most likely encounter the same problem as you then.

Re: 0.7dev Compilation error
« Reply #13 on: 07 October 2014, 00:02:10 »
Well, at least I have a dropbox-account now..  ;) In fact I had it earlier but it went unused for a very long time and now I have the credentials again.

*

texus

  • *****
  • 1143
    • View Profile
    • Texus's Blog
Re: 0.7dev Compilation error
« Reply #14 on: 07 October 2014, 00:16:02 »
I don't believe what I'm seeing here.
Its on the very top of my todo list: find out where the hell SFML/Config.hpp is included.

Due to some reordering of includes, this file was simply included too late, making OS detection impossible. Therefore the windows specific code for dlls was not defined.

All should be fixed now.
« Last Edit: 07 October 2014, 00:17:41 by texus »