在Ubuntu 10.04.4 LTS上,我使用apt-get install
将git升级到1.8.1.1
现在我下载了git-1.8.1.5.tar.gz,并希望构建源代码来升级git
我在.bashrc中设置了$ PATH环境变量
export PATH=/usr/local:$PATH
我输入.bashrc,echo $ PATH显示设置路径'/ usr / local:/'
当我
make prefix=/usr/local all doc info
错误来了:
In file included from http.c:1:
http.h:6:23: warning: curl/curl.h: no such file or directory
http.h:7:23: warning: curl/easy.h: no such file or directory
In file included from http.c:1:
http.h:46: error: expected specifier-qualifier-list before ‘CURLcode’
http.h:51: error: expected specifier-qualifier-list before ‘CURL’
http.h:97: error: ‘CURL_ERROR_SIZE’ undeclared here (not in a function)
http.h: In function ‘missing__target’:
http.h:102: error: ‘CURLE_FILE_COULDNT_READ_FILE’ undeclared (first use in this function)
http.h:102: error: (Each undeclared identifier is reported only once
http.h:102: error: for each function it appears in.)
http.h:104: error: ‘CURLE_HTTP_NOT_FOUND’ undeclared (first use in this function)
任何人都可以帮我找到答案吗?
答案 0 :(得分:1)
要编译git
,您不仅需要curl
二进制文件,还需要开发包(我相信它在Ubuntu中称为libcurl-dev
或类似的东西),以及zlib
expat
和gettext
个开发包。要构建文档,您需要asccidoc
,makeinfo
,docbook2X
和dblatex
程序。
答案 1 :(得分:0)
vonbrand是对的(+1),这是他答案的补充。
在Red Hat Enterprise Linux Server 6.3版(圣地亚哥)上,我必须安装一些软件包才能编译git
1.8.3.3,1.8.3.4和1.8.4.rc0版本:
sudo yum install perl-ExtUtils-MakeMaker.x86_64
sudo yum install libcurl-devel.x86_64
sudo yum install expat-devel.x86_64