Skip to content
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

UnsatisfiedLinkError when upgrade imgui-java from 1.83.2 to 1.85.0 #95

Closed
Illithidek opened this issue Dec 7, 2021 · 5 comments · Fixed by #96
Closed

UnsatisfiedLinkError when upgrade imgui-java from 1.83.2 to 1.85.0 #95

Illithidek opened this issue Dec 7, 2021 · 5 comments · Fixed by #96

Comments

@Illithidek
Copy link
Contributor

Hey, when I upgrade version from 1.83.2 to 1.85.0 I get following error:

Exception in thread "main" java.lang.InternalError: java.lang.UnsatisfiedLinkError: 'short org.lwjgl.system.libffi.LibFFI.FFI_TYPE_DOUBLE()' at java.base/java.lang.invoke.InnerClassLambdaMetafactory.generateInnerClass(InnerClassLambdaMetafactory.java:415) at java.base/java.lang.invoke.InnerClassLambdaMetafactory.spinInnerClass(InnerClassLambdaMetafactory.java:304) at java.base/java.lang.invoke.InnerClassLambdaMetafactory.buildCallSite(InnerClassLambdaMetafactory.java:218) at java.base/java.lang.invoke.LambdaMetafactory.metafactory(LambdaMetafactory.java:328) at java.base/java.lang.invoke.BootstrapMethodInvoker.invoke(BootstrapMethodInvoker.java:127) at java.base/java.lang.invoke.CallSite.makeSite(CallSite.java:315) at java.base/java.lang.invoke.MethodHandleNatives.linkCallSiteImpl(MethodHandleNatives.java:281) at java.base/java.lang.invoke.MethodHandleNatives.linkCallSite(MethodHandleNatives.java:271)

I suppose this can be made due to fact that I'm using lwjgl 3.3.0 instead 3.2.3 like imgui-java right now.
It's strange for this to happen in the new imgui release when in the old one I didn't have this problem, something has changed?
Thanks in advance for any answer!

@SpaiR
Copy link
Owner

SpaiR commented Dec 7, 2021

It's strange. There were changes in the native part of the binding, but I can't see how they can be related to the exception log you've provided. Did you tried to run your stuff with lwjgl 3.2.3? Is the problem connected with the difference in versions for real?

@Illithidek
Copy link
Contributor Author

Illithidek commented Dec 7, 2021

@SpaiR I just checked, when I change lwjgl to 3.2.3 it's works. The disadvantage is that I cannot then use SPIRV-Cross in vulkan, because it came in lwjgl 3.3.0. So maybe the best idea would be to upgrade lwjgl in imgui-java to 3.3.0?

@SpaiR
Copy link
Owner

SpaiR commented Dec 8, 2021

Binding depends on lwjgl to provide glfw and opengl implementations. Basically, imgui-java-lwjgl3 package. It's optional, so you can copy-paste a content of that package to your local codebase and use any lwjgl version you want.

@Illithidek
Copy link
Contributor Author

Illithidek commented Dec 8, 2021

Yeah but I believe there is no reason to use an older version of lwjgl in the main repo.
I maked PR for that: #96

@tlf30
Copy link
Contributor

tlf30 commented Dec 9, 2021

Interesting, I am running LWJGL 3.3.0 and not getting this error. But I fully support updating this library.

Illithidek added a commit to Illithidek/imgui-java that referenced this issue Dec 10, 2021
In order to use imgui-java with the lwjgl 3.3.0 without errors there is need for an update.
To remove code duplication when changing dependencies, a dependencies.gradle file was added.
Fixes: SpaiR#95

- update lwjgl version from 3.2.3 to 3.3.0 across all submodules
- add dependencies.gradle and apply it across all submodules
Illithidek added a commit to Illithidek/imgui-java that referenced this issue Dec 13, 2021
In order to use imgui-java with the lwjgl 3.3.0 without errors there is need for an update.
To remove code duplication when changing dependencies,
an lwjgl.bom variable was added.
Fixes: SpaiR#95

- update lwjgl version from 3.2.3 to 3.3.0 across all submodules
@SpaiR SpaiR closed this as completed in #96 Dec 15, 2021
SpaiR pushed a commit that referenced this issue Dec 15, 2021
In order to use imgui-java with the lwjgl 3.3.0 without errors there is need for an update.
To remove code duplication when changing dependencies,
an lwjgl.bom variable was added.
Fixes: #95

- update lwjgl version from 3.2.3 to 3.3.0 across all submodules
SpaiR pushed a commit that referenced this issue Dec 15, 2021
In order to use imgui-java with the lwjgl 3.3.0 without errors there is need for an update.
To remove code duplication when changing dependencies,
an lwjgl.bom variable was added.
Fixes: #95

- update lwjgl version from 3.2.3 to 3.3.0 across all submodules
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants