-
Notifications
You must be signed in to change notification settings - Fork 697
feat(bindings/java): Add musl platform support #7087
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
base: main
Are you sure you want to change the base?
Conversation
bindings/java/src/main/java/org/apache/opendal/NativeLibrary.java
Outdated
Show resolved
Hide resolved
| ] | ||
| print("$ " + subprocess.list2cmdline(link_cmd)) | ||
| subprocess.run(link_cmd, cwd=basedir, check=True) | ||
| raise SystemExit(0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why always raise here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a weird AI code. It's actually sys.exit(0) here. Refactored.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But it looks still incorrect. We need the following lines to move the output artifacts.
| if (loader == null) { | ||
| return false; | ||
| } | ||
| return Files.exists(Paths.get("/lib", loader)) || Files.exists(Paths.get("/usr/lib", loader)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you test this line works?
I suspect that with bundled jar the file doesn't exist on /lib but in the JAR package.
Which issue does this PR close?
Closes #7086
Rationale for this change
This PR will add musl platform support for binding java.
What changes are included in this PR?
Are there any user-facing changes?
AI Usage Statement
Parts of this PR were drafted with assistance from Codex (with
gpt-5.2) and fully reviewed and edited by me. I take full responsibility for all changes.