9

I have installed Eclipse 3.5.2 and the plugin Subversion JavaHL Native Library Adapter 1.6.9.2 and this worked without any problems. However, this morning I was forced to change the password to logon to my Mac and since then I get the message that "Subversion native library not available" when I try to save any changes. Can anyone help? I have tried to add this line (-Djava.library.path=/usr/lib/jni) to the eclipse.ini file but this didn´t seem to make any difference.

Can anyone help?

IAdapter
  • 62,595
  • 73
  • 179
  • 242
INeedHelp
  • 91
  • 1
  • 1
  • 3

6 Answers6

2

Install MacPorts or HomeBrew, then run the following command:

For MacPorts, the commands to run are:

sudo port install subversion-javahlbindings +no_bdb +universal

For HomeBrew, the command is:

brew install --universal --java subversion
Glorfindel
  • 21,988
  • 13
  • 81
  • 109
Raptor
  • 53,206
  • 45
  • 230
  • 366
1

I was having a similar problem on Mac OS X Snow Leopard. I suspect your libraries are there but just need permissions changed, whereas I didn't have the libs at all.

The directory to check is /opt/subversion/lib, see if it has any libsvnjavahl files. In your case they may be there and just need new permissions.

To get the files I followed the the instructions they give for installing JavaHL on OS X, which is to download and install Open CollabNet. (login required, although it's free)

Then you just need to update your environment variable in .profile, something like:

export PATH=.:/opt/subversion/bin:$HOME/bin:$PATH

Then ran:

. .profile

Then I tested with javahltests.jar as mentioned here.

Community
  • 1
  • 1
Mark Bennett
  • 1,446
  • 2
  • 19
  • 37
  • 2
    You can also just create a symlink in /Library/Java/Extensions to the libjavahl library: `$ ls -l total 8 lrwxr-xr-x 1 root admin 40 Sep 23 2011 libsvnjavahl-1.jnilib -> /opt/subversion/lib/libsvnjavahl-1.dylib` – DustinB Jul 17 '12 at 14:14
0

In case you already have subversion installed I'd recommend performing first a brew uninstall and then the install again. And follow the steps to create the links indicated after the install concludes. This worked for me. Regards

Eduardo
  • 201
  • 2
  • 3
0

I fixed it installing the SVNKit Client Adapter (not required) package.

Alberto M
  • 1,608
  • 1
  • 18
  • 42
0

Here is a blog entry that gives a solution: http://blog.mattwoodward.com/getting-rid-of-subversion-native-library-not

I don't know whether this will work in your particular situation, but it's worth a try.

(Edited to fix link that became broken after I posted. The link became broken sometime between May 3 and June 1.)

mernst
  • 7,437
  • 30
  • 45
0

The easiest thing to do is download and install the OSX package that is provided on openCollabNet.

MacPorts also provides an easy Subversion and JavaHL package, however on Snow Leopard ?MacPorts is still compiling these packages as simple 32-bit binaries. If you use the default Snow Leopard JVM which is 64-bit you will get an error...

Failed to load JavaHL Library. These are the errors that were encountered:

no libsvnjavahl-1 in java.library.path
no svnjavahl-1 in java.library.path /opt/local/lib/libsvnjavahl-1.0.0.0.dylib: no suitable image found. Did find: /opt/local/lib/libsvnjavahl-1.0.0.0.dylib: mach-o, but wrong architecture

Note the error about wrong architecture. This is because the 64-bit JVM cannot load a 32-bit native library. The ?CollabNet binaries for OSX do not have this problem because they include both 32-bit and 64-bit versions.

Source: subclipse.tigris.org

April Smith
  • 1,810
  • 2
  • 28
  • 52