test32.c:(.text+0x117): undefined reference to `inflateInit2_'
test32.c:(.text+0x177): undefined reference to `inflate'
test32.c:(.text+0x1e2): undefined reference to `inflateEnd'
collect2: ld returned 1 exit status
今天再次运行以前的libnids的http协议还原程序,结果出现inflateInit2没有定义的错误。解决方法是:加上-lz。
gcc test32.c -o test32 -lnet -lpcap -lnids -lz