SFML community forums

Help => General => Topic started by: pdinklag on March 11, 2011, 07:23:59 pm

Title: Freeze trying to load sfml-window-2.dll
Post by: pdinklag on March 11, 2011, 07:23:59 pm
Hey again!

I have built SFML2 with MSVC++ 2010 on Windows 7 (32bit) with the "Release" configuration. It compiles and links fine, however, "sfml-window-2.dll" cannot be loaded.

There is no error or anything, any application trying to load "sfml-window-2.dll" will straight up freeze. I noticed that when my Java application froze and first thought it might be Java having issues, but now I could reproduce this problem using the following simple program:
Code: [Select]
#include <stdio.h>
#include <Windows.h>

int main(int argc, char** argv) {
printf("Before loadLibrary\n");
HMODULE module = LoadLibrary(L"sfml-window-2.dll");
printf("After loadLibrary (module = %d)\n", module);

return 0;
}

You will get the output "Before loadLibrary", and then it freezes for good. This means that any SFML application using the Graphics or Window module will freeze on startup.

On another machine with Windows XP (32bit as well), where I compiled SFML2 using MSVC++ 2008, everything works fine. So this is either an issue with Windows 7 or the MSVC++ 2010 runtime. Running the application with Administrator priviliges did not help here.

Any idea what might be going on here?
Title: Freeze trying to load sfml-window-2.dll
Post by: Laurent on March 11, 2011, 07:26:30 pm
There's a problem with ATI graphics cards (half of the forum is about this problem ;)), but this will be solved soon with the fix that I told you last time.
Title: Freeze trying to load sfml-window-2.dll
Post by: pdinklag on March 11, 2011, 07:42:16 pm
I'm indeed using ATI here, but why would this freeze occur when the DLL gets loaded? Any magic in DllMain?  :?

Anyway, thanks for the info. Sounds you seriously got some work to do on this. :)
Title: Freeze trying to load sfml-window-2.dll
Post by: Laurent on March 11, 2011, 07:45:04 pm
Quote
I'm indeed using ATI here, but why would this freeze occur when the DLL gets loaded? Any magic in DllMain?

Some magic in global scope ;)