为了账号安全,请及时绑定邮箱和手机立即绑定

报错/opt/download/hping-master/main.c:190: undefined reference to `hping_script'

OS:CENTOS6.6

[root@Security hping-master]# ./configure

build byteorder.c...

create byteorder.h...

./configure: line 81: -: command not found

--------------------------------------

system type: LINUX


LIBPCAP      : PCAP=-lpcap

PCAP_INCLUDE : 

MANPATH      : /usr/local/man

USE_TCL      : -DUSE_TCL

TCL_VER      : 

TCL_INC      : 

LIBTCL       : -ltcl -lm -lpthread

TCLSH        : 


(to modify try configure --help)

--------------------------------------

creating Makefile...

creating dependences...

now you can try `make'

[root@Security hping-master]# make

gcc -c -O2 -Wall   -DUSE_TCL -g  main.c

gcc -c -O2 -Wall   -DUSE_TCL -g  getifname.c

getifname.c: In function ‘get_if_name’:

getifname.c:61: warning: ‘sa.sin_addr.s_addr’ may be used uninitialized in this function

gcc -c -O2 -Wall   -DUSE_TCL -g  getlhs.c

gcc -c -O2 -Wall   -DUSE_TCL -g  parseoptions.c

gcc -c -O2 -Wall   -DUSE_TCL -g  datafiller.c

gcc -c -O2 -Wall   -DUSE_TCL -g  datahandler.c

gcc -c -O2 -Wall   -DUSE_TCL -g  binding.c

gcc -c -O2 -Wall   -DUSE_TCL -g  logicmp.c

gcc -c -O2 -Wall   -DUSE_TCL -g  waitpacket.c

gcc -c -O2 -Wall   -DUSE_TCL -g  sendip.c

gcc -c -O2 -Wall   -DUSE_TCL -g  sendicmp.c

gcc -c -O2 -Wall   -DUSE_TCL -g  sendudp.c

gcc -c -O2 -Wall   -DUSE_TCL -g  sendtcp.c

gcc -c -O2 -Wall   -DUSE_TCL -g  cksum.c

gcc -c -O2 -Wall   -DUSE_TCL -g  statistics.c

gcc -c -O2 -Wall   -DUSE_TCL -g  version.c

gcc -c -O2 -Wall   -DUSE_TCL -g  listen.c

gcc -c -O2 -Wall   -DUSE_TCL -g  sendhcmp.c

gcc -c -O2 -Wall   -DUSE_TCL -g  rtt.c

gcc -c -O2 -Wall   -DUSE_TCL -g  relid.c

gcc -c -O2 -Wall   -DUSE_TCL -g  sendip_handler.c

gcc -c -O2 -Wall   -DUSE_TCL -g  libpcap_stuff.c

gcc -c -O2 -Wall   -DUSE_TCL -g  ip_opt_build.c

gcc -c -O2 -Wall   -DUSE_TCL -g  display_ipopt.c

gcc -c -O2 -Wall   -DUSE_TCL -g  sendrawip.c

gcc -c -O2 -Wall   -DUSE_TCL -g  send.c

gcc -c -O2 -Wall   -DUSE_TCL -g  arsglue.c

gcc -c -O2 -Wall   -DUSE_TCL -g  scan.c

gcc -c -O2 -Wall   -DUSE_TCL -g  ars.c

ars.c: In function ‘ars_multi_cksum’:

ars.c:485: warning: comparison with string literal results in unspecified behavior

gcc -c -O2 -Wall   -DUSE_TCL -g  apd.c

gcc -c -O2 -Wall   -DUSE_TCL -g  split.c

gcc -c -O2 -Wall   -DUSE_TCL -g  rapd.c

gcc -o hping3 -O2 -Wall   -DUSE_TCL -g main.o getifname.o getlhs.o parseoptions.o datafiller.o datahandler.o gethostname.o binding.o getusec.o opensockraw.o logicmp.o waitpacket.o resolve.o sendip.o sendicmp.o sendudp.o sendtcp.o cksum.o statistics.o usage.o version.o antigetopt.o sockopt.o listen.o sendhcmp.o memstr.o rtt.o relid.o sendip_handler.o libpcap_stuff.o memlockall.o memunlockall.o memlock.o memunlock.o ip_opt_build.o display_ipopt.o sendrawip.o signal.o send.o strlcpy.o arsglue.o random.o scan.o hstring.o script.o interface.o adbuf.o hex.o apdutils.o sbignum.o sbignum-tables.o ars.o apd.o split.o rapd.o -L/usr/local/lib -lpcap  -ltcl -lm -lpthread

main.o: In function `main':

/opt/download/hping-master/main.c:190: undefined reference to `hping_script'

collect2: ld returned 1 exit status

make: *** [hping3] Error 1


正在回答

4 回答

第一步 删除 ,解压包 

rm -fr hping-master/

第二步:  重新解压, unzip   (yum install  -y unzip)

unzip master.zip

第三步: 

yum install  -y   libpcap-devel

yum install  -y   tcl tcl-devel

第四步: cd 到解压目录

cd hping-master/

第五步:  

./configure

make

make strip

make install

预祝你能成功, 如果还不行,欢迎追问.

1 回复 有任何疑惑可以回复我~
#1

怀恋Allen

果然是的,感谢
2016-12-23 回复 有任何疑惑可以回复我~

执行 make clean 

在执行 make  试试

0 回复 有任何疑惑可以回复我~

我也遇到这个问题了?求解?

0 回复 有任何疑惑可以回复我~

我也遇到这个问题了 请问楼主现在解决了吗?

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

报错/opt/download/hping-master/main.c:190: undefined reference to `hping_script'

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信