Failed to load JavaHL Library.- linux/eclipse

2019-04-20 03:29发布

问题:

While trying to install the Subversion plugin I get this error when Eclipse starts:

Failed to load JavaHL Library.
These are the errors that were encountered:
no libsvnjavahl-1 in java.library.path
/usr/lib/jni/libsvnjavahl-1.so.0.0.0: /usr/lib/jni/libsvnjavahl-1.so.0.0.0: wrong ELF class: ELFCLASS64 (Possible cause: architecture word width mismatch)
no svnjavahl in java.library.path
java.library.path = /usr/lib/jni

environment:

  • java version "1.6.0_29"
  • Java(TM) SE Runtime Environment (build 1.6.0_29-b11)
  • Java HotSpot(TM) Client VM (build 20.4-b02, mixed mode, sharing)
  • Linux debian 2.6.32-5-amd64 #1 SMP Mon Jan 16 16:22:28 UTC 2012 x86_64 GNU/Linux

I tried changing my java.library.path to a 64-bit lib but it doesn't help - I still go=et the same error (only last line changes - to a 64-bit path) Also, I have no idea why it's looking in /usr/lib/jni/ even after I change the java.library.path.

回答1:

I was annoyed by that message so I did this and it disappeared!



回答2:

To solved just install the package with this command:

sudo apt-get install libsvn-java

and you must config eclipse.inito add path /jni

example :

-Djava.library.path=/usr/lib/x86_64-linux-gnu/jni

https://danangindrak.wordpress.com/2012/02/23/solved-memperbaiki-subclipse-error-default-svn-client-not-found-pada-eclipse/



回答3:

OK I just ran into the same problem. I installed the javaHL lib but that didn't fix it alone. I was able to fix it by double checking which version of subversion I had installed in synaptic. I actually had 1.6.x while I installed the subclipse for version 1.8.x. so I started over, deleted my eclipse folder, extracted it and installed subclipse from the following eclipse update site: http://subclipse.tigris.org/update_1.6.x

more on the incompatibility: http://subclipse.tigris.org/wiki/JavaHL

http://subclipse.tigris.org/servlets/ProjectProcess?pageID=p4wYuA (get the one that says Links for 1.6.x Release:)



回答4:

The problem is that you don't have libsvn-java installed. To solved just install the package with this command:

sudo apt-get install libsvn-java

and you are read use subclipse.



回答5:

problem solved - the reason was that 64b Subversive SVN Connectors that were installed couldn't work with 32b JDK; I've re-installed eclipse to 32b version and everything is ok