Centos7.X source code compilation and installation of subversion svn1.8.x tutorial

Source: Internet
Author: User
Tags bz2 sqlite svn zip

Reason

When I use vagrant for the development environment, the svn version on windows is 1.8.x, and the svn version in the centos7 Virtual Machine managed by vagrant is 1.7.x.

In this case, the svn version earlier cannot manage the repository managed by the svn version later. You need to upgrade the svn version to version 1.8.x.

In centos7.x official repository, the version of subversion (svn) is 1.7.x, and RepoForge is attempted. The EPEL third-party source is also the version of svn 1.7.x ~

So we need to compile and install svn1.8.x in the source code.

Description of dependent libraries required for installing svn

To support svn in centos7 linux, you need to package apr-util zlib serf.
Subversion1.8.x requires the application of the serf software package to support http and https access to the svn version Library
Scons is required for serf compilation and installation.
Therefore, zlib and scons are installed through yum. arp, apr-util, and serf are compiled and installed through source code.

You also need to update sqlite-amalgamation in the shell script.

Install shell

# Remove old svn versions and supported libraries
Yum-y remove apr-util subversion-libs

# Install svn dependent libraries
Yum install-y zlib scons
Wget https://dist.apache.org/repos/dist/release/apr/apr-1.5.1.tar.gz
Wget https://dist.apache.org/repos/dist/release/apr/apr-util-1.5.4.tar.gz
Tar zxvf apr-1.5.1.tar.gz
Cd apr-1.5.1
./Configure
Make & make install
Cd ..
Tar zxvf apr-util-1.5.4.tar.gz
Cd apr-util-1.5.4
./Configure -- with-apr =/usr/local/apr
Make & make install
Cd ..

Wget http://pkgs.fedoraproject.org/repo/pkgs/libserf/serf-1.3.3.tar.bz2/8375cf4fe2a89773c7d6dbf0d540ed27/serf-1.3.3.tar.bz2
Tar xjfv serf-1.3.3.tar.bz2
Cd serf-1.3.3
Scons PREFIX =/usr/local/serf APR =/usr/local/apr APU =/usr/local/apr
Scons install

# Copy the serf library file. Otherwise, the following error will be reported:
# Svn: error while loading shared libraries: libserf-1.so.1: cannot open shared object file: No such file or directory
Cp libserf-1.so */usr/local/lib/
Scons-c
Cd ..

# Install svn
Wget http://mirrors.cnnic.cn/apache/subversion/subversion-1.8.13.tar.gz
Tar zxvf subversion-1.8.13.tar.gz
Cd subversion-1.8.13
# Update sqlite
Wget http://www.sqlite.org/sqlite-amalgamation-3071501.zip
Unzip sqlite-amalgamation-3071501.zip
Mv sqlite-amalgamation-3071501 sqlite-amalgamation
./Configure -- with-apr =/usr/local/apr -- with-apr-util =/usr/local/apr -- with-serf =/usr/local/serf
Make & make install
Svn help

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.