GithubHelp home page GithubHelp logo

Comments (7)

zcaudate avatar zcaudate commented on June 26, 2024

Output is listed: https://github.com/zcaudate/sample-jep-graal#running

from graalvm-clojure.

BrunoBonacci avatar BrunoBonacci commented on June 26, 2024

Hi @zcaudate ,

It is probably because of the “closed world assumption” you have to provide at compile-time all the dependencies that you will use at runtime.

I’m currently on holidays with limited internet access but I’d suggest that you have a read to
https://www.graalvm.org/docs/Native-Image/user/JNI

Bruno

from graalvm-clojure.

zcaudate avatar zcaudate commented on June 26, 2024

Thanks @BrunoBonacci. Enjoy your holidays!

The program compiles but is not working at runtime.

I did ask around about that and even attempted to hand code the JNI.json for about half a day before finding a better solution. The call to --agentlib does the instrumentation to generate the JNI.json.

Anyways. Most of the problems I've run into are captured here: ninia/jep#271 and I gave some more background here: babashka/babashka#517 who pointed me out to you.

I think I'm pretty close and it's not that urgent but any help would be great.

from graalvm-clojure.

BrunoBonacci avatar BrunoBonacci commented on June 26, 2024

Make sure that the native library is either embedded in your jar or the -Djna.library.path= is set correctly.

from graalvm-clojure.

zcaudate avatar zcaudate commented on June 26, 2024

The shared library is located here: /usr/local/Cellar/[email protected]/3.8.3_2/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/jep/ after a brew install it uses JNI so I'm not sure that setting jna.library.path would help.

The layout of the folder looks like this:
Screen Shot 2020-08-18 at 3 44 40 pm

Where does the folder go?

When not compiled using Native Image, I'm doing a bootstrap call to an external python process to find this directory:
https://github.com/zcaudate/sample-jep-graal/blob/master/src/jep/graal.clj#L30

from graalvm-clojure.

BrunoBonacci avatar BrunoBonacci commented on June 26, 2024

from graalvm-clojure.

zcaudate avatar zcaudate commented on June 26, 2024

Sweet. Thanks Bruno. I'll give it another go.

from graalvm-clojure.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.