Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - symt0p

Pages: [1]
1
General / Unexpected Errors with SFML in VSCode
« on: May 05, 2023, 06:25:14 pm »
Hello, I'm having errors with building with SFML. For context, I downloaded the most recent 64-bit Visual C++ 15 (2017) version of SFML, and I'm currently using VSCode, with the MinGW compiler. This error occurs whenever I write any line regarding SFML, in this case it's just :

VideoMode vm(1920, 1000);

I'm compiling on the  terminal with this command:

g++ src/main.cpp -o main -I"SFML/include" -L"SFML/lib" -lopenal32 -lsfml-graphics -lsfml-audio -lsfml-window -lsfml-system -o main

and I'm getting this error back:

c:/mingw/bin/../lib/gcc/x86_64-w64-mingw32/11.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:\Users\shiya\AppData\Local\Temp\cc4H6TOZ.o:main.cpp:(.text+0x28): undefined reference to `__imp__ZN2sf9VideoModeC1Ejjj'

The compiler seems to recognize all the files I've linked, so I'm unsure as to where this undefined reference is coming from. I've also copied all the dll files from SFML/bin into my project folder. Thanks in advance.

Pages: [1]
anything