星期一, 7月 07, 2008

subversion 1.5

最近工作需要又要另外安裝一台Subversion Server for linux,
發現Subversion原始碼不久前升級至1.5版,
1.4->1.5版最大不同在merge專案時有更詳細的紀錄.

於是今天早上就忙著裝安裝新版的Subversion Server為新的專案做準備.

安裝Subversion所需的套件及過程:
=======================
1.依subversion說明需要autoconf 2.58 or laster,libtool 1.4 or later.
檢查系統環境libz 1.2.1,autoconf 2.59,libtool 1.5.6,gcc 3.4.6符合條件.

2.收集expat 2.0.1,libxml2 2.6.32,neon 0.28.2,apache2 2.2.9,swig 1.3.31,python 2.4.5.

3.安裝python,swig.
python安裝時設定指令:
./configure --prefix=[path]
make;make test;make install

swig安裝時設定指令:
./configure --prefix=[path] --with-python=[path] --enable-static=yes
make;make install

4.安裝expat,libxml2,neon
expat安裝時設定指令:
./configure --prefix=[path] --enable-shared --with-gnu-ld=yes
make;make install

libxml2安裝時設定指令:
./configure --prefix=[path] --with-python=[path] --with-zlib=[path]
make;make install

neon安裝時設定指令:
./configure --prefix=[path] --with-libs=[path] --enable-shared --with-libxml2 --with-expat
make;make install

5.安裝apache2
apache2安裝時設定指令:
cd [path_apache2_src]/srclib/apr
./configure --prefix=[path]
make;make install
cd ../apr-util
./configure --prefix=[path] --with-apr=../apr --with-expat=[path]
make;make install
cd ../..
./configure --prefix=[path] --enable-mods=all --with-apr=srclib/apr --with-apr-util=srclib/apr-util
make;make install

6.安裝subversion
./configure --prefix=[path] --with-swig=[path] --with-neon=[path] --with-apxs=[path]/bin/apaxs --with-apr=[path]/bin/apr-1-config --with-apr-util=[path]/bin/apu-1-config --with-zlib
make;make install
=======================

設定專案及專案成員方法:
=======================
1.利用htpasswd建立svn-auth-file
2.設定accesscontrol.conf
[groups]
proj1-developers = john,mary

[proj1:/]
@proj-developers = rw

3. httpd.conf尾端加上以下設定
<Location /repos>
DAV svn
SVNParentPath [repos_path]
AuthzSVNAccessFile [path]/accesscontrol.conf
Require valid-user
AuthType Basic
AuthName "Subversion repository"
AuthUserFile [path]/svn-auth-file
</Location>

4. [path]/bin/svnadmin create proj1 --fs-type fsfs
=======================

沒有留言: