1
General / Re: Unable to link statically compiled SFML with clang
« on: November 08, 2024, 11:51:50 am »
I forgot to mention I also ran the makefile after the CMake GUI
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.
lld-link: error: /failifmismatch: mismatch detected for 'RuntimeLibrary':
>>> C:\Users\\AppData\Local\Temp\test-af06e4.o has value MT_StaticRelease
>>> sfml-graphics-s.lib(CircleShape.cpp.obj) has value MD_DynamicRelease
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
clang++ test.cpp -o test.exe -fuse-ld=lld-link -D SFML_STATIC -I "SFML-2.6.1\include" -L "SFML-2.6.1\build\lib" -l sfml-graphics-s -l sfml-window-s -l sfml-system-s -l opengl32 -l winmm -l gdi32
lld-link: error: /failifmismatch: mismatch detected for 'RuntimeLibrary':
>>> C:\Users\\AppData\Local\Temp\test-db37c8.o has value MT_StaticRelease
>>> sfml-graphics-s.lib(CircleShape.cpp.obj) has value MD_DynamicRelease
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
-static-libstdc++ -static
flags to my compile command, thanks
g++ test.cpp -o test.exe -D SFML_STATIC -I SFML-2.6.1\include -L SFML-2.6.1\build\lib -l sfml-graphics-s -l sfml-window-s -l sfml-system-s -l opengl32 -l winmm -l gdi32