Centos6.8安装ncrack 报错undefined reference to `clock_gettime解决方案

错误:Centos6.8安装ncrack执行mak命令时遇到以下

opensshlib/libopenssh.a(misc.o): In function `monotime':

/root/Documents/ncrack-0.5/opensshlib/misc.c:922: undefined reference to `clock_gettime'
collect2: ld returned 1 exit status
make[1]: *** [ncrack] Error 1
make[1]: Leaving directory `/root/Documents/ncrack-0.5'

make: *** [all] Error 2


解决方案:

打开Makefile,找到LDFLAGS =,在这之后加入 -lrt,重新执行make, make install.


你可能感兴趣的:(Centos6.8安装ncrack 报错undefined reference to `clock_gettime解决方案)