hp-unix 编译openssh

在hp-unix上编译openssh,报错:

checking for deflate in -lz... no
configure: error: *** zlib missing - please install first or check config.log ***


查看config.log发现:

configure:10969: gcc -o conftest -g -O2 -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wno-pointer-sign -Wformat-security -fno-strict-aliasing -fno-builtin-memset -std=gnu9
9 -I/usr/local/include  -D_HPUX_SOURCE -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1 -L/usr/local/lib  conftest.c -lnsl -lxnet  -lsec -lz >&5
ld: Can't find library for -lz
Fatal error.


是编译时找不到libz.a,在网络上查了半天,要安装zlib1.2.3以上版本,但我这主机上已经装了1.2.8

ngapp-zjcbtst1%swlist |grep zlib
  zlib                          1.2.8          zlib


后来/usr下find了一下,在/usr/local/lib/hpux32/libz.a这个目录下有,link到/usr/local/lib下重新执行./configure通过

link /usr/local/lib/hpux32/libz.a libz.a

你可能感兴趣的:(unix,HP,openssh)