x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

External dynamic lib causes crashes on Windows 10

I've spent many days struggling with crashes and the following error every time I tried to run my project (both editor or game build) with external lib:

"The game module 'myGameTest' could not be loaded. There may be an operating system error or the module may not be properly set up"

I've checked every step of the linkage procedure. The project compiles successfully on Visual Studio and there are copies of the DLLs in the required folders... I'm on Windows 10.

Today I got my hands on a Windows 8.1 PC with same UE4 version and tried to run the same project. I just made a copy of the project folder to the other machine with the same UE4 version and... it worked flawlessly! I've even built the project again on that machine and made changes on code to run some tests and didn't get any single problem...

Then I tried to place the same copy of the project on a fresh Windows 10 PC just to make sure it wasn't some weird issue on the first machine itself. And it didn't run again... So I can just conclude that DLL linkage is causing crashes under Windows 10 for some reason here... Both Windows 8.1 and 10 are 64bits version.

The library itself is working fine on Windows 10, I've tested it on non-UE4 projects and it works.

Does anyone have any idea about the cause of that? I can't format my main machine and install Windows 8.1 again just because of this issue...

Ps; I've tried this on both 4.8 and 4.9 UE4 versions.

Product Version: UE 4.9
Tags:
more ▼

asked Oct 02 '15 at 05:21 PM in C++ Programming

avatar image

rabellogp
79 3 10 18

(comments are locked)
10|2000 characters needed characters left

1 answer: sort voted first

You need to load it manually, follow the next code from the physics system and how it loads the PhysX DLL's. The code is located in: Engine/Source/Runtime/Engine/Private/PhysicsEngine/PhysXLibs.cpp

more ▼

answered Oct 02 '15 at 07:05 PM

avatar image

lion032
981 31 80 55

avatar image rabellogp Oct 02 '15 at 07:59 PM

I don't get it... I'll need to create a cpp file like that to load the external library somehow? I thought that was only necessary if I'm including the external library as a new module... I'm currently loading the includes and libs via myProject.Build.cs as explained here https://wiki.unrealengine.com/Linking_Static_Libraries_Using_The_Build_System

I created a ThirdParty folder inside my project folder and put the libraries in there, properly organizing and linking them on myProject.Build.cs. Then I copied the DLL to the Binaries folder (inside my project) and it works fine on Windows 8. But it won't work on Windows 10...

If there is a reason for that and now the only way to include external libs on Windows 10 is creating a new module, I'll do it. But I have no idea on how to turn the library into those modules with cpp and all those labels... Is there a tutorial about that somewhere?

ps: the library I'm trying to use is SimpleAmqpClient and rabbitmq-c

avatar image lion032 Oct 02 '15 at 08:04 PM
avatar image rabellogp Oct 02 '15 at 09:02 PM

That can't help me either, but thanks..

I'm not trying to migrate code between projects. I just can't get the very same project that runs fine on Windows 8 to run on Windows 10 too.. And I think the cause is somehow the external lib linking because when I remove its usage from code, the project runs fine on both Windows 8 and 10.

As I can use it on Win8, it has to be related to Windows version... But it is looking like a bug already. I'd like to find someone that has successfully run the same project on Win8 and Win10 while using external dynamic libs...

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question