eclipsesource / eclipsesource/J2V8
Running in IDE on Windows, but not working when deployed on Linux ?
- Dominant language
- Java
- Stars
- 2.6k
- Forks
- 387
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
On Windows, I add the dependency for J2V8 in my pom.xml, and then I can run my application within the Eclipse IDE just fine (I tested with version 4.6).
My goal is to run on Linux. So, I copy the J2V8 jar over to my Ubuntu along with the application using it.
When I try to start it with the command line, e.g. java -cp (the J2V8 jar is in the classpath), it fails with
java.lang.IllegalStateException: J2V8 native library not loaded
at com.eclipsesource.v8.V8.checkNativeLibraryLoaded(V8.java:195)
at com.eclipsesource.v8.V8.createV8Runtime(V8.java:149)
at com.eclipsesource.v8.V8.createV8Runtime(V8.java:110)
...
Caused by: java.lang.UnsatisfiedLinkError: Could not load J2V8 library. Reasons:
no j2v8_linux_i386 in java.library.path
at com.eclipsesource.v8.LibraryLoader.loadLibrary(LibraryLoader.java:75)
at com.eclipsesource.v8.V8.load(V8.java:71)
at com.eclipsesource.v8.V8.createV8Runtime(V8.java:145)
... 14 more
I also tried extracting the _x86_64.so library to the directory where my main class is, and to my libs directory, but I get the same result. I also find it odd that it's looking for the i386 version ????
What are the steps needed to run J2V8 on my Ubuntu 12.04 linux ?
Thanks.
Contributor guide
Research direction
Start with V8.java and LibraryLoader.java, then compare the Maven dependency and command-line classpath used in Eclipse and Ubuntu 12.04. Reproduce the native-library loading failure and determine the documented deployment steps, including why the i386 library is selected; done means a verified Linux launch procedure or a clearly documented incompatibility.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, linux
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 18/100