S.l.e!ep.¢%

像打了激速一样,以四倍的速度运转,开心的工作
简单、开放、平等的公司文化;尊重个性、自由与个人价值;
posts - 1098, comments - 335, trackbacks - 0, articles - 1
  C++博客 :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理

svn安装

Posted on 2012-01-28 16:26 S.l.e!ep.¢% 阅读(972) 评论(0)  编辑 收藏 引用 所属分类: Unix
SVN安装 由于系统是RHEL4.7 于是决定编译安装SVN 1)安装BerkeleyDB http://www.oracle.com/technology/software/products/berkeley-db/db/index.html下载地址 [root@localhost ~]# cd db-4.7.25/build_unix/ [root@localhost build_unix]# ../dist/configure --prefix=/usr/local/BerkeleyDB&& make && make install [root@localhost build_unix]# mv /usr/include/db4 /usr/inculde/db4.OFF [root@localhost build_unix]# rm -rf /usr/include/db_cxx.h /usr/include/db.h /usr/include/db_185.h [root@localhost build_unix]# ln -sv /usr/local/BerkeleyDB/include /usr/include/db4 [root@localhost build_unix]# ln -sv /usr/local/BerkeleyDB/include/db.h /usr/include/db.h [root@localhost build_unix]# ln -sv /usr/local/BerkeleyDB/include/db_cxx.h /usr/include/db_cxx.h 配置库文件搜索路径 [root@localhost build_unix]# echo "/usr/local/BerkeleyDB/lib" >> /etc/ld.so.conf [root@localhost build_unix]# ldconfig -v 2)安装apr http://www.apache.org/ 下载apr apr-util httpd tar zxvf apr-1.4.2.tar.gz cd apr-1.4.2 ./configure --prefix=/usr/local/apr &&make && make install tar jxvf apr-util-1.3.9.tar.bz2 cd apr-util-1.3.9 3)安装apr-util ./configure --prefix=/usr/local/apr/ --with-apr=/usr/local/apr/ --with-berkeley-db=/usr/local/BerkeleyDB/ && make && make install tar zxvf httpd-2.2.15.tar.gz cd httpd-2.2.15 4)安装apache ./configure --prefix=/usr/local/apache --with-included-apr --with-apr-util=/usr/local/apr/ --enable-dav --enable-so make make install 5)sqlite安装 sqlite下载 http://www.sqlite.org/sqlite-amalgamation-3.6.13.tar.gz cd sqlite-3.6.13/ ./configure --prefix=/usr/local/sqlite && make && make install 6)subversion安装 ./configure --prefix=/usr/local/svn --with-apr-util=/usr/local/apr/ --with-apr=/usr/local/apache/ --with-apr=/usr/local/apr/ --with-apxs=/usr/local/apache/bin/apxs --with-sqlite=/usr/local/sqlite/ --with-berkeley-db make make install 7)环境变量配置 在/etc/profile下面加入 PATH="$PATH:/usr/local/apr/bin/:/usr/local/apache/bin/:/usr/local/svn/bin/" 8)svn使用 svnadmin create /usr/local/svn/game 在/usr/local/apache/conf/httpd.conf中加入: DAV svn SVNPath /usr/local/svn/game svnadmin create /usr/local/svn/game svn import cfengine-3.0.3 file:///usr/local/svn/game/ -m "Initial import" svn使用看下面链接 http://bill-sbia.javaeye.com/blog/172973 http://blog.chinaunix.net/u/33048/showart_2079175.html http://blog.csdn.net/haru/archive/2009/03/16/3996152.aspx svn: None of the environment variables SVN_EDITOR, VISUAL or EDITOR are set, and no 'editor-cmd' run-time configuration option was found 安装过程中的部分错误信息。。。。。。。。。 apache安装报错: 使用./configure --prefix=/usr/local/apache --with-apr=/usr/local/apr/ --with-apr-util=/usr/local/apr/ --enable-so时 加上 --with-included-apr 选项即可解决下面错误 “exports.c:1653: error: redefinition of 'ap_hack_apr_version_string' exports.c:1022: error: previous definition of 'ap_hack_apr_version_string' was here make[2]: *** [exports.lo] Error 1 make[2]: Leaving directory `/usr/local/src/httpd-2.2.*/server' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/usr/local/src/httpd-2.2.*/server' make: *** [all-recursive] Error 1” subversion安装报错: 解决办法在安装apr-util时加上--with-berkeley-db=选项 checking for socket in -lsocket... no configure: error: APR-UTIL wasn't linked against Berkeley DB 4, while the fs component is required. Reinstall APR-UTIL with the appropiate options. ./configure --prefix=/usr/local/svn --with-apr-util=/usr/local/apr --with-apr=/usr/local/apache/ --with-berkeley-db subversion make时报错,由于未指定apxs与apr路径,可能是由于apr呵呵未再次确认 *** [subversion/libsvn_fs_base/bdb/bdb-err.lo] Error 1 启动apache报错是因为apache安装时没有--enable-dav --enable-so [root@jx80 svn]# apachectl start httpd: Syntax error on line 53 of /usr/local/apache/conf/httpd.conf: Cannot load /usr/local/apache/modules/mod_dav_svn.so into server: /usr/local/svn/lib/libsvn_subr-1.so.0: undefined symbol: sqlite3_config [root@jx80 apr-1.4.2]# svn import file:///usr/local/svn/game/ sh: vi: command not found svn: system('vm svn-commit.tmp') returned 32512 更改vi /root/.subversion/config 去掉下面的#号前面不能有空格否则会报svn: /root/.subversion/config:45: Option expected editor-cmd = editor (vi, emacs, notepad, etc.) [root@jx80 cfengine-3.0.3]# svn import file:///usr/local/svn/game/ sh: vi: command not found svn: system('vi svn-commit.tmp') returned 32512 解决在vi /root/.bashrc加入并source下 export SVN_EDITOR=vi ./config --prefix=/usr/locol/ssl --openssldir=/usr/local/ssl/ -fPIC no-shared ./configure --prefix=/usr/local/svn --with-apr-util=/usr/local/apr/ --with-apr=/usr/local/apache/ --with-apr=/usr/local/apr/ --with-apxs=/usr/local/apache/bin/apxs --with-sqlite=/usr/local/sqlite/ --with-berkeley-db --with-openssl=/usr/local/ssl --without-serf

只有注册用户登录后才能发表评论。
网站导航: 博客园   IT新闻   BlogJava   知识库   博问   管理