Unable to Compile Maven Project with Guava using j2cl-maven-plugin #229
Unanswered
loveslikey
asked this question in
Q&A
Replies: 1 comment
-
Thanks for trying this out, but please keep the j2cl-maven-plugin discussions over at https://github.com/Vertispan/j2clmavenplugin/discussions so as to not pollute the upstream Google project that graciously has formed the basis for the maven plugin. The issue you're running into is limited to the maven build tooling, not anything specific to j2cl itself. To port this, we'll want to understand what expectations the |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am currently working on a project where I'm attempting to use the j2cl-maven-plugin to compile Java code for use in a browser environment. I've noticed that in the official demo, bazel-helloworld, libraries like Guava are being utilized successfully. However, when I try to import these same libraries (e.g., Guava ) into my Maven project using the j2cl-maven-plugin, the compilation fails.
I've searched for documentation or examples that might explain how to properly include these libraries in a Maven project with j2cl-maven-plugin, but haven't found anything relevant.
Could you please provide guidance on how to successfully use libraries like Guava with j2cl-maven-plugin in a Maven project? Is there a special configuration or additional steps that I need to follow?
Thank you for your assistance!
Error info:
ImmutableList cannot be resolved to a type [ERROR] com.major.j2cl:acss:1.0-SNAPSHOT/transpiled_js: Error:E:\project\idea_speace\j2clDemo\target\gwt3BuildCache\...\stripped_sources\App.java:39: ImmutableList cannot be resolved
maven dependency
<dependency>\n <groupId>com.google.guava</groupId> <artifactId>guava-gwt</artifactId> <version>32.1.1-jre</version> </dependency>
Beta Was this translation helpful? Give feedback.
All reactions