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

JRuby extension fails to build on Windows #522

Open
headius opened this issue Mar 8, 2023 · 1 comment
Open

JRuby extension fails to build on Windows #522

headius opened this issue Mar 8, 2023 · 1 comment

Comments

@headius
Copy link
Contributor

headius commented Mar 8, 2023

The build on Windows appears to have trouble locating the JRuby jar file, resulting in many missing classes during the extension build.

https://github.com/flori/json/actions/runs/4360822114/jobs/7624157859

The classpath gets set to a path to the JRuby jar file, but it does not appear to be correct:

javac -classpath java/src:D:/jruby-9.4.1.0/lib/jruby.jar -source 1.6 -target 1.6 java/src/json/ext/ByteListTranscoder.java
warning: [options] bootstrap class path not set in conjunction with -source 1.6
java\src\json\ext\ByteListTranscoder.java:8: error: package org.jruby.exceptions does not exist
import org.jruby.exceptions.RaiseException;
                           ^
java\src\json\ext\ByteListTranscoder.java:9: error: package org.jruby.runtime does not exist
import org.jruby.runtime.ThreadContext;
                        ^
java\src\json\ext\ByteListTranscoder.java:10: error: package org.jruby.util does not exist
import org.jruby.util.ByteList;
                     ^
...

This probably never worked, since we usually just build the extension once on Linux or MacOS and release it for all platforms that way. We'll need to make sure the classpath is getting set properly for the extension build when running on Windows.

@hsbt
Copy link
Collaborator

hsbt commented Mar 8, 2023

@headius Should we stop the build and test with Windows platform?

We can build jar file at linux or macOS, and upload artifact with https://github.com/actions/upload-artifact, after that download it with https://github.com/actions/download-artifact, test it on Windows.

How about it?

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

No branches or pull requests

2 participants