Linux系统中安装subversion1.9.9步骤

本文详细介绍了Subversion (SVN) 在Linux环境下的安装过程,包括必要的依赖库如apr、zlib、openssl等的安装步骤,并说明了如何通过serf支持HTTP协议。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

一、下载:

1.subversion-1.9.9.tar.gz

2.openssl-1.1.0h.tar.gz

3.zlib-1.2.11.tar.gz

4.sqlite-amalgamation-3071501.zip

5.Python-3.5.0.tar.xz

6.pcre-8.42.tar.gz

7.apr-util-1.6.1.tar.gz

8.apr-1.6.3.tar.gz

9.scons-3.0.1.tar.gz

10.serf-1.3.9.tar.gz

二、安装

1.安装apr,按顺序执行

#tar -xzvf apr-1.6.3.tar.gz

#cd apr-1.6.3

#./configure --prefix=/opt/apr

#make && make install

2.安装apr-util,按顺序执行

#tar -xzvf apr-util-1.6.1.tar.gz
#cd apr-util-1.5.4
#./configure --prefix=/opt/apr-util --with-apr=/opt/apr
#make && make install

3.安装zlib

#tar -xzvf zlib-1.2.11.tar.gz

#cd zlib-1.2.11

#./configure

#make && make install

4.安装openssl

#cd openssl-1.1.0h

#./config shared zlib  --prefix=/opt/openssl 

#make && make install

##安装结束后执行以下命令

#./config -t

#make depend

进入/opt目录下,执行以下命令

ln -s openssl ssl

在/etc/ld.so.conf文件的最后面,添加如下内容:/opt/openssl/lib 
然后执行以下命令

ldconfig

##检查openssl是否安装成功
#openssl version -a

添加OPESSL的环境变量,在etc/profile的最后一行,添加:

export OPENSSL=/opt/openssl/bin

export PATH=$OPENSSL:$PATH:$HOME/bin

保存后执行:

source etc/profile

查看是否成功:

echo $PATH

5.安装sqlite

#./configure --prefix=/usr/local/sqlite

#make && make install

6.SVN1.8版本以后需要serf软件包来支持访问http协议的版本库,不然会报svn: E170000: Unrecognized URL scheme for ''的错误,而serf需要使用scons来编译安装,安装scons需要先安装python

(1)安装python

#tar -xzvf Python-3.5.0.tar.xz

#cd Python-3.5.0

#./configure --prefix=/opt/python3

#make && make install

(2)安装scons

#tar -xzvf scons-3.0.1.tar.gz
#cd scons-3.0.1
#python setup.py install --prefix=/opt/scons

(3)安装serf

#cd serf-1.3.9
#scons PREFIX=/opt/serf APR=/opt/apr APU=/opt/apr-util OPENSSL=/opt/openssl
#scons install
 

7.安装subversion

#tar -xzvf subversion-1.9.9.tar.gz

#cd subversion-1.9.9

#./configure --prefix=/opt/subversion --with-apr=/opt/apr --with-apr-util=/opt/apr-util --with-zlib --with-openssl=/opt/openssl --enable-maintainer-mode --with-serf=/opt/serf --enable-mod-activation

#make && make install

修改环境变量:
# vim /etc/profile
# svnserve --version
出现如下:

svnserve, version 1.9.9 (r1835931)
   compiled Aug  2 2018, 17:47:34 on x86_64-unknown-linux-gnu

Copyright (C) 2018 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 back-end (FS) modules are available:

* fs_fs : Module for working with a plain file (FSFS) repository.
* fs_x : Module for working with an experimental (FSX) repository.

 

启动服务器:
# svnserve -d -r /home/svn

 

 

评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值