Centos 5.5 64位,編譯安裝Subversion1.7

來源:互聯網
上載者:User

裝了兩天的Subversion!!!!啊呀呀,要瘋啊~我用同樣的版本:

    subversion-1.7.2.tar.gz
    subversion-deps-1.6.1.tar.gz

之前這兩個版本的檔案,我在Ubuntu12.04 amd64 下編譯安裝成功過。可是,到了這裡,apr、apr-util、sqlite3.c、serf的Configure都過了,但在編譯的時候就報如下錯誤:

    1. serf can not find -lexpat
    2. subversion serf make deflate context_t

一路狂Google啊,還是沒有解法…好失落的!!!唉,想著也沒什麼進度,也就換裝了其它兩個工具軟體:tmux、Vim73。這兩個裝的還是比較愉快,雖然中途tmux也報了如:

    Not found libevent

這樣的錯誤,不過到官網下一個libevent-2.0.19-stable.tar.gz,裝完就搞定了~看了下時間,晚上還有分享會就沒繼續弄…明天再說~
一大早我就醒了,怎麼也想不通,昨天試了N次也沒有成功,於是一大早換了換思路,咱去官網整個最新版本的:

    #wget http://labs.mop.com/apache-mirror/subversion/subversion-1.7.5.tar.gz
    #wget http://subversion.tigris.org/downloads/subversion-deps-1.6.18.tar.gz

然後再接著解開兩個包,把deps裡的apr, apr-utl…都移到subversion1.7.5目錄下,先還是試了一下,跟之前一樣的安裝步驟:

    #cd subversion 1.7.5
    #./configure --prefix=/usr/local/subversion --with-openssl=/usr/local/openssl --with-zlib=/usr/local/zlib

這之前已經把“openssl”跟“zlib”安裝到了
/usr/local
下,所以這裡就直接用了。可還是沒有成功

    #./configure ....
    ....
    ok
    #make
    ....
    make deflate context_t not find.

後面我覺得我得試一試一個個的安裝,然後就分別跑到apr、apr-util裡安裝了個遍,並且把serf給扔掉了,操作如下:

    #cd subversion 1.7.5
    #cd apr
    #./configure --prefix=/usr/loca/apr
    ....
    ok
    #make
    ....
    make leave .....
    #make install
    install ok
    #cd ..
    #cd apr-util
    #./configure --with-apr=/usr/local/apr --prefix=/usr/local/apr-util
    ....
    config create : Makefile
    ...
    #make
    ....
    make leave ...
    #make install
    ok
    #cd ..
    #./configure --prefix=/usr/local/subversion --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util --without-serf --with-openssl=/usr/local/openssl
    ....
    configure create: Makefile
    ......
    #make
    o checking zlib.h presence ... no checking zlib.h

杯具… T_T,還是有問題。後面在網上找了下看到了需要執行這麼一條命令:

    #cd zlib
    #./configure --shared

意思是可以共用的寫資料安裝。趕緊執行了上面的操作再回到subversion 1.7.5

    #cd subversion 1.7.5
    #make clean
    ....
    #./configure .....
    .....
    configure create: Makefile
    ...
    #make
    ....
    1 分鐘過去了還在編譯中....
    make leave...
    #make install
    ......

終於成功了….尼瑪,原來需要這樣?要瘋啊!!!

    [root@xyrj-server bin]# svn --version
    svn,版本 1.7.5 (r1336830)
    編譯於 Jul 22 2012,10:23:32
    
    著作權 (C) 2012 Apache 軟體基金會。
    此軟體包含了許多人的貢獻,請查看檔案 NOTICE 以獲得更多資訊。
    Subversion 是開放原始碼軟體,請參閱 http://subversion.apache.org/ 網站。
    
    可使用以下的版本庫訪問模組:
    
    * ra_svn : 使用 svn 網路通訊協定訪問版本庫的模組。
    - 處理“svn”方案
    * ra_local : 訪問本地磁碟的版本庫模組。
    - 處理“file”方案

總結:Linux下的軟體編譯安裝,你得去親身經曆,光覺得可以那是不靠譜滴說~啊哈

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.