[gmake: *** [Makefile:91: all] Error 2] - VS Code IDE Extension Issue Report (7d319d42ec867d3db18a4cca9db7e4be)

OS: linux :: x64 :: WSL 2
Distro: Ubuntu 22.04.3 LTS
Extension activation logs:

 Activating Torizon IDE ...
 Telemetry is enabled
 Extension collects completely anonymous telemetry data about templates usage. Participation in this anonymous program is optional, and you may opt-out if you'd not like to share any information. Check: https://github.com/toradex/torizon-experimental-torizon-ide-v2-docs/blob/main/USAGE-DATA.md#opt-out
 Telemetry allows us to accurately gauge templates usage. This data will help us to focus better on the most used templates, adding new features and putting effort in the right place.
 Resolving host IP address ...
 Host IP address OK
 Docker installed OK
 Docker running OK
 Docker compose OK
 PowerShell OK
 git OK
 dig OK
 avahi-resolve OK
 nmap OK
 iputils-ping OK
 file OK
 sshpass OK
 net-tools OK
 Cloning project templates
 Project templates clone OK
 Project templates fetched OK
 Checkout templates repo to v2.3.2 OK
[01-09 11:46:00.02] Checking connected devices ...
[01-09 11:46:00.03] Scanning Torizon devices ...
 Configuring debug id_rsa ...
 Debug id_rsa OK
 Torizon IDE extension activated
 Checking host ip sanity ...
 Host ip is OK
 Device 200.235.64.54 set as Docker Host
 Debian stable packages list load OK
 ERROR :: build-debug-amd64-local failed with exit code 2

Tasks logs:

Container Runtime: docker
Run Arguments: --rm --privileged torizon/binfmt
Container Name: binfmt
Error response from daemon: No such container: binfmt
Container does not exists. Starting ...
 *  Terminal will be reused by tasks, press any key to close it. 

 *  Executing task: cmake -DCMAKE_BUILD_TYPE=Debug -B/home/andre/Braile2/build-local 

-- The CXX compiler identification is GNU 11.4.0
-- The C compiler identification is GNU 11.4.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Configuring done
-- Generating done
-- Build files have been written to: /home/andre/Braile2/build-local
 *  Terminal will be reused by tasks, press any key to close it. 

 *  Executing task: cmake --build /home/andre/Braile2/build-local 

[ 50%] Building CXX object CMakeFiles/Braile2.dir/src/main.cpp.o
[100%] Linking CXX executable debug/Braile2
/usr/bin/ld: CMakeFiles/Braile2.dir/src/main.cpp.o: warning: relocation against `_ZTVN2sf11CircleShapeE' in read-only section `.text._ZN2sf11CircleShapeD2Ev[_ZN2sf11CircleShapeD5Ev]'
/usr/bin/ld: CMakeFiles/Braile2.dir/src/main.cpp.o: in function `main':
/home/andre/Braile2/src/main.cpp:7: undefined reference to `sf::String::String(char const*, std::locale const&)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:7: undefined reference to `sf::VideoMode::VideoMode(unsigned int, unsigned int, unsigned int)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:7: undefined reference to `sf::RenderWindow::RenderWindow(sf::VideoMode, sf::String const&, unsigned int, sf::ContextSettings const&)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:8: undefined reference to `sf::CircleShape::CircleShape(float, unsigned long)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:9: undefined reference to `sf::Color::Green'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:9: undefined reference to `sf::Shape::setFillColor(sf::Color const&)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:17: undefined reference to `sf::Window::close()'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:14: undefined reference to `sf::Window::pollEvent(sf::Event&)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:20: undefined reference to `sf::Color::Color(unsigned char, unsigned char, unsigned char, unsigned char)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:20: undefined reference to `sf::RenderTarget::clear(sf::Color const&)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:21: undefined reference to `sf::RenderStates::Default'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:21: undefined reference to `sf::RenderTarget::draw(sf::Drawable const&, sf::RenderStates const&)'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:22: undefined reference to `sf::Window::display()'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:11: undefined reference to `sf::Window::isOpen() const'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:29: undefined reference to `sf::RenderWindow::~RenderWindow()'
/usr/bin/ld: /home/andre/Braile2/src/main.cpp:29: undefined reference to `sf::RenderWindow::~RenderWindow()'
/usr/bin/ld: CMakeFiles/Braile2.dir/src/main.cpp.o: in function `sf::CircleShape::~CircleShape()':
/usr/include/SFML/Graphics/CircleShape.hpp:41: undefined reference to `vtable for sf::CircleShape'
/usr/bin/ld: /usr/include/SFML/Graphics/CircleShape.hpp:41: undefined reference to `vtable for sf::CircleShape'
/usr/bin/ld: /usr/include/SFML/Graphics/CircleShape.hpp:41: undefined reference to `sf::Shape::~Shape()'
/usr/bin/ld: warning: creating DT_TEXTREL in a PIE
collect2: error: ld returned 1 exit status
gmake[2]: *** [CMakeFiles/Braile2.dir/build.make:97: debug/Braile2] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/Braile2.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2

 *  The terminal process "/usr/bin/bash '-c', 'cmake --build /home/andre/Braile2/build-local'" terminated with exit code: 2. 
 *  Terminal will be reused by tasks, press any key to close it. 

Reported by: @undefined

If you have more data that you think that is interesting from the context of the issue please reply below.

Thanks :robot:

Greetings,

According to your error log it seems to be a linking error when building your project. Make sure your project is linked correctly with all the required libraries and such.