Replies: 1 comment 7 replies
-
Like you pointed, with Java 11 providing JRE emulation externally got more problematic. The main problem is mainly around adding new classes to existing modules. Is that not working? If not, maybe something is different in Bazel that might be causing a problem... |
Beta Was this translation helpful? Give feedback.
7 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Previous discussion: #157 (comment)
In that comment, the very reasonable point is made that adding arbitrary JRE classes/members to j2cl may not make sense for everyone - indeed, Dmitrii and I have different "gwt-nio" projects with different aims (one seeks complete emulation, the other seeks to limit itself to what can be efficiently done in the browser).
We're in the process of providing a flatbuffers implementation for GWT, and hoping to also make it J2CL compatible, and have been trying to use closure-compiler and guava as a guide here. However, both of those use only the stock JRE classes that can be found in j2cl (naturally, being Google projects), while FlatBuffers requires
java.nio.ByteBuffer
.It is fairly straightforward when using Java 8 to just add
java.*
classes to a project, but with Java 11 and Bazel, I don't see any examples or documentation showing how this might be done. Is this the kind of thing that is intended to be supported but isn't? I would rule out forking j2cl itself and adding support directly with no hope of upstreaming it.We've explored a few options to build this ourselves, but before picking an approach that works for Maven and might not work for Bazel, I was hoping to see if there was an "official" answer, or if we should just target our FlatBuffers implementation as "GWT and j2cl+maven only".
Beta Was this translation helpful? Give feedback.
All reactions