I've been recently trying to transfer my Visual Studio OpenGL project to VS Code, using GCC via mingw-x64 on Windows 10. I've been making steady progress working this all out as I am fairly new to c++ programming, and I've been running into an error that I can't solve.
When building with the following command:
C:\Lib\mingw-w64\mingw64\bin\g++.exe -LC:/Lib/lib -IC:/Lib/include -g main.cpp -lglew32 -lglfw3 -lSOIL -lopengl32 -o build.exe
I've been getting this error:
C:/Lib/lib/SOIL.lib: error adding symbols: File format not recognizedcollect2.exe: error: ld returned 1 exit status
The SOIL.lib I am using worked fine for Visual Studio, and GCC seems to have no complaints with the other .lib files I am using.
There doesn't seem to be much information about what's happening, I've found a bunch of different people having the same error for different things, and I haven't been able to work out what is actually going wrong for this cryptic error message. Can anyone help out?