Compile error on debian
Opened this issue · 0 comments
Linux VM 4.19.0-6-amd64 #1 SMP Debian 4.19.67-2 (2019-08-28) x86_64 GNU/Linux
make[2]: Leaving directory '/root/sft/pbscan-master/123/libuinet/bin/multitool'
make[2]: Entering directory '/root/sft/pbscan-master/123/libuinet/bin/tproxy'
cc -I/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libev -O -gdwarf-2 -I/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libuinet/api_include -c -o tproxy.o tproxy.c
In file included from /root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libuinet/api_include/uinet_api.h:36,
from tproxy.c:36:
/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libuinet/api_include/uinet_api_types.h:556:2: error: unknown type name 'uintptr_t'
uintptr_t ref;
^~~~~~~~~
make[2]: *** [: tproxy.o] Error 1
make[2]: Leaving directory '/root/sft/pbscan-master/123/libuinet/bin/tproxy'
make[1]: *** [Makefile:13: all] Error 2
make[1]: Leaving directory '/root/sft/pbscan-master/123/libuinet/bin'
make: *** [Makefile:10: all] Error 2
I found there are many error.
libhttp parser is also can't compile. I updated it with new version(I just copy .a file into folder and error disappeared) but libuinet show error!!!
/root/sft/pbscan-master/123/libuinet/lib/libuinet/../../sys/kern/vnode_if.src(451): Missing end-of-line ; in " IN struct task *task; ".
make: *** [Makefile:484: vnode_if.h] Error 1
libuinet_memstat
memstat_malloc.c:31:10: fatal error: sys/malloc.h: No such file or directory
#include <sys/malloc.h>
^~~~~~~~~~~~~~
compilation terminated.
make: *** [: memstat_malloc.o] Error 1
libuinetnv
In file included from /usr/include/x86_64-linux-gnu/sys/socket.h:33,
from msgio.c:37:
msgio.c: In function 'cred_send':
msgio.c:166:42: error: invalid application of 'sizeof' to incomplete type 'struct cmsgcred'
unsigned char credbuf[CMSG_SPACE(sizeof(struct cmsgcred))];
^~~~~~
msgio.c:193:35: error: invalid application of 'sizeof' to incomplete type 'struct cmsgcred'
cmsg->cmsg_len = CMSG_LEN(sizeof(struct cmsgcred));
^~~~~~
msgio.c:195:20: error: 'SCM_CREDS' undeclared (first use in this function); did you mean 'SOL_RDS'?
cmsg->cmsg_type = SCM_CREDS;
^~~~~~~~~
SOL_RDS
msgio.c:195:20: note: each undeclared identifier is reported only once for each function it appears in
In file included from /usr/include/x86_64-linux-gnu/sys/socket.h:33,
from msgio.c:37:
msgio.c: In function 'cred_recv':
msgio.c:206:42: error: invalid application of 'sizeof' to incomplete type 'struct cmsgcred'
unsigned char credbuf[CMSG_SPACE(sizeof(struct cmsgcred))];
^~~~~~
msgio.c:229:40: error: invalid application of 'sizeof' to incomplete type 'struct cmsgcred'
cmsg->cmsg_len != CMSG_LEN(sizeof(struct cmsgcred)) ||
^~~~~~
msgio.c:230:59: error: 'SCM_CREDS' undeclared (first use in this function); did you mean 'SOL_RDS'?
cmsg->cmsg_level != SOL_SOCKET || cmsg->cmsg_type != SCM_CREDS) {
^~~~~~~~~
SOL_RDS
msgio.c:234:38: error: dereferencing pointer to incomplete type 'struct cmsgcre '
bcopy(CMSG_DATA(cmsg), cred, sizeof(*cred));
^~~~~
make: *** [: msgio.o] Error 1
2019-09-20 15:07:31
I used #34 and #37
But none of them work.
Error changed to
make[2]: *** [: echo++.o] Error 1
make[2]: Leaving directory '/root/sft/pbscan-master/123/libuinet/bin/echo++'
make[2]: Entering directory '/root/sft/pbscan-master/123/libuinet/bin/passive'
cc -I/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libev -I/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libhttp_parser -DENABLE_EXTRACT -O -gdwarf-2 -I/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libuinet/api_include -c -o passive.o passive.c
cc -I/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libev -I/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libhttp_parser -DENABLE_EXTRACT -O -gdwarf-2 -I/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libuinet/api_include -o passive passive.o -L/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libuinet -luinet -L/usr/local//lib/ /root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libev/.libs/libev.a -lm -lpcap -L/root/sft/pbscan-master/123/libuinet/bin/passive/../../lib/libhttp_parser -lhttp_parser -lz -lpthread -lrt -lcrypto
/usr/bin/ld: cannot find -luinet
collect2: error: ld returned 1 exit status
make[2]: *** [/root/sft/pbscan-master/123/libuinet/bin/passive/../../mk/prog.mk:56: passive] Error 1
make[2]: Leaving directory '/root/sft/pbscan-master/123/libuinet/bin/passive'
make[2]: Entering directory '/root/sft/pbscan-master/123/libuinet/bin/tproxy'
cc -I/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libev -O -gdwarf-2 -I/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libuinet/api_include -c -o tproxy.o tproxy.c
cc -I/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libev -O -gdwarf-2 -I/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libuinet/api_include -o tproxy tproxy.o -L/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libuinet -luinet -L/usr/local//lib/ /root/sft/pbscan-master/123/libuinet/bin/tproxy/../../lib/libev/.libs/libev.a -lm -lpcap -lpthread -lrt -lcrypto
/usr/bin/ld: cannot find -luinet
collect2: error: ld returned 1 exit status
make[2]: *** [/root/sft/pbscan-master/123/libuinet/bin/tproxy/../../mk/prog.mk:56: tproxy] Error 1
make[2]: Leaving directory '/root/sft/pbscan-master/123/libuinet/bin/tproxy'
make[1]: *** [Makefile:13: all] Error 2
make[1]: Leaving directory '/root/sft/pbscan-master/123/libuinet/bin'
make: *** [Makefile:10: all] Error 2
I entered to libuinet folder under lib to make and it show
awk -f /root/sft/pbscan-master/123/libuinet/lib/libuinet/../../sys/tools/vnode_if.awk /root/sft/pbscan-master/123/libuinet/lib/libuinet/../../sys/kern/vnode_if.src -p
/root/sft/pbscan-master/123/libuinet/lib/libuinet/../../sys/kern/vnode_if.src(451): Missing end-of-line ; in " IN struct task *task; ".
make: *** [Makefile:391: vnode_if_newproto.h] Error 1