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

Support of LLVM backend #65

Open
plokhotnyuk opened this issue Feb 13, 2023 · 0 comments
Open

Support of LLVM backend #65

plokhotnyuk opened this issue Feb 13, 2023 · 0 comments

Comments

@plokhotnyuk
Copy link

plokhotnyuk commented Feb 13, 2023

Describe the bug

The plugin should support compilation with LLVM backend

To Reproduce

  1. Clone the following repository: git clone --depth 1 https://github.com/plokhotnyuk/jsoniter-scala
  2. Enter to the examples project: cd jsoniter-scala/jsoniter-scala-examples
  3. Add "-H:CompilerBackend=llvm" to the sequence of nativeImageOptions in the build.sbt
  4. Run sbt jsoniter-scala-examplesJVM/nativeImage

Expected behavior

Successfully compiled native image

Current behavior

andriy@notebook:~/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples$ sbt jsoniter-scala-examplesJVM/nativeImage
[info] welcome to sbt 1.7.2 (Azul Systems, Inc. Java 17.0.5)
[info] loading global plugins from /home/andriy/.sbt/1.0/plugins
[info] loading settings for project jsoniter-scala-examples-build-build from sbt-updates.sbt ...
[info] loading project definition from /home/andriy/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples/project/project
[info] loading settings for project jsoniter-scala-examples-build from plugins.sbt ...
[info] loading project definition from /home/andriy/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples/project
[info] loading settings for project root from build.sbt ...
[info] set current project to root (in build file:/home/andriy/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples/)
[warn] there are 2 keys that are not used by any other settings/tasks:
[warn]  
[warn] * jsoniter-scala-examplesJVM / nativeImageJvm
[warn]   +- /home/andriy/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples/build.sbt:27
[warn] * jsoniter-scala-examplesJVM / nativeImageVersion
[warn]   +- /home/andriy/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples/build.sbt:26
[warn]  
[warn] note: a setting might still be used by a command; to exclude a key from this `lintUnused` check
[warn] either append it to `Global / excludeLintKeys` or call .withRank(KeyRanks.Invisible) on the key
[info] /home/andriy/.cache/coursier/jvm/[email protected]/bin/native-image -cp /home/andriy/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples/.jvm/target/native-image-internal/manifest.jar --no-fallback --initialize-at-build-time --diagnostics-mode -H:CompilerBackend=llvm com.github.plokhotnyuk.jsoniter_scala.examples.Example01 /home/andriy/Projects/com/github/plokhotnyuk/jsoniter-scala/jsoniter-scala-examples/.jvm/target/native-image/jsoniter-scala-examples
# Diagnostics mode enabled: image-build reports are saved to reports/diagnostics_20230213_105957
Apply jar:file:///home/andriy/.cache/coursier/jvm/[email protected]/lib/svm/library-support.jar!/META-INF/native-image/com.oracle.svm/thirdparty/native-image.properties
Apply jar:file:///home/andriy/.cache/coursier/jvm/[email protected]/lib/svm/library-support.jar!/META-INF/native-image/com.oracle.svm/polyglot/native-image.properties
# Printing command line arguments to: reports/diagnostics_20230213_105957/command-line_20230213_105957.txt
Error: Please install the LLVM backend for GraalVM Native Image via `$JAVA_HOME/bin/gu install native-image-llvm-backend`.
Error: Image build request failed with exit status 1
[error] native-image command failed with exit code '1'
[error] (jsoniter-scala-examplesJVM / nativeImage) native-image command failed with exit code '1'
[error] Total time: 2 s, completed Feb 13, 2023, 10:59:58 AM

Installation:

  • Operating system: Linux
  • Version: v0.3.2
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

1 participant