【转】Ubuntu下Subclipse报failed to load javahl library的解决办法
http://www.voland.com.cn/subclipse-under-ubuntu-report-failed-to-load-javahl-library-solution
安装Eclipse并安装Subclipse1.6x插件后,使用svn过程中报如下错误:
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
原来是缺少一些关联文件,去subclipse的Wiki看了看,说需要安装libsvn-java,在Ubuntu 下安装很简单,命令如下:
sudo apt-get install libsvn-java
安装完后,这文件在/usr/lib/jni目录下,这个目录并不是eclipse的java.library.path路径之一,所以还需要修改eclipse.ini来告诉eclipse去哪找这个libsvn-java相关的文件.
打开eclipse.ini,在最后行加入如下内容(注意换行)
-Djava.library.path=/usr/lib/jni