背景

原来想在Linux机上开Samba共享,在Windows机上把工作目录映射到网络驱动器,用Source Insight编辑代码后就不用来回同步文件了。

然而在使用中发现,Windows机用的SVN客户端版本是1.9.4,而CentOS自带的版本是1.7.14。

用Windows更新过SVN Work Directory后,一不小心就更到了SVN1.8版格式(应该可以选不更新格式吧?)

这样弄完,Linux机上就无法使用SVN了(使用1.7版格式,提示客户端版本太旧)。

网上搜RPM包但是CentOS木有更新的版本了,无奈只好琢磨编译安装最新版!这样两个平台都用1.9版的,就应该没问题了!

环境

[root@min-base ~]# cat /etc/redhat-release
CentOS Linux release 7.2. (Core)

且是Minimal Install

安装

主要参考官网的安装说明,这里没有研究最小依赖安装环境,不过也挺小的了。

安装开发环境工具

[root@min-base ~]# yum -y groupinstall "Deveolpment tools"

这里也会把svn客户端安上,但是是1.7.14版本的,移除它

[root@min-base ~]# yum -y remove subversion

根据安装说明,这里需要几个依赖

安装依赖

[root@min-base ~]# yum -y install yum install python-devel zlib openssl openssl-devel file-libs libtool libtool-devel

查看版本

[root@min-base ~]# rpm -qa | grep autoconf
autoconf-2.69-.el7.noarch
[root@min-base ~]# rpm -qa | grep libtool
libtool-2.4.-.el7_2.x86_64
[root@min-base ~]# gcc --version
gcc (GCC) 4.8. (Red Hat 4.8.-)
Copyright (C) Free Software Foundation, Inc.

下载svn源码包

[root@min-base ~]# wget http://mirrors.tuna.tsinghua.edu.cn/apache/subversion/subversion-1.9.5.tar.gz
[root@min-base ~]# tar zxvf subversion-1.9..tar.gz
[root@min-base ~]# cd subversion-1.9.
[root@min-base subversion-1.9.]# ll
-rw-rw-r--. Mar aclocal.m4
-rwxrwxr-x. Jul autogen.sh
-rw-rw-r--. Feb BUGS
drwxrwxr-x. Nov : build
-rw-rw-r--. Jun build.conf
-rw-rw-r--. Nov : build-outputs.mk
-rw-rw-r--. Nov : CHANGES
-rw-rw-r--. Jan COMMITTERS
-rwxrwxr-x. Nov : configure
-rw-rw-r--. Nov : configure.ac
drwxrwxr-x. Nov : doc
-rw-rw-r--. Nov : gen-make.opts
-rwxrwxr-x. May gen-make.py
-rwxrwxr-x. Aug : get-deps.sh
-rw-rw-r--. Dec INSTALL
-rw-rw-r--. Jan LICENSE
-rw-rw-r--. Dec Makefile.in
-rw-rw-r--. Apr NOTICE
-rw-rw-r--. Jun README
drwxrwxr-x. Nov : subversion
drwxrwxr-x. Nov : tools
-rw-rw-r--. Dec win-tests.py

使用自带脚本下载svn依赖(前面加了===的为get-deps.sh脚本下载的依赖)

[root@min-base subversion-1.9.]# ./get-deps.sh
[root@min-base subversion-1.9.]# ll
-rw-rw-r--. Mar aclocal.m4
===drwxr-sr-x. Feb apr
===drwxr-xr-x. Sep apr-util
-rwxrwxr-x. Jul autogen.sh
-rw-rw-r--. Feb BUGS
drwxrwxr-x. Nov : build
-rw-rw-r--. Jun build.conf
-rw-rw-r--. Nov : build-outputs.mk
-rw-rw-r--. Nov : CHANGES
-rw-rw-r--. Jan COMMITTERS
-rwxrwxr-x. Nov : configure
-rw-rw-r--. Nov : configure.ac
drwxrwxr-x. Nov : doc
-rw-rw-r--. Nov : gen-make.opts
-rwxrwxr-x. May gen-make.py
-rwxrwxr-x. Aug : get-deps.sh
-rw-rw-r--. Dec INSTALL
-rw-rw-r--. Jan LICENSE
-rw-rw-r--. Dec Makefile.in
-rw-rw-r--. Apr NOTICE
-rw-rw-r--. Jun README
===drwxr-xr-x. games Oct serf
===drwxr-xr-x. root root Dec sqlite-amalgamation
drwxrwxr-x. Nov : subversion
drwxrwxr-x. Nov : tools
-rw-rw-r--. Dec win-tests.py
===drwxr-xr-x. games Apr zlib

下载serf构建工具

[root@min-base subversion-1.9.]# cd serf
[root@min-base serf]# wget http://prdownloads.sourceforge.net/scons/scons-local-2.3.0.tar.gz
[root@min-base serf]# tar zxvf scons-local-2.3..tar.gz

按照如下顺序安装

安装apr

[root@min-base ~]# cd ~/subversion-1.9./apr
[root@min-base apr]# ./buildconf
[root@min-base apr]# ./configure
[root@min-base apr]# make
[root@min-base apr]# make install

安装apr-util

[root@min-base ~]# cd ~/subversion-1.9./apr-util
[root@min-base apr-util]# ./buildconf
[root@min-base apr-util]# ./configure --with-apr=/usr/local/apr/bin/apr--config
[root@min-base apr-util]# make
[root@min-base apr-util]# make install

安装serf

[root@min-base ~]# cd ~/subversion-1.9./serf
[root@min-base serf]# ln -s /root/subversion-1.9./serf/scons.py /usr/local/bin/scons
[root@min-base serf]# scons APR=/usr/local/apr/bin/apr--config APU=/usr/local/apr/bin/apu--config OPENSSL=/usr PREFIX=/usr/local
[root@min-base serf]# scons install

安装svn-client

[root@min-base ~]# cd ~/subversion-1.9./
[root@min-base ~]# ./configure --with-serf=/usr/local --with-apr=/usr/local/apr/bin/apr--config --with-apr-util=/usr/local/apr/bin/apu--config
[root@min-base ~]# make
[root@min-base ~]# make install

使用

[root@min-base serf]# svn --version
svn, version 1.9. (r1770682)
compiled Jan , :: on x86_64-unknown-linux-gnu Copyright (C) The Apache Software Foundation.
This software consists of contributions made by many people;
see the NOTICE file for more information.
Subversion is open source software, see http://subversion.apache.org/ The following repository access (RA) modules are available: * ra_svn : Module for accessing a repository using the svn network protocol.
- handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
- handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
- using serf 1.3. (compiled with 1.3.)
- handles 'http' scheme
- handles 'https' scheme The following authentication credential caches are available: * Plaintext cache in /root/.subversion
* GPG-Agent

CentOS7.2 编译安装SVN1.9.5客户端的更多相关文章

  1. CentOS7下编译安装redis-5.0.9

    CentOS7下编译安装redis-5.0.9 本文地址http://yangjianyong.cn/?p=171转载无需经过作者本人授权 下载redis #code start wget https ...

  2. centos7.6编译安装php7.2.11及redis/memcached/rabbitmq/openssl/curl等常见扩展

    centos7.6编译安装php7..11及redis/memcached/rabbitmq/openssl/curl等常见扩展 获取Php的编译参数方法: [root@eus-api-cms-bac ...

  3. centos7下编译安装php-7.0.15(PHP-FPM)

    centos7下编译安装php-7.0.15(PHP-FPM) 一.下载php7源码包 http://php.net/downloads.php 如:php-7.0.15.tar.gz 二.安装所需依 ...

  4. Linux Centos7.2 编译安装PHP7.0.2

    操作环境: 1.系统:Centos7.2 2.服务:Nginx 1.下载PHP7.0.2的安装包解压,编译,安装: $ cd /usr/src/ $ wget http://cn2.php.net/d ...

  5. CentOS7.6编译安装openssl-1.1.1c

    卸载旧版本OpenSSL # which openssl/usr/bin/openssl# mv openssl openssl.oldrm -rf /etc/ssl #删除配置文件 CentOS7. ...

  6. CentOS7.6编译安装Python-3.7.4

    安装步骤 1. 下载安装包.wget https://www.python.org/ftp/python/3.7.4/Python-3.7.4.tgz<说明>如果报SSL/TSL错误,则加 ...

  7. CentOS7 下编译安装 Samba,什么是 SMB/CIFS 协议

    目录 一.关于 Samba 1. SMB 2. Samba 二.yum 安装 Samba 1. 安装 Samba 2. 查看版本 3. 查看配置文件 4. 启动服务 5. 本地客户端验证 6. Win ...

  8. CentOS6.3编译安装Memcached的PHP客户端memcache

    在安装Memcached的PHP客户端memcache之前,可先看下先前的工作笔记: PHP5不重新编译,如何安装自带的未安装过的扩展,如soap扩展? 安装PHP的memcache扩展 cd /us ...

  9. Centos7.2 编译安装PHP7

    PHP7,编译安装: 环境:centos7.2    (注意:因为我用的nginx, 此配置参数没有考虑到apache,所以不合适需要用apache的朋友照搬过去运行,但是可以参考.)   直接下载P ...

随机推荐

  1. 【leetcode】Climbing Stairs

    题目简述: You are climbing a stair case. It takes n steps to reach to the top. Each time you can either ...

  2. java单例模式详解

    饿汉法 饿汉法就是在第一次引用该类的时候就创建对象实例,而不管实际是否需要创建.代码如下: public class Singleton { private static Singleton = ne ...

  3. Difinition Of Done

    A Story is Sprint ready (Rally Defined) when............. The story has well defined and testable ac ...

  4. linux 限制root SSH登陆和限制su

    linux 限制root用户SSH登录:   1.修改SSHD服务的配置文件/etc/ssh/sshd_config    将#PermitRootLogin yes 改为PermitRootLogi ...

  5. [转] 传统 Ajax 已死,Fetch 永生

    原谅我做一次标题党,Ajax 不会死,传统 Ajax 指的是 XMLHttpRequest(XHR),未来现在已被 Fetch 替代. 最近把阿里一个千万级 PV 的数据产品全部由 jQuery 的  ...

  6. Struts2文件上传与下载

    一,页面 index.html 在页面中最重要的就是这个文件上传用的 form 表单,注意这里一定要把 form 的encyType属性明确标定为“multipart/form-data”,只有这样. ...

  7. CF #376 (Div. 2) C. dfs

    1.CF #376 (Div. 2)    C. Socks       dfs 2.题意:给袜子上色,使n天左右脚袜子都同样颜色. 3.总结:一开始用链表存图,一直TLE test 6 (1)如果需 ...

  8. http状态码详解

    1 网址协议不支持的协议. 2 检测器内部错误. 3 网址格式不正确. 5 无法连接到代理服务器. 6 无法连接到服务器或找不到域名. 7 连接服务器失败. 28 操作超时.可能原因:页面执行时间过长 ...

  9. [转]as3中的SharedObject的保存路径

    SharedObject的保存路径 Windows XP 网络访问: C:\Documents and Settings\[你的用户名]\Application Data\Macromedia\Fla ...

  10. 不能用con作为类名

    A class file was not written. The project may be inconsistent, if so try refreshing this project and ...