Example 2 in setup not working #209
-
These are the errors showing in the terminal. I don;t't understand what is the problem. :~/FluidX3D-master$ chmod +x make.sh
...............FluidX3D-master$ ./make.sh
/usr/bin/ld: temp/lbm.o: warning: relocation against `key_4' in read-only section `.text'
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/11/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x1b): undefined reference to `main'
/usr/bin/ld: temp/info.o: in function `Info::print_update() const':
info.cpp:(.text+0x413a): undefined reference to `key_G'
/usr/bin/ld: info.cpp:(.text+0x4a18): undefined reference to `camera'
/usr/bin/ld: info.cpp:(.text+0x4a45): undefined reference to `camera'
/usr/bin/ld: info.cpp:(.text+0x4a71): undefined reference to `camera'
/usr/bin/ld: info.cpp:(.text+0x4ba1): undefined reference to `camera'
/usr/bin/ld: info.cpp:(.text+0x4bc1): undefined reference to `camera'
/usr/bin/ld: temp/info.o:info.cpp:(.text+0x4bef): more undefined references to `camera' follow
/usr/bin/ld: temp/info.o: in function `Info::print_update() const':
info.cpp:(.text+0x4ef8): undefined reference to `key_G'
/usr/bin/ld: temp/lbm.o: in function `LBM_Domain::Graphics::update_camera()':
lbm.cpp:(.text+0x8f3): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x90e): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x93b): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x94f): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x987): undefined reference to `camera'
/usr/bin/ld: temp/lbm.o:lbm.cpp:(.text+0x9b0): more undefined references to `camera' follow
/usr/bin/ld: temp/lbm.o: in function `LBM::Graphics::draw_frame()':
lbm.cpp:(.text+0x8286): undefined reference to `key_1'
/usr/bin/ld: lbm.cpp:(.text+0x82a0): undefined reference to `key_1'
/usr/bin/ld: lbm.cpp:(.text+0x82a7): undefined reference to `key_2'
/usr/bin/ld: lbm.cpp:(.text+0x82b4): undefined reference to `key_2'
/usr/bin/ld: lbm.cpp:(.text+0x82bb): undefined reference to `key_3'
/usr/bin/ld: lbm.cpp:(.text+0x82c8): undefined reference to `key_3'
/usr/bin/ld: lbm.cpp:(.text+0x82cf): undefined reference to `key_4'
/usr/bin/ld: lbm.cpp:(.text+0x82dc): undefined reference to `key_4'
/usr/bin/ld: lbm.cpp:(.text+0x82e3): undefined reference to `key_5'
/usr/bin/ld: lbm.cpp:(.text+0x82f0): undefined reference to `key_5'
/usr/bin/ld: lbm.cpp:(.text+0x82f7): undefined reference to `key_6'
/usr/bin/ld: lbm.cpp:(.text+0x8304): undefined reference to `key_6'
/usr/bin/ld: lbm.cpp:(.text+0x830b): undefined reference to `key_7'
/usr/bin/ld: lbm.cpp:(.text+0x831b): undefined reference to `key_7'
/usr/bin/ld: lbm.cpp:(.text+0x8322): undefined reference to `key_T'
/usr/bin/ld: lbm.cpp:(.text+0x833f): undefined reference to `key_T'
/usr/bin/ld: lbm.cpp:(.text+0x8346): undefined reference to `key_Z'
/usr/bin/ld: lbm.cpp:(.text+0x8364): undefined reference to `key_Z'
/usr/bin/ld: lbm.cpp:(.text+0x837c): undefined reference to `key_Q'
/usr/bin/ld: lbm.cpp:(.text+0x83a4): undefined reference to `key_Q'
/usr/bin/ld: lbm.cpp:(.text+0x83ab): undefined reference to `key_E'
/usr/bin/ld: lbm.cpp:(.text+0x83d7): undefined reference to `key_E'
/usr/bin/ld: lbm.cpp:(.text+0x83e0): undefined reference to `key_Q'
/usr/bin/ld: lbm.cpp:(.text+0x8407): undefined reference to `key_Q'
/usr/bin/ld: lbm.cpp:(.text+0x840e): undefined reference to `key_E'
/usr/bin/ld: lbm.cpp:(.text+0x8435): undefined reference to `key_E'
/usr/bin/ld: lbm.cpp:(.text+0x843e): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x845d): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x84b7): undefined reference to `key_Q'
/usr/bin/ld: lbm.cpp:(.text+0x84df): undefined reference to `key_Q'
/usr/bin/ld: lbm.cpp:(.text+0x84e6): undefined reference to `key_E'
/usr/bin/ld: lbm.cpp:(.text+0x8512): undefined reference to `key_E'
/usr/bin/ld: lbm.cpp:(.text+0x85eb): undefined reference to `camera'
/usr/bin/ld: temp/lbm.o: in function `LBM::Graphics::print_frame()':
lbm.cpp:(.text+0x86c4): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x86cc): undefined reference to `camera'
/usr/bin/ld: temp/lbm.o: in function `LBM_Domain::Graphics::allocate(Device&)':
lbm.cpp:(.text+0x986d): undefined reference to `camera'
/usr/bin/ld: lbm.cpp:(.text+0x9874): undefined reference to `camera'
/usr/bin/ld: temp/lbm.o:lbm.cpp:(.text+0x9937): more undefined references to `camera' follow
/usr/bin/ld: temp/main.o: in function `main_graphics()':
main.cpp:(.text+0x29): undefined reference to `draw_bitmap(int*)'
/usr/bin/ld: temp/main.o: in function `draw_scale(int, int)':
main.cpp:(.text+0x654): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x693): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6a3): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x8a6): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x169e): undefined reference to `draw_line_label(int, int, int, int, int)'
/usr/bin/ld: main.cpp:(.text+0x16c1): undefined reference to `draw_line_label(int, int, int, int, int)'
/usr/bin/ld: main.cpp:(.text+0x16dc): undefined reference to `draw_line_label(int, int, int, int, int)'
/usr/bin/ld: main.cpp:(.text+0x16f3): undefined reference to `draw_line_label(int, int, int, int, int)'
/usr/bin/ld: main.cpp:(.text+0x1708): undefined reference to `draw_line_label(int, int, int, int, int)'
/usr/bin/ld: temp/main.o:main.cpp:(.text+0x1ada): more undefined references to `draw_line_label(int, int, int, int, int)' follow
/usr/bin/ld: temp/main.o: in function `draw_scale(int, int)':
main.cpp:(.text+0x1b85): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x1c83): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: temp/main.o: in function `main_label(double)':
main.cpp:(.text+0x1f1e): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x1f2b): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x24c1): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x2834): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x2a61): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x2cdc): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x3087): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: temp/main.o:main.cpp:(.text+0x34c1): more undefined references to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)' follow
/usr/bin/ld: temp/main.o: in function `main_label(double)':
main.cpp:(.text+0x4a83): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x4ea5): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x4fe0): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x4ff5): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x5022): undefined reference to `key_H'
/usr/bin/ld: main.cpp:(.text+0x50f6): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x510b): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x5fb9): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x5fe5): undefined reference to `key_P'
/usr/bin/ld: main.cpp:(.text+0x606d): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x60e5): undefined reference to `key_H'
/usr/bin/ld: main.cpp:(.text+0x616d): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x6230): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x62cd): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x636a): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x640a): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: temp/main.o:main.cpp:(.text+0x64aa): more undefined references to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)' follow
/usr/bin/ld: temp/main.o: in function `main_label(double)':
main.cpp:(.text+0x67f0): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6850): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6932): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x6a1c): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6a2b): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6a7f): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6a85): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6a8b): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6af5): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x6bab): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x6bd9): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6c66): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x6cde): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6d66): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x6dfb): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6e2c): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6e5c): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x6f30): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x70ca): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x70f6): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x717e): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x71f6): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x727e): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x72f6): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x737e): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x7405): undefined reference to `camera'
/usr/bin/ld: main.cpp:(.text+0x745e): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: main.cpp:(.text+0x7514): undefined reference to `draw_label(int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
/usr/bin/ld: warning: creating DT_TEXTREL in a PIE
collect2: error: ld returned 1 exit status
make: *** [makefile:25: bin/FluidX3D] Error 1 |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Hi @dipta005, edit Kind regards, |
Beta Was this translation helpful? Give feedback.
-
Can you copy/paste the output of |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
Hi @dipta005,
edit
src/defines.hpp
, comment out//#define BENCHMARK
and uncomment#define INTERACTIVE_GRAPHICS
.That should resolve the compile errors.
Kind regards,
Moritz