ui
ui copied to clipboard
About library reference in Linux
Hi,
I try to run the project in Linux
After executing the following commands ./b2 libs/ui/build/ cxxflags=-std=c++0x ./b2 libs/ui/test/ cxxflags=-std=c++0x ./b2 libs/ui/example/ cxxflags=-std=c++0x ./b2 libs/ui/example/cpp11/ cxxflags=-std=c++0x
I can successfully run the built UI example above
However, if I want to run my project in another folder(Either in VS code or other IDE), I even get failed at the code line #include <boost/ui.hpp> (With the undefined reference errors)
What should I do next?
Are the library built from above ./b2 libs/ui/build/ cxxflags=-std=c++0x along with the headers inside ui/include sufficient to build my own project with #include<boost/ui.hpp> as reference?
For example, after building the official boost library with the syntax ./b2 install, list of related compiled library such as libboost_xxx.a, libboost_xxx.so and liboost_xxx.1.84.so.0 can be obtained in /usr/local/lib. Along with the header files, I can successfully use these libraries with my projects by taking the correct reference path. Did I miss something for boost UI as the example here https://kosenko.github.io/boost.ui/?
Any advice is appreciated.
Boost.UI is not header-only library. So you need to link Boost.UI and wxWidgets libraries. Try to find a function that causes undefined reference error.
Boost.UI is not header-only library. So you need to link Boost.UI and wxWidgets libraries. Try to find a function that causes undefined reference error.
Thanks for your reply!
So maybe it does not mean that Boost.UI and wxWidgets libraries are linked successfully as the syntax "./b2 libs/ui/build/ cxxflags=-std=c++0x" executed successfully?( So far, I can get libboost_ui.a & libboost_ui.so.1.84.0 under the bin.v2 folder by ./b2 related syntax, but I cannot get libboost_ui.so)
Do you mean I have to build the library from source other than using "./b2 related syntax"?
Your project application should also link Boost.UI and wxWidgets libraries, not just examples.