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.


Topics - PrancerFrisco

Pages: [1]
1
I have tried installing the SFML library for C++, however after compiling my program I get this error:

The procedure entry point _ZNSt15basic_streambuflcSt11char_traitslcEE7seekposESt4fposliESt13_los_Openmode could not be located in the dynamic link library C:\SFML-2.6.1\bin\sfml-system-2.dll.

My code:

#include <SFML/Graphics.hpp>

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

    while (window.isOpen())
    {
        sf::Event event;
        while (window.pollEvent(event))
        {
            if (event.type == sf::Event::Closed)
                window.close();
        }

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

    return 0;
}

 


I compiled the code like this: g++ main.cpp -o main -I"C:\SFML-2.6.1\include" -L"C:\SFML-2.6.1\lib" -lsfml-graphics -lsfml-window -lsfml-system



I am using Windows 11 x64, VSCode, SFML for 64 bit.

Thank you.

Pages: [1]