我正在尝试使用make在SLES 11.3 VM上构建git,但make失败并出现错误“cache.h:39:18:warning:zlib.h:没有这样的文件或目录”。
configure: creating ./config.status
config.status: creating config.mak.autogen
config.status: executing config.mak.autogen commands
linuxcli: bimaljha/git/git-master> make
* new build flags
CC credential-store.o
In file included from credential-store.c:1:
cache.h:39:18: warning: zlib.h: No such file or directory
In file included from credential-store.c:1:
cache.h:41: error: expected specifier-qualifier-list before 'z_stream'
make: *** [credential-store.o] Error 1
linuxcli: bimaljha/git/git-master>
我尝试以root身份安装zlib,但它已经是最新级别了。
linuxcli: /root> zypper install zlib
Loading repository data...
Reading installed packages...
'zlib' is already installed.
No update candidate for 'zlib-1.2.7-0.10.128.x86_64'. The highest available version is already installed.
Resolving package dependencies...
Nothing to do.
linuxcli: /root>
我在zlib.h
和/usr/include
下检查了/usr/local/include
,但没有zlib.h
个文件:
linuxcli: /usr/include> ls zlib*
ls: cannot access zlib*: No such file or directory
linuxcli: /usr/include> cd ../local/include
linuxcli: usr/local/include> ls zlib*
ls: cannot access zlib*: No such file or directory
linuxcli: usr/local/include>
如何到达或在哪里找到它?只有zypper
命令才能在我的系统上运行。感谢。
答案 0 :(得分:2)
我认为应该安装zlib-devel。
答案 1 :(得分:0)
您可以在zlib源代码包中找到zlib.h。头文件安装完成后,我尝试安装,但是没有成功...