美文网首页
SVN Server离线安装

SVN Server离线安装

作者: 米开朗基乐 | 来源:发表于2019-02-27 14:18 被阅读0次

    操作系统:Centos6.x(x86_64)

    #!/bin/bash
    # version
    APR_VERSION=apr-1.6.3
    APR_UTIL_VERSION=apr-util-1.6.1
    SVN_VERSION=subversion-1.10.0
    SQLITE_VERSION=sqlite-autoconf-3240000
    
    # download tar
    x_download (){
      export  DEPLOY_DIR=/home/svn
      [ -d ${DEPLOY_DIR} ] || mkdir -p ${DEPLOY_DIR}
      cd ${DEPLOY_DIR}
      wget -N -q https://archive.apache.org/dist/apr/${APR_VERSION}.tar.gz
      wget -N -q https://archive.apache.org/dist/apr/${APR_UTIL_VERSION}.tar.gz
      wget -N -q https://archive.apache.org/dist/subversion/${SVN_VERSION}.tar.gz
      wget -N -q https://sqlite.org/2018/${SQLITE_VERSION}.tar.gz
    }
    
    x_download 
    
    # install apr
    cd ${DEPLOY_DIR}
    tar -zxf apr-1.6.3.tar.gz
    cd apr-1.6.3
    ./configure --prefix=/home/svn/apr-1.6.3
    make && make install
    
    # install apr-util
    cd ${DEPLOY_DIR}
    tar -zxf apr-util-1.6.1.tar.gz
    cd apr-util-1.6.1
    ./configure --prefix=/home/svn/apr-util-1.6.1 --with-apr=/home/svn/apr-1.6.3
    make && make install
    #xml/apr_xml.c:35:19: error: expat.h: No such file or directory
    #should install 'expat-devel'
    
    # install svn
    cd ${DEPLOY_DIR}
    tar -zxf subversion-1.10.0.tar.gz
    ##install sqlite unzip >> subversion-1.10.0 the configure directory
    tar -zxf sqlite-autoconf-3240000.tar.gz -C /home/svn/subversion-1.10.0
    mv /home/svn/subversion-1.10.0/sqlite-autoconf-3240000 /home/svn/subversion-1.10.0/sqlite-amalgamation
    cd subversion-1.10.0
    ./configure --prefix=/home/svn/subversion-1.10.0 --with-apr=/home/svn/apr-1.6.3 --with-apr-util=/home/svn/apr-util-1.6.1 --with-lz4=internal --with-utf8proc=internal
    make && make install
    
    
    # add bashrc
    cat >> /etc/profile << EOF
    PATH=\$PATH:\$HOME/bin
    PATH=/home/svn/subversion-1.10.0/bin:\$PATH
    EOF
    
    source /etc/profile
    svn --version
    
    #http://www.linuxfromscratch.org/blfs/view/svn/general/subversion.html  --install svn
    #https://blog.csdn.net/roy_70/article/details/52166331  --install svn for centos tags ay
    #https://superuser.com/questions/929965/subversion-1-8-13-installation-without-root  --install svn for ubuntu no root
    #https://blog.csdn.net/huang930528/article/details/53761711  --install maven
    #http://www.21ic.com/app/mcu/201806/761465.htm  --arm linux
    #http://www.linuxfromscratch.org/blfs/view/svn/general/svnserver.html  --setting svn
    


    操作系统:银河麒麟(ARM)

    #!/bin/bash
    #install apr
    tar -zxf apr-1.6.3.tar.gz
    cd apr-1.6.3
    ./configure --prefix=/home/svn/apr-1.6.3
    make && make install
    
    #install apr-util
    tar -zxf apr-util-1.6.1.tar.gz
    cd apr-util-1.6.1
    ./configure --prefix=/home/svn/apr-util-1.6.1 --with-apr=/home/svn/apr-1.6.3
    make && make install
    #xml/apr_xml.c:35:19: error: expat.h: No such file or directory
    #should install 'expat-devel'
    
    #install svn
    tar -zxf subversion-1.10.0.tar.gz
    ##install sqlite unzip >> subversion-1.10.0 configure direcctiry
    tar -zxf sqlite-autoconf-3240000.tar.gz -C /home/svn/subversion-1.10.0
    mv /home/svn/subversion-1.10.0/sqlite-autoconf-3240000 /home/svn/subversion-1.10.0/sqlite-amalgamation
    cd subversion-1.10.0
    ./configure --prefix=/home/svn/subversion-1.10.0 --with-apr=/home/svn/apr-1.6.3 --with-apr-util=/home/svn/apr-util-1.6.1 --with-lz4=internal --with-utf8proc=internal
    make && make install
    
    #add bashrc
    cat >> /etc/profile << EOF
    PATH=\$PATH:\$HOME/bin
    PATH=/home/svn/subversion-1.10.0/bin:\$PATH
    EOF
    
    source /etc/profile
    svn --version
    
    #rc.local
    cat >> /etc/rc.local << EOF
    svnserve -d -r /home/kylin/svn/
    EOF
    
    #create xm
    svnadmin create /home/kylin/svn1.6.23/zbx
    
    
    #http://www.linuxfromscratch.org/blfs/view/svn/general/subversion.html  --install svn
    #https://blog.csdn.net/roy_70/article/details/52166331  --install svn for centos tags ay
    #https://superuser.com/questions/929965/subversion-1-8-13-installation-without-root  --install svn for ubuntu no root
    #https://blog.csdn.net/huang930528/article/details/53761711  --install maven
    #http://www.21ic.com/app/mcu/201806/761465.htm  --arm linux
    
    #add svn 1.6.23 && apr-1.2.12 && apr-util-1.2.12
    
    #
    #apr ./configure --prefix=/home/kylin/svn1.6.23/apr-1.2.12 --build=arm-linux && make && make install
    #./configure --prefix=/home/kylin/svn1.6.23/apr-util-1.2.12 --with-apr=/home/kylin/svn1.6.23/apr-1.2.12 --build=arm-linux && make && make install
    #./configure --prefix=/home/kylin/svn1.6.23/subversion-1.6.23 --with-apr=/home/kylin/svn1.6.23/apr-1.2.12 --with-apr-util=/home/kylin/svn1.6.23/apr-util-1.2.12 --build=arm-linux && make && make install
    #
    

    相关文章

      网友评论

          本文标题:SVN Server离线安装

          本文链接:https://www.haomeiwen.com/subject/zhuaeftx.html