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

Author Topic: SFML Project DLL entrypoint failure  (Read 139 times)

0 Members and 1 Guest are viewing this topic.

VCSMaster

  • Newbie
  • *
  • Posts: 3
    • View Profile
SFML Project DLL entrypoint failure
« on: January 11, 2020, 08:28:04 am »
Hello, I registered here after searching for a while to find the answer to this, but it doesn't seem many people have the same problem. Lucky them!

I'm writing a game in Code::Blocks using the latest version of both Code::Blocks and of SFML at the time of writing. I followed the tutorial and documentation, and when compiled and run from CB the program works flawlessly. Everything operates smoothly and properly as intended.

But... I can't get the EXE files to work. I know SFML must be installed correctly for everything to be working this well. Placing the EXE in a new folder with all DLL files and the few external resources it currently uses, it will not start.
Attempting to launch the file, it gives me a procedure entry point error for system, graphics, and window before closing.

I am on Windows 10, I have an Intel HD4000 video card (this is a laptop), I'm using the dynamic libraries if it wasn't clear, I am not using a snapshot version, and none of the relevant code seems to be an issue. As I said, it works fine in the IDE.

Any help is appreciated. Hope I did a good job with my first post.

Pictured below are some cropped screenshots I took to aide in understanding the problem. The first three are the errors I am getting, the fourth is the directory of the folder, and the fifth shows it running in Code::Blocks.





eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 9405
    • View Profile
    • development blog
    • Email
Re: SFML Project DLL entrypoint failure
« Reply #1 on: January 11, 2020, 05:12:27 pm »
If you build your game with C++11 (or higher) enabled, you may need to rebuild SFML with that compiler flag enabled as well, due to different ABI for strings between pre and post C++11 in GCC.
Official FAQ: https://www.sfml-dev.org/faq.php
Nightly Builds: https://www.nightlybuilds.ch/
——————————————————————
Dev Blog: https://dev.my-gate.net/
Thor: http://www.bromeon.ch/libraries/thor/

VCSMaster

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: SFML Project DLL entrypoint failure
« Reply #2 on: January 11, 2020, 10:59:22 pm »
How do I do this in Code::Blocks?

I can't find anything about rebuilding it.

I also wouldn't be opposed to making changes to make it work in earlier versions of C++. Last time I did anything before this was in Visual Studio 2005, so I doubt I'm using many new features.
« Last Edit: January 11, 2020, 11:08:57 pm by VCSMaster »

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 9405
    • View Profile
    • development blog
    • Email
Re: SFML Project DLL entrypoint failure
« Reply #3 on: January 12, 2020, 09:06:19 am »
You use CMake to generate a makefile or C::B project and build SFML with it (see the CMake SFML tutorial).

Otherwise check your compiler flags.
Official FAQ: https://www.sfml-dev.org/faq.php
Nightly Builds: https://www.nightlybuilds.ch/
——————————————————————
Dev Blog: https://dev.my-gate.net/
Thor: http://www.bromeon.ch/libraries/thor/

VCSMaster

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: SFML Project DLL entrypoint failure
« Reply #4 on: January 13, 2020, 08:38:56 pm »
So I have to make a new project from scratch if I use CMake?

Is there another way which preserves my project?