You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The LmdbJava Native project can be archived. This project required coordination with LmdbJava module releases and added extra artifacts to Maven Central simply to wrap native libraries. The native project also required a great deal of Maven configuration and it was always tedious to support additional platforms. Using Zig eliminates the need to run QEMU emulators in builds to support unusual platforms etc.
Zig supports numerous cross-compilation targets straight out of the box. A full list is available via zig targets | jq -r '.libc[]' and this presently lists 64 on my machine. This is likely to accommodate most LmdbJava platform support requests we are likely to receive.
Platform naming conventions have now been standardised based on the Zig target name. Support for individual build chains or specific processors is now simplified and much more transparent.
The GitHub Action has been amended to perform cross-compilation under Linux and upload the resulting native artifacts for later build steps. The later build steps run the Verifier on a native VM where available (eg Windows, Mac OS) and this therefore tests the cross-compiled libraries.
Target name resolution logic has been refactored and externalised in its own class with corresponding unit tests to ensure corner cases are duly considered and any bugs more easily reproduced and permanently rectified.
This change is backwards compatible with users who used (and may continue to use) the lmdbjava.native.lib system property.
This new approach provides a number of benefits:
1. The LmdbJava Native project can be archived. This project required
coordination with LmdbJava module releases and added extra artifacts
to Maven Central simply to wrap native libraries. The native project
also required a great deal of Maven configuration and it was always
tedious to support additional platforms. Using Zig eliminates the need
to run QEMU emulators in builds to support unusual platforms etc.
2. Zig supports numerous cross-compilation targets straight out of the
box. A full list is available via zig targets | jq -r '.libc[]' and
this presently lists 64 on my machine. This is likely to accommodate
most LmdbJava platform support requests we are likely to receive.
3. Platform naming conventions have now been standardised based on the
Zig target name. Support for individual build chains or specific
processors is now simplified and much more transparent.
4. The GitHub Action has been amended to perform cross-compilation
under Linux and upload the resulting native artifacts for later build
steps. The later build steps run the Verifier on a native VM where
available (eg Windows, Mac OS) and this therefore tests the
cross-compiled libraries.
5. Target name resolution logic has been refactored and externalised
in its own class with corresponding unit tests to ensure corner cases
are duly considered and any bugs more easily reproduced and
permanently rectified.
This change is backwards compatible with users who used (and may
continue to use) the lmdbjava.native.lib system property.
I can use mvn package with no test errors on Linux x86 and Mac OS X ARM64 with master branch head, and the same with this new PR. I will do some more tests using mvn package on mac arm64, but the build jar files appear to work.
I'm not 100% sure about the state of this issue. My impression: It has been fixed, but so far there is not public release which contains the fix. Is that correct? In that case it would be really nice to ship a new lmdbjava version (current: 0.8.3).
@jubax, you are correct in that this is scheduled for inclusion in 0.9.0 as per the Change Log.
I need to have a closer look at #215 before I release 0.9.0 in case it's a bug, after which I will make a release (I've follow a "Zero Bug Policy" for a couple of decades now; it's the only way to keep on top of them!).
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This new approach provides a number of benefits:
The LmdbJava Native project can be archived. This project required coordination with LmdbJava module releases and added extra artifacts to Maven Central simply to wrap native libraries. The native project also required a great deal of Maven configuration and it was always tedious to support additional platforms. Using Zig eliminates the need to run QEMU emulators in builds to support unusual platforms etc.
Zig supports numerous cross-compilation targets straight out of the box. A full list is available via zig targets | jq -r '.libc[]' and this presently lists 64 on my machine. This is likely to accommodate most LmdbJava platform support requests we are likely to receive.
Platform naming conventions have now been standardised based on the Zig target name. Support for individual build chains or specific processors is now simplified and much more transparent.
The GitHub Action has been amended to perform cross-compilation under Linux and upload the resulting native artifacts for later build steps. The later build steps run the Verifier on a native VM where available (eg Windows, Mac OS) and this therefore tests the cross-compiled libraries.
Target name resolution logic has been refactored and externalised in its own class with corresponding unit tests to ensure corner cases are duly considered and any bugs more easily reproduced and permanently rectified.
This change is backwards compatible with users who used (and may continue to use) the lmdbjava.native.lib system property.