Closed ioquatix closed 3 years ago
I have no expertise with the JRuby extension of nio4r, so can't help here.
It looks like just general Java warnings due to changes in the Java standard or something?
I will look into this and the other issues you mentioned tomorrow, thanks for letting me know!
On Wed, Sep 9, 2020, 19:23 Samuel Williams notifications@github.com wrote:
It looks like just general Java warnings due to changes in the Java standard or something?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/socketry/nio4r/issues/245#issuecomment-689894357, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAACPFZA3MZFXGRMGS6ZVVTSFAMBTANCNFSM4Q5VLXGA .
@ioquatix Yes, these are just general Java warnings that anyone with Java knowledge could fix. I will submit a PR to eliminate the warnings.
Note also these only come up because the compiler runs with -Xlint
which prints more warnings than normal. But they're probably good to fix, I guess.
Pushed #252 to fix this.
The warnings are all gone except for one related to how javac
guarantees it is compiling for an earlier version (need to have earlier version installed and specify that install as the "boot" class path). This is an issue that would need to be fixed in the rake-compiler invocation of javac (it should use the "-release 8" flag on Java versions 9 or higher).
$ rake clean compile
mkdir -p tmp/java/nio4r_ext
javac -target 1.8 -source 1.8 -Xlint -d tmp/java/nio4r_ext -cp /Users/headius/.rvm/rubies/jruby-9.2.13.0/lib/jruby.jar ext/nio4r/org/nio4r/ByteBuffer.java ext/nio4r/org/nio4r/Monitor.java ext/nio4r/org/nio4r/Nio4r.java ext/nio4r/org/nio4r/Selector.java
warning: [options] bootstrap class path not set in conjunction with -source 8
1 warning
touch tmp/java/nio4r_ext/.build
jar cf tmp/java/nio4r_ext/nio4r_ext.jar -C tmp/java/nio4r_ext org/nio4r/ByteBuffer.class -C tmp/java/nio4r_ext org/nio4r/Monitor.class -C tmp/java/nio4r_ext org/nio4r/Nio4r\$1.class -C tmp/java/nio4r_ext org/nio4r/Nio4r\$2.class -C tmp/java/nio4r_ext org/nio4r/Nio4r\$3.class -C tmp/java/nio4r_ext org/nio4r/Nio4r.class -C tmp/java/nio4r_ext org/nio4r/Selector.class
install -c tmp/java/nio4r_ext/nio4r_ext.jar lib/nio4r_ext.jar
The above build was done on Java 14, the most recent release.
Thanks so much for your help!
@headius / @eregon do either of you mind helping me with these?