Skip to content
Discussion options

You must be logged in to vote

Hey @kenwenzel,

LWJGL builds LMDB into a JNI library with dedicated native methods. Even if the dlmdb API is compatible, there's no way to replace the lwjgl_lmdb binary with another build, because it will be lacking the JNI functions that Java needs.

If datalevin can afford to require JDK 25 or newer, my recommendation would be: build dlmdb into a standard .so and use the org.lwjgl.system.ffm API in LWJGL 3.4.0+ to create custom FFM-based bindings. SegmentStack provides the equivalent MemoryStack functionality for FFM segments, however it is trivial to convert between NIO buffers and MemorySegment if necessary.

Otherwise, it's either a new module in LWJGL as you said, or you can get creat…

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
1 reply
@kenwenzel
Comment options

Comment options

You must be logged in to vote
2 replies
@kenwenzel
Comment options

@Spasi
Comment options

Answer selected by kenwenzel
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants