在Mac下安装Eclipse插件svnEclipse插件后,每次打开Eclipse都会弹出如下弹出框:
提示你本机缺少JavaHL Library。
选择Eclipse→偏好设置(preference)→Team→SVN,可以看到SVN接口Client的定义如下:
这说明当前系统中缺少JavaHL,需要我们手动安装。
subeclipse官网(http://subclipse.tigris.org/wiki/JavaHL 打开可能会非常慢)给出的介绍说有两种方式可以在Mac电脑上(OS X)上安装JavaHL Library,一种是通过MacPort,一种是通过HomeBrew的形式。如图所示:
这里我们主要介绍使用HomeBrew实行安装。
步骤1:安装HomeBrew:
HomeBrew的安装需要依赖XCode和Commond Line,具体的安装步骤如下:
HomeBrew的安装过程介绍网上也有很多教程,比如:
http://brew.sh/ --官网
http://www.jb51.net/os/MAC/101860.html
http://www.cnblogs.com/liulipeng/p/3938518.html
就不更多介绍了,如果安装过程遇到了问题,百度下基本都能解决的。
步骤2:执行命令,安装JavaHL
进入终端,键入如下命令:
brew install --universal --java subversion
但是会遇到如下问题,提示有个包下不到,原因你懂得,被墙了。
==> Downloading https://www.apache.org/dyn/closer.cgi?path=subversion/subversion
Already downloaded: /Library/Caches/Homebrew/subversion-1.8.13.tar.bz2
==> Patching
patching file configure
Hunk #1 succeeded at 25386 (offset 20 lines).
patching file subversion/bindings/swig/perl/native/Makefile.PL.in
==> Downloading https://serf.googlecode.com/svn/src_releases/serf-1.3.8.tar.bz2
curl: (7) Failed to connect to serf.googlecode.com port 443: Operation timed out
Error: Failed to download resource "subversion--serf"
Download failed: https://serf.googlecode.com/svn/src_releases/serf-1.3.8.tar.bz2
这个问题也有解决的办法,那就是下载对应的包,放在对应的目录下,这样就能再安装JavaHL的过程中跳过serf-1.3.8.tar.bz2的下载了。
步骤2.1:下载serf-1.3.8.tar.bz2包:
http://download.csdn.net/detail/shanwenchao/8653245
下载后放在任意目录,将名称修改为:subversion--serf-1.3.7.tar.bz2
步骤2.2:将改名后的该文件放在目录下:
将修改后的文件放在/Library/Caches/Homebrew目录下。
步骤2.3:重新执行安装命令,安装JavaHL:
brew install --universal --java subversion
这是就不会下载而是直接从文件目录中取该包了。如下过程:
brew install --universal --java subversion Warning: subversion: --java was deprecated; using --with-java instead! ==> Downloading https://www.apache.org/dyn/closer.cgi?path=subversion/subversion Already downloaded: /Library/Caches/Homebrew/subversion-1.8.13.tar.bz2 ==> Patching patching file configure Hunk #1 succeeded at 25386 (offset 20 lines). patching file subversion/bindings/swig/perl/native/Makefile.PL.in ==> Downloading https://serf.googlecode.com/svn/src_releases/serf-1.3.8.tar.bz2 Already downloaded: /Library/Caches/Homebrew/subversion--serf-1.3.8.tar.bz2 ==> /usr/local/opt/scons/bin/scons PREFIX=/usr/local/Cellar/subversion/1.8.13/li ==> /usr/local/opt/scons/bin/scons install ==> ./configure --prefix=/usr/local/Cellar/subversion/1.8.13 --with-zlib=/usr --with-sqlite=/usr/local/opt/sqlite --with-serf=/usr/local/Cellar/subversion/1.8.13/libexec/serf --disa ==> make ==> make install ==> make tools ==> make install-tools ==> make javahl ==> make install-javahl ==> Caveats svntools have been installed to: /usr/local/opt/subversion/libexec 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 Bash completion has been installed to: /usr/local/etc/bash_completion.d ==> Summary
推荐阅读
- Ubuntu18.04安装RabbitMQ
- MongoDB-管道与聚合(3)
- flutter Scaffold添加ScaffoldStateKey 导致TextField 键盘弹起后马上收回的问题
- 配置.bash_profile文件 导致大量命令失效 报错信息-bash: xxx: command not found
- iOS 集成flutter module 不使用cocoapods
- Flutter Future 异步 FutureBuilder 获取数据后 加载Widget
- Java学习 第四章 java面向对象(一)
- iOS 折线图、柱状图、扇形图封装
- git修改已push的commit信息
- RunTime 方法交换 NSURL 空值处理