-
-
Notifications
You must be signed in to change notification settings - Fork 575
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't open dynamic library: [...] error: Error 126: The specified module could not be found.
But the .dll is right there
#1064
Comments
Found related issue already opened, though #976 mentions that beta 8 and 9 have been tested. So this could be a regression introduced in previous beta releases. |
I noticed it tends to happen with dlls built with mingw, i noticed building with MSVC instead tends to fix this issue |
Check for the library dependencies (and dependencies of dependencies, use tools like https://github.com/lucasg/Dependencies to check it). All non-system libs should be in the same folder as the GDExtension library. Windows return the same |
I was getting the exact same error, I was being able to compile the library but the editor couldn't load the .gdextension resource, throwing error 126 as the library was being linked dynamically instead of linking statically. The PR #1082 fixed my issue by passing the static flags to the linker. |
I had been building my plugin hundreds of times successfully with MSVC on 4.0.2. I added this to my class:
It compiles fine, but suddenly Godot can't find the extension:
I changed it to |
System: Windows 11
Godot Version: v4.0.stable.official.92bee43ad
godot-cpp version: 4.0 branch
extension source code: qrnative
Last time I tried to compile and use my custom extension worked (it was on Godot 4 beta 3).
Even after updating everything, and following the documentation, when I try to use the .dll in Godot after compilation of both
godot-cpp
and my library, the following message appears in the Editor:Altough the path to the .dll is correct and there are no typos.
Here's the
.gdextension
fileI've put the link to the source code, if anybody using w11 want's to try to test the extension. The source code contains the example project used in this issue.
Anyway, compilation tests work on all of the desktop platforms, so I don't know if I'm really missing something or it is something on Windows 11.
The text was updated successfully, but these errors were encountered: