CENTOS的GIT安装及使用

时间:2022-01-05 10:13:34

    最近玩Linux的移植的时候怎么都下载不了最新的GIT,在大名鼎鼎的www.kernel.org里面也只有0.99最新的,应该是我没有找对位置!没办法,一番搜索,在我的CENTOS上可以这么解决:

//先安装git依赖的包 
yuminstall zlib-devel 
yuminstall openssl-devel 
yuminstall perl 
yuminstall cpio 
yuminstall expat-devel 
yuminstall gettext-devel 


//安装autoconf 
yuminstall autoconf 

//安装git 
wgethttp://www.codemonkey.org.uk/projects/git-snapshots/git/git-latest.tar.gz 
tarxzvf git-latest.tar.gz 
cdgit-{date} 
autoconf 
./configure--with-curl=/usr/local 
make 

make install


好了,执行git --version,看见

CENTOS的GIT安装及使用

说明安装成功了,一般来说,我们下载GIT是用来下载一些源代码的,比如说下载YAFFS2,就可以:

git  clone git://www.aleph1.co.uk/yaffs2 

这样就能得到最新的yaffs2的源码了!