[eclipse] Failed to load JavaHL Library

After updating to Snow Lion I started receiving these errors in Flash Builder / Eclipse when trying to use SVN:

Failed to load JavaHL Library.
These are the errors that were encountered:
no libsvnjavahl-1 in java.library.path
/opt/subversion/lib/libsvnjavahl-1.0.dylib:  Library not loaded: /usr/lib/libpq.5.dylib   Referenced from: /opt/subversion/lib/libsvnjavahl-1.0.dylib   Reason: no suitable image found.  Did find:  /usr/lib/libpq.5.dylib: mach-o, but wrong architecture  /usr/lib/libpq.5.dylib: mach-o, but wrong architecture
no svnjavahl in java.library.path
java.library.path = .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java

This question is related to eclipse apache-flex svn flash-builder subclipse

The answer is


Try this:

  1. Select Window >> Preferences
  2. Expand Team >> SVN
  3. Under SVN interface set Client to SVNKit (Pure Java) SVNKit....

maybe you can try this: change jdk version. And I resolved this problem by change jdk from 1.6.0_37 to 1.6.0.45 . BR!


You may or may not need JavaHL depending on your OS. In addition to other suggestions just posting this here.

enter image description here

For other OS see this source: http://subclipse.tigris.org/wiki/JavaHL


My Understanding - Basically, svn client comes by default on Mac os. While installing in eclipse we should match svn plugin to the mac plugin and javaHL wont be missing. There is a lengthy process to update by installing xcode and then by using homebrew or macports which you can find after googling but if you are in hurry use simply the steps below.

1) on your mac terminal shell

$ svn --version

Note down the version e.g. 1.7.

2) open the link below

http://subclipse.tigris.org/wiki/JavaHL

check which version of subclipse you need corresponding to it. e.g.

Subclipse Version SVN/JavaHL Version 1.8.x 1.7.x

3) ok, pick up url corresponding to 1.8.x from

http://subclipse.tigris.org/servlets/ProjectProcess?pageID=p4wYuA

and add to your eclipse => Install new Software under help

select whatever you need, svn client or subclipse or mylyn etc and it will ask for restart of STS/eclipse thats it you are done. worked for me.

NOTE: if you already have multiple versions installed inside your eclipse then its best to uninstall all subclipse or svn client versions from eclipse plugins and start fresh with steps listed above.


I Just installed Mountain Lion and had the same problem I use FLashBuilder (which is 32bit) and MountainLion is 64bit, which means by default MacPorts installs everything as 64bit. The version of subclipse I use is 1.8 As i had already installed Subversion and JavaHLBindings I just ran this command:

 sudo port upgrade --enforce-variants active +universal 

This made mac ports go through everything already installed and also install the 32bit version.

I then restarted FlashBuilder and it no longer showed any JavaHL errors.


For me i started getting this problem when I upgraded to java 8, and then reverted back to java 7. Upgraded again to java 8 and the problem got resolved.


i tried every single solution available and finally for me the problem was:

uninstall Native JavaHL 1.6

install everything under Subclipse from this site:

http://subclipse.tigris.org/update_1.10.x>


On Kubuntu, my path to the library changed because of installing another Java version. Here's the whole picture, but in short:

sudo apt-get install libsvn-java
sudo find / -name libsvnjavahl-1.so

The output from the last command could look like this, for example:

/usr/lib/x86_64-linux-gnu/jni/libsvnjavahl-1.so

This gives you the path, so you can add the following to your eclipse.ini:

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

Check out this blog. It has a ton of information. Also if installing through brew donĀ“t miss this note:

You may need to link the Java bindings into the Java Extensions folder:

 $ sudo mkdir -p /Library/Java/Extensions
 $ sudo ln -s /usr/local/lib/libsvnjavahl-1.dylib /Library/Java/Extensions/libsvnjavahl-1.dylib

For Eclipse/STS v3.9.X windows user, you may need to update your subclipse version.

Go to Help > Install New Software > Click on Subclipse and edit the version from 1.6.X to 1.8.X

This method also apply to those who encounter JavaHL not available. You can check whether JavaHL is available or not by Go to Windows > Preference > Team > SVN. You may check it in SVN Interface > Client section.

If this work on MAC OS, kindly response in comment section. :)


Examples related to eclipse

How do I get the command-line for an Eclipse run configuration? My eclipse won't open, i download the bundle pack it keeps saying error log strange error in my Animation Drawable How to uninstall Eclipse? How to resolve Unable to load authentication plugin 'caching_sha2_password' issue Class has been compiled by a more recent version of the Java Environment Eclipse No tests found using JUnit 5 caused by NoClassDefFoundError for LauncherFactory How to downgrade Java from 9 to 8 on a MACOS. Eclipse is not running with Java 9 "The POM for ... is missing, no dependency information available" even though it exists in Maven Repository The origin server did not find a current representation for the target resource or is not willing to disclose that one exists. on deploying to tomcat

Examples related to apache-flex

Failed to load JavaHL Library How to pass "Null" (a real surname!) to a SOAP web service in ActionScript 3 How do I get a HttpServletRequest in my spring beans? What is the best way to get the minimum or maximum value from an Array of numbers? Eclipse memory settings when getting "Java Heap Space" and "Out of Memory"

Examples related to svn

Error "can't use subversion command line client : svn" when opening android project checked out from svn How to view changes made to files on a certain revision in Subversion Intellij idea subversion checkout error: `Cannot run program "svn"` How change default SVN username and password to commit changes? How to rename a file using svn? Connect Android Studio with SVN svn: E155004: ..(path of resource).. is already locked SVN Commit failed, access forbidden How to add an existing folder with files to SVN? Update OpenSSL on OS X with Homebrew

Examples related to flash-builder

Failed to load JavaHL Library

Examples related to subclipse

Failed to load JavaHL Library How to fix Subversion lock error Why do I keep getting 'SVN: Working Copy XXXX locked; try performing 'cleanup'? Associating existing Eclipse project with existing SVN repository Subclipse svn:ignore How to change credentials for SVN repository in Eclipse? Adding a SVN repository in Eclipse Rolling back bad changes with svn in Eclipse