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 - awdjr8

Pages: [1]
1
Hey, thanks for the help.

I ended up replacing the mingw64 installation from Msys2 with the contents of the download from the SFML download page. I am now able to link both dynamically and statically, resulting in a working program.

I do wonder what is different about the compilers though. The devil seems to be in the details, and it is strange to me that the same version of something can actually be different.

For other people's reference, since I don't think this is actually posted anywhere, the build command with all the dependencies linked ends up looking something like:

g++ -g C:\correctprojectdirectoryhere/src/*.cpp -DSFML_STATIC -o C:\correctprojectdirectoryhere/sfmltest -I C:\correctprojectdirectoryhere/headers -lsfml-audio-s -lsfml-graphics-s -lsfml-network-s -lsfml-window-s -lsfml-system-s -lopengl32 -lwinmm -lgdi32 -lflac -lvorbisenc -lvorbisfile -lvorbis -logg -lws2_32 -lfreetype

looks like the slashes are all over the place, but that is what my vscode is telling me in the terminal.

for reference, my tasks.json args look like:

"args": [
                "-g",
                "${workspaceFolder}/src/*.cpp",
                "-DSFML_STATIC",
                //"-static",      // Ensure static linking
                "-o",
                "${workspaceFolder}/sfmltest",
                "-I", "${workspaceFolder}/headers",
                //"-I", "C:/Libraries/SFML/include",  // Add this line to include the SFML headers
                //"-L", "C:/Libraries/SFML/lib",
                "-lsfml-audio-s",
                "-lsfml-graphics-s",
                "-lsfml-network-s",
                "-lsfml-window-s",   // Make sure to link these
                "-lsfml-system-s",    // Make sure to link these as well
                "-lopengl32",
                "-lwinmm",
                "-lgdi32",
                "-lflac",
                "-lvorbisenc",
                "-lvorbisfile",
                "-lvorbis",
                "-logg",
                "-lws2_32",
                "-lfreetype"
            ],

2
Hello,

I have spent way too much time trying to get the default boiler plate code working to check the overall setup with SFML.

this is the code:

#include <SFML/Graphics.hpp>


#include <optional> // Required for std::optional

using namespace sf;
using namespace std;

int main()
{
    RenderWindow window(VideoMode(Vector2u(200, 200)), "SFML works!");
    CircleShape shape(100.f);
    shape.setFillColor(Color::Green);

    while (window.isOpen())
    {
        optional<Event> event;
        while ((event = window.pollEvent()))
        {
            if (event->is<Event::Closed>()) // Check if the event is a window close event
                window.close();
        }

        window.clear();
        window.draw(shape);
        window.display();
    }

    return 0;
}



-I am on windows 10
-I used Msys2 to get minGW64 and the version is 14.2.0.
-I am sure that I downloaded the minGW version of SFML from the downloads page.
-I am sure its all the 64 bit versions of everything. (I ran the version check commands to confirm that g++ was the 64 bit version.


I am now at a fork in the road where both paths are blocked:

1. when linking dynamically using the tasks.json file:

{
    "version": "2.0.0",
    "tasks": [
        {
            "label": "Build with MinGW",
            "type": "shell",
            "command": "g++",
            "args": [
                "-g",
                "${workspaceFolder}/src/main.cpp",
                //"-DSFML_STATIC",
                //"-static",      // Ensure static linking
                "-o",
                "${workspaceFolder}/sfmltest",
                "-I", "C:/Libraries/SFML/include",  // Add this line to include the SFML headers
                "-L", "C:/Libraries/SFML/lib",
                "-lsfml-audio",
                "-lsfml-graphics",
                "-lsfml-network",
                "-lsfml-window",   // Make sure to link these
                "-lsfml-system"    // Make sure to link these as well
            ],
            "group": {
                "kind": "build",
                "isDefault": true
            },
            "problemMatcher": ["$gcc"],
            "detail": "Generated task for compiling C++"
        }
    ]
}


The build succeeds.

when running the .exe however, I get the following error:

The procedure entry point _ZNKSt25__codecvt_utf16_baselwE10do_unshiftER9_MbstatetPcS3_RS3_ could not be located in the dynamic link library C:\correctprojectdirectoryhere\sfml-system-3.dll.

The dll files are indeed beside the .exe in the project directory.



2. The other option is to try statis linking. This is the tasks.json file:

{
    "version": "2.0.0",
    "tasks": [
        {
            "label": "Build with MinGW",
            "type": "shell",
            "command": "g++",
            "args": [
                "-g",
                "${workspaceFolder}/src/main.cpp",
                "-DSFML_STATIC",
                "-static",      // Ensure static linking
                "-o",
                "${workspaceFolder}/sfmltest",
                "-I", "C:/Libraries/SFML/include",  // Add this line to include the SFML headers
                "-L", "C:/Libraries/SFML/lib",
                "-lsfml-audio-s",
                "-lsfml-graphics-s",
                "-lsfml-network-s",
                "-lsfml-window-s",   // Make sure to link these
                "-lsfml-system-s"    // Make sure to link these as well
            ],
            "group": {
                "kind": "build",
                "isDefault": true
            },
            "problemMatcher": ["$gcc"],
            "detail": "Generated task for compiling C++"
        }
    ]
}


but now building cannot succeed, with very many undefined reference errors as per the following:


Executing task: g++ -g C:\correctprojectdirectoryhere/src/main.cpp -DSFML_STATIC -static -o C:\correctprojectdirectoryhere/sfmltest -I C:/Libraries/SFML/include -L C:/Libraries/SFML/lib -lsfml-audio-s -lsfml-graphics-s -lsfml-network-s -lsfml-window-s -lsfml-system-s

C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.text+0x3953e): undefined reference to `std::codecvt<wchar_t, char, _Mbstatet>::codecvt(unsigned long long)&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.text+0x39644): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_out(_Mbstatet&, wchar_t const*, wchar_t const*, wchar_t const*&, char*, char*, char*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.text$_ZNSt10filesystem7__cxx114path10_S_convertIcEEDaPKT_S5_[_ZNSt10filesystem7__cxx114path10_S_convertIcEEDaPKT_S5_]+0x3c): undefined reference to `std::codecvt<wchar_t, char, _Mbstatet>::codecvt(unsigned long long)&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.text$_ZNSt10filesystem7__cxx114path10_S_convertIcEEDaPKT_S5_[_ZNSt10filesystem7__cxx114path10_S_convertIcEEDaPKT_S5_]+0xe4): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_in(_Mbstatet&, char const*, char const*, char const*&, wchar_t*, wchar_t*, wchar_t*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE[_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE]+0x20): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_out(_Mbstatet&, wchar_t const*, wchar_t const*, wchar_t const*&, char*, char*, char*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE[_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE]+0x28): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_unshift(_Mbstatet&, char*, char*, char*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE[_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE]+0x30): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_in(_Mbstatet&, char const*, char const*, char const*&, wchar_t*, wchar_t*, wchar_t*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE[_ZTVSt18codecvt_utf8_utf16IwLm1114111ELSt12codecvt_mode0EE]+0x48): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_length(_Mbstatet&, char const*, char const*, unsigned long long) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE[_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE]+0x20): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_out(_Mbstatet&, wchar_t const*, wchar_t const*, wchar_t const*&, char*, char*, char*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE[_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE]+0x28): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_unshift(_Mbstatet&, char*, char*, char*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE[_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE]+0x30): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_in(_Mbstatet&, char const*, char const*, char const*&, wchar_t*, wchar_t*, wchar_t*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-graphics-s.a(Image.cpp.obj):Image.cpp:(.rdata$_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE[_ZTVNSt10filesystem7__cxx114path8_CodecvtIwEE]+0x48): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_length(_Mbstatet&, char const*, char const*, unsigned long long) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WindowImplWin32.cpp.obj):WindowImplWin32.cpp:(.text+0x1257): undefined reference to `__imp_GetDeviceCaps&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x196): undefined reference to `__imp_SwapBuffers&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x20b): undefined reference to `__imp_wglDeleteContext&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x280): undefined reference to `__imp_wglMakeCurrent&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x6f5): undefined reference to `__imp_wglGetProcAddress&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x7ab): undefined reference to `__imp_wglDeleteContext&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x828): undefined reference to `__imp_wglMakeCurrent&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0xb5f): undefined reference to `__imp_wglMakeCurrent&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0xb95): undefined reference to `__imp_wglMakeCurrent&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0xde6): undefined reference to `__imp_GetPixelFormat&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0xe15): undefined reference to `__imp_DescribePixelFormat&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x1bf3): undefined reference to `__imp_ChoosePixelFormat&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x2d17): undefined reference to `__imp_DescribePixelFormat&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x2d26): undefined reference to `__imp_SetPixelFormat&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x3ad8): undefined reference to `__imp_wglCreateContext&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x3b2a): undefined reference to `__imp_wglShareLists&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x3d28): undefined reference to `__imp_wglMakeCurrent&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(WglContext.cpp.obj):WglContext.cpp:(.text+0x3f7f): undefined reference to `__imp_wglMakeCurrent&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(CursorImpl.cpp.obj):CursorImpl.cpp:(.text+0x112): undefined reference to `__imp_CreateDIBSection&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(CursorImpl.cpp.obj):CursorImpl.cpp:(.text+0x174): undefined reference to `__imp_CreateBitmap&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(CursorImpl.cpp.obj):CursorImpl.cpp:(.text+0x1b0): undefined reference to `__imp_DeleteObject&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(CursorImpl.cpp.obj):CursorImpl.cpp:(.text+0x285): undefined reference to `__imp_DeleteObject&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(JoystickImpl.cpp.obj):JoystickImpl.c:(.text+0xc9a): undefined reference to `__imp_joyGetPosEx&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(JoystickImpl.cpp.obj):JoystickImpl.c:(.text+0xfde): undefined reference to `__imp_joyGetPosEx&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(JoystickImpl.cpp.obj):JoystickImpl.c:(.text+0x10d3): undefined reference to `__imp_joyGetPosEx&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(JoystickImpl.cpp.obj):JoystickImpl.c:(.text+0x1b11): undefined reference to `__imp_joyGetPosEx&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-window-s.a(JoystickImpl.cpp.obj):JoystickImpl.c:(.text+0x3fc3): undefined reference to `__imp_joyGetDevCapsW&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-system-s.a(Err.cpp.obj):Err.cpp:(.rdata+0x80): undefined reference to `std::basic_streambuf<char, std::char_traits<char> >::seekpos(std::fpos<_Mbstatet>, std::_Ios_Openmode)&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-system-s.a(Utils.cpp.obj):Utils.cpp:(.text$_ZNSt10filesystem7__cxx11lsIcSt11char_traitsIcEEERSt13basic_ostreamIT_T0_ES8_RKNS0_4pathE[_ZNSt10filesystem7__cxx11lsIcSt11char_traitsIcEEERSt13basic_ostreamIT_T0_ES8_RKNS0_4pathE]+0x4d9): undefined reference to `std::codecvt<wchar_t, char, _Mbstatet>::codecvt(unsigned long long)&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-system-s.a(Utils.cpp.obj):Utils.cpp:(.text$_ZNSt10filesystem7__cxx11lsIcSt11char_traitsIcEEERSt13basic_ostreamIT_T0_ES8_RKNS0_4pathE[_ZNSt10filesystem7__cxx11lsIcSt11char_traitsIcEEERSt13basic_ostreamIT_T0_ES8_RKNS0_4pathE]+0x5db): undefined reference to `std::__codecvt_utf8_utf16_base<wchar_t>::do_out(_Mbstatet&, wchar_t const*, wchar_t const*, wchar_t const*&, char*, char*, char*&) const&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-system-s.a(SleepImpl.cpp.obj):SleepImpl.cpp:(.text+0x2f): undefined reference to `__imp_timeBeginPeriod&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-system-s.a(SleepImpl.cpp.obj):SleepImpl.cpp:(.text+0x61): undefined reference to `__imp_timeEndPeriod&#39;
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/14.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/Libraries/SFML/lib\libsfml-system-s.a(SleepImpl.cpp.obj):SleepImpl.cpp:(.text+0x74): undefined reference to `__imp_timeGetDevCaps&#39;
collect2.exe: error: ld returned 1 exit status


Any help in getting SFML working would be appreciated.

Thanks

Pages: [1]