luxeengine/alpha

haxelib run flow run windows results in DLL error

twilson90 opened this issue · 23 comments

2016-03-16 18_16_54-store

Running latest build of flow snow and haxe.
Tried compiling several projects. Works fine building HTML5.

EDIT: It works if I run in debug mode.

Could you add information about what version of Windows, Visual Studio, and whether or not you installed OpenAL (since snow alpha-2.0, this is temporarily required)?

I've got Visual Studio 2010 installed and OpenAL is installed.
I can build OpenFL projects just fine, no problems with hxcpp.

What version of Windows are you running?

Windows 10 pro, Ver 1511

It feels like something strange. Are you using the hxcpp build cache? I'd like to know if a clean non-debug build helps - or try another test/sample but ideally with a properly clean (no cache) build.

The message seems to be coming from OpenAL since it's the only dynamic library that we use, and the message is stating it's from a dynamic library explicitly.

I tried deleting bin and trying a fresh run but that doesn't work either.
When I run the command it does the whole thing without any errors, but never opens the exe. when I try and manually open the exe is when I get the error.
Just realised I haven't tried restarting, I'm going to bed now so I'll try it again in the morning.

Here's the entire output from the build:
https://gist.github.com/hedgehog90/203a71df9a15f659f039

Well that's weird. The problem somehow resolved itself...
I executed the command: haxelib run snowfall update luxe
After that, I tried to build it again. Same problem. No errors, tells me the build was successful, but it never runs. When I manually run it, I get the old error again.
I did this once, and then, just for the hell of it, I tried again. This time it compiled from scratch without my instruction, a minute later it had successfully compiled.

EDIT - Oh I just remembered I installed MSVS 2013 earlier today. That must be why.

You can run with --log 3 and look for the hxcpp logo to see what it's telling you about which version of MSVC it's using - could it be a 2015 specific thing?

I did that earlier and noticed it was saying 18 now instead of whatever number 2010 had. 13 or 15 I think.

Doppp commented

@hedgehog90 Did you manage to solve this problem? I am on Windows 8.1 and get the exact same issue with you. Only works in Debug mode and can't locate the OpenAL32.dll file.

cc: @underscorediscovery

Newer versions of snow automatically copy the correct OpenAL dll to the bin folder (you should see it there without any need to copy it manually) if your setup is configured correctly. Check to see that it is there, for instance, delete the bin folder, run flow build and check the dll is alongside the exe.

Doppp commented

@underscorediscovery The dll file is in the right place but the error still persists. Like @hedgehog90 mentioned, everything compiles but doesn't open the exe.

Do you have openal itself installed? The installer that is, not the sdk. Can you try run the installer and then see if it persists?

Doppp commented

@underscorediscovery Yes I did. Do I need VS installed?

You ran it and the error is still there? If you're compiling c++ target yes, but you wouldn't get an exe at all without VS, so I suspect you have it?

Doppp commented

I don't have it installed explicitly, when I was setting up Haxe they installed VS for me, so yes, I do have it. I ran the OpenAL installer and did a clean build and the error is still there. The debug version of the exe works.

The haxe installer does not install VS, so I can guess you maybe mean lime (or something else). It's quite difficult to debug inconsistencies with VS because MS made a mess of it, so I'm unsure if the error shown is somehow related to VS and not OpenAL. The only concrete suggestion I can offer is cleaning up all versions of VS, restart, and then install only one version of VC++ to build stuff with, and restart again. Unfortunately Windows doesn't give you much to go on here, and the number of reports have been low so it's hard to pinpoint.

Doppp commented

Will do. I'll try with later versions of and report back.

Doppp commented

@underscorediscovery I took your advice and deleted all versions of VS and installed VS 2013 like @hedgehog90. Turns out it only works on 2013 and not 2015 which was what I had installed. Geez, that took some time. x_x

It's still peculiar though, luxe/snow should work just fine on 2015 so I'm not sure where the issue is specifically rooted. Thanks for reporting back though and I'm glad it's working.

Doppp commented

2015 probably works but maybe I had other versions of VS installed and they might have caused issues. 2013 works for now at least. :)

Doppp commented

I deleted 2013 and reinstalled 2015. It works. I'm thinking it had something to do with having multiple versions of VS installed.

I encountered this issue as well. Deleting the old (2010) version of VS and rebooting worked for me. I'm using 2015 now.

Would recommend updating https://luxeengine.com/get/ to add the solution of deleting old versions of VS or pointing to this issue - it wasn't clear to me after reading that page what I was supposed to do to resolve the issue.