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

Link failure with GraalVM 21.1.0 for Java 16 #314

Closed
mipastgt opened this issue Apr 22, 2021 · 11 comments
Closed

Link failure with GraalVM 21.1.0 for Java 16 #314

mipastgt opened this issue Apr 22, 2021 · 11 comments

Comments

@mipastgt
Copy link

mipastgt commented Apr 22, 2021

I tested building my application with the client-maven-plugin on a Mac with the new GraalVM 21.1.0 for Java 16. It failed at the end with a link error.

[Do. Apr. 22 16:46:11 MESZ 2021][INFO] [SUB] ld: library not found for -lsunec

The exact same setup worked without problem with the same GraalVM version for Java 11. I used client-maven-plugin version 0.1.39, JavaFX 17-ea+7. The configuration was all created by running the agent.

@alialkubaisi
Copy link

Same here.

@markhuang1993
Copy link

I am build on Windows with same GraalVM and Java version, and have same error:

[週一 7月 12 17:34:29 TST 2021][INFO] [SUB] LINK : fatal error LNK1181: 無法開啟輸入檔 'sunec.lib'

This solve my problem:

1.Copy link command on error log
2.Remove 'sunec.lib' in command
3.Run new command again

@dwhitla
Copy link

dwhitla commented Sep 9, 2021

I experienced the same issue today on MacOS 10.15.7 graalvm-ce-java16-21.2.0 using both gluonfx-maven-plugin 1.0.4 and 1.0.5-SNAPSHOT built from 9ff71e7

@beatngu13
Copy link
Contributor

Same with GraalVM CE Java 17 21.3.0, JavaFX 17.0.0.1, and GluonFX Maven Plugin 1.0.7:

  • Linux:
    [INFO] [SUB] gcc: error: /opt/hostedtoolcache/GraalVM/21.3.0-java17-amd64/x64/lib/static/linux-amd64/glibc/libsunec.a: No such file or directory
  • macOS:
    [INFO] [SUB] ld: library not found for -lsunec
  • Windows:
    [INFO] [SUB] LINK : fatal error LNK1181: cannot open input file 'sunec.lib'

@mipastgt
Copy link
Author

It works with the Java 11 version.

@beatngu13
Copy link
Contributor

Yes, I can confirm that. But I thought this issue is specifically about Java 16+?

@jperedadnr
Copy link
Contributor

sunec library has been removed from JDK 16+. The plugin (1.0.10) already checks if you are running on JDK 11 (keeps the library) or greater (removes the library).

@beatngu13
Copy link
Contributor

@jperedadnr thank you for the update, I can confirm that it works with 1.0.10 – at least on macOS and Windows. On Linux, I still get [INFO] [SUB] /usr/bin/ld: cannot find -l:libsunec.a. But this could also be an issue with my workflow, will dig a little deeper.

Side note: 1.0.1 is still the latest release on GitHub, which might be confusing to some users.

@jperedadnr
Copy link
Contributor

There was a small issue with sunec on Linux, it has been fixed with 1.0.11-SNAPSHOT
(Include this repo:)

<pluginRepositories>
        <pluginRepository>
            <id>Snapshots</id>
            <url>http://oss.sonatype.org/content/repositories/snapshots/</url>
        </pluginRepository>
    </pluginRepositories>

Yes, releases are done via Github actions, and they don't show as releases, but Maven badge shows 1.0.10

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

7 participants
@jperedadnr @beatngu13 @mipastgt @markhuang1993 @dwhitla @alialkubaisi and others