phaag / nfdump

Netflow processing tools
Other
788 stars 206 forks source link

Install problem with “--enable-readpcap” option #105

Closed siftfan closed 6 years ago

siftfan commented 6 years ago

Hello, I’m trying to install nfdump so it can ingest data from pcap files. I’m definitely using the “--enable-readpcap” option when running configure. After running configure, I expected to see a make file but it appears no make file is getting created in the nfdump-master directory. Should there be one in nfdump-master?

I’m attempting to install nfdump into Ubuntu 16.04 LTS with patching/updates current as of March 8, 2018. Ubuntu is running as a VM under Virtual Box. While using snapshots, I figured out the extra packages needed by autogen & configure and so I can get both of them to run to completion. I even installed a few of the suggested packages as well.

Since no make file was in the nfdump-master directory, I tried running /usr/bin/make just to see what would happen. But lots of warnings occurred and it finally terminated with the following error:

pcap_reader.c:52:18: fatal error: pcap.h: No such file or directory

In the attached log file, I did not attempt installation using sudo, but I did on a previous Snapshot’d attempt and the same results occurred.

When autogen runs there are some warnings about m4 and a couple instances of “Consider adding...”. But as mentioned, it seems to finish.

When configure runs I don’t see any warning or errors, several of the checks received a “no”. But it too seems to finish.

Please let me know if I’m doing something wrong. If it helps determine the root cause, I can try additional installations or re-test as necessary. Just let me know.

Thank you!

Kenny.

============================================

batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ ls AUTHORS bootstrap configure.ac doc Makefile.am README autogen.sh BSD-license.txt COPYING extra man README.md bin ChangeLog CreateSubHierarchy.pl LICENSE NEWS batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ sudo chmod 755 autogen.sh [sudo] password for batman: batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ ls AUTHORS bootstrap configure.ac doc Makefile.am README autogen.sh BSD-license.txt COPYING extra man README.md bin ChangeLog CreateSubHierarchy.pl LICENSE NEWS batman@batman-VirtualBox:~/nfdump-master$ ls -l total 100 -rwxr-xr-x 1 batman batman 38 Feb 11 06:10 AUTHORS -rwxr-xr-x 1 batman batman 2149 Feb 11 06:10 autogen.sh drwxrwxr-x 2 batman batman 4096 Feb 11 06:10 bin lrwxrwxrwx 1 batman batman 10 Mar 8 21:24 bootstrap -> autogen.sh -rw-rw-r-- 1 batman batman 1616 Feb 11 06:10 BSD-license.txt -rwxr-xr-x 1 batman batman 21932 Feb 11 06:10 ChangeLog -rwxr-xr-x 1 batman batman 12590 Feb 11 06:10 configure.ac lrwxrwxrwx 1 batman batman 15 Mar 8 21:24 COPYING -> BSD-license.txt -rwxr-xr-x 1 batman batman 4119 Feb 11 06:10 CreateSubHierarchy.pl drwxrwxr-x 2 batman batman 4096 Feb 11 06:10 doc drwxrwxr-x 5 batman batman 4096 Feb 11 06:10 extra -rw-rw-r-- 1 batman batman 1616 Feb 11 06:10 LICENSE -rwxr-xr-x 1 batman batman 134 Feb 11 06:10 Makefile.am drwxrwxr-x 2 batman batman 4096 Feb 11 06:10 man lrwxrwxrwx 1 batman batman 9 Mar 8 21:24 NEWS -> ChangeLog lrwxrwxrwx 1 batman batman 9 Mar 8 21:24 README -> README.md -rwxr-xr-x 1 batman batman 15405 Feb 11 06:10 README.md batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ ./autogen.sh autogen.sh: reconfigure with autoreconf autoreconf: Entering directory .' autoreconf: configure.ac: not using Gettext autoreconf: running: aclocal -I m4 --force aclocal: warning: couldn't open directory 'm4': No such file or directory autoreconf: configure.ac: tracing autoreconf: running: libtoolize --copy --force libtoolize: putting auxiliary files in '.'. libtoolize: copying file './ltmain.sh' libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([m4])' to configure.ac, libtoolize: and rerunning libtoolize and aclocal. libtoolize: Consider adding '-I m4' to ACLOCAL_AMFLAGS in Makefile.am. aclocal: warning: couldn't open directory 'm4': No such file or directory autoreconf: running: /usr/bin/autoconf --include=m4 --force autoreconf: running: /usr/bin/autoheader --include=m4 --force autoreconf: running: automake --add-missing --copy --force-missing configure.ac:12: installing './compile' configure.ac:12: installing './config.guess' configure.ac:12: installing './config.sub' configure.ac:10: installing './install-sh' configure.ac:10: installing './missing' Makefile.am: installing './INSTALL' bin/Makefile.am: installing './depcomp' configure.ac: installing './ylwrap' parallel-tests: installing './test-driver' autoreconf: Leaving directory.' autogen.sh: for the next step, run './configure' [or './configure --help' to check available options] batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ ls -l total 1636 -rw-rw-r-- 1 batman batman 384310 Mar 8 21:45 aclocal.m4 -rwxr-xr-x 1 batman batman 38 Feb 11 06:10 AUTHORS -rwxr-xr-x 1 batman batman 2149 Feb 11 06:10 autogen.sh drwxr-xr-x 2 batman batman 4096 Mar 8 21:45 autom4te.cache drwxrwxr-x 2 batman batman 4096 Mar 8 21:45 bin lrwxrwxrwx 1 batman batman 10 Mar 8 21:24 bootstrap -> autogen.sh -rw-rw-r-- 1 batman batman 1616 Feb 11 06:10 BSD-license.txt -rwxr-xr-x 1 batman batman 21932 Feb 11 06:10 ChangeLog -rwxr-xr-x 1 batman batman 7333 Mar 8 21:45 compile -rwxr-xr-x 1 batman batman 43499 Mar 8 21:45 config.guess -rw-rw-r-- 1 batman batman 9614 Mar 8 21:45 config.h.in -rwxr-xr-x 1 batman batman 36144 Mar 8 21:45 config.sub -rwxrwxr-x 1 batman batman 640512 Mar 8 21:45 configure -rwxr-xr-x 1 batman batman 12590 Feb 11 06:10 configure.ac lrwxrwxrwx 1 batman batman 15 Mar 8 21:24 COPYING -> BSD-license.txt -rwxr-xr-x 1 batman batman 4119 Feb 11 06:10 CreateSubHierarchy.pl -rwxr-xr-x 1 batman batman 23566 Mar 8 21:45 depcomp drwxrwxr-x 2 batman batman 4096 Mar 8 21:45 doc drwxrwxr-x 5 batman batman 4096 Feb 11 06:10 extra -rw-r--r-- 1 batman batman 15752 Mar 8 21:45 INSTALL -rwxr-xr-x 1 batman batman 15155 Mar 8 21:45 install-sh -rw-rw-r-- 1 batman batman 1616 Feb 11 06:10 LICENSE -rw-r--r-- 1 batman batman 324404 Mar 8 21:45 ltmain.sh -rwxr-xr-x 1 batman batman 134 Feb 11 06:10 Makefile.am -rw-rw-r-- 1 batman batman 25694 Mar 8 21:45 Makefile.in drwxrwxr-x 2 batman batman 4096 Mar 8 21:45 man -rwxr-xr-x 1 batman batman 6872 Mar 8 21:45 missing lrwxrwxrwx 1 batman batman 9 Mar 8 21:24 NEWS -> ChangeLog lrwxrwxrwx 1 batman batman 9 Mar 8 21:24 README -> README.md -rwxr-xr-x 1 batman batman 15405 Feb 11 06:10 README.md -rwxr-xr-x 1 batman batman 4640 Mar 8 21:45 test-driver -rwxr-xr-x 1 batman batman 6858 Mar 8 21:45 ylwrap batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ batman@batman-VirtualBox:~/nfdump-master$ ./configure --enable-readpcap checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-pc-linux-gnu checking how to print strings... printf checking for style of include used by make... GNU checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking dependency style of gcc... gcc3 checking for a sed that does not truncate output... /bin/sed checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for fgrep... /bin/grep -F checking for ld used by gcc... /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... yes checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B checking the name lister (/usr/bin/nm -B) interface... BSD nm checking whether ln -s works... yes checking the maximum length of command line arguments... 1572864 checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop checking for /usr/bin/ld option to reload object files... -r checking for objdump... objdump checking how to recognize dependent libraries... pass_all checking for dlltool... no checking how to associate runtime and link libraries... printf %s\n checking for ar... ar checking for archiver @FILE support... @ checking for strip... strip checking for ranlib... ranlib checking command to parse /usr/bin/nm -B output from gcc object... ok checking for sysroot... no checking for a working dd... /bin/dd checking how to truncate binary pipes... /bin/dd bs=4096 count=1 checking for mt... mt checking if mt is a manifest tool... no checking how to run the C preprocessor... gcc -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for dlfcn.h... yes checking for objdir... .libs checking if gcc supports -fno-rtti -fno-exceptions... no checking for gcc option to produce PIC... -fPIC -DPIC checking if gcc PIC flag -fPIC -DPIC works... yes checking if gcc static flag -static works... yes checking if gcc supports -c -o file.o... yes checking if gcc supports -c -o file.o... (cached) yes checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes checking whether -lc should be explicitly linked in... no checking dynamic linker characteristics... GNU/Linux ld.so checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking for gcc... (cached) gcc checking whether we are using the GNU C compiler... (cached) yes checking whether gcc accepts -g... (cached) yes checking for gcc option to accept ISO C89... (cached) none needed checking whether gcc understands -c and -o together... (cached) yes checking dependency style of gcc... (cached) gcc3 checking for bison... bison -y checking for flex... flex checking lex output file root... lex.yy checking lex library... -lfl checking whether yytext is a pointer... yes checking for pkg-config... /usr/bin/pkg-config checking pkg-config is at least version 0.9.0... yes checking for struct sockaddr.sa_len... no checking for struct sockaddr_storage.ss_family... yes checking for struct sockaddr_storage.ss_family... no checking for struct sockaddr_storage.ss_len... no checking for struct sockaddr_storage.ss_len... no checking for struct sockaddr.sa_len... (cached) no checking for gethostbyname... yes checking for setsockopt... yes checking for fpurge... no checking for __fpurge... yes checking if htonll is defined... no checking for dirent.h that defines DIR... yes checking for library containing opendir... none required checking for ANSI C header files... (cached) yes checking nameser8_compat.h usability... no checking nameser8_compat.h presence... no checking for nameser8_compat.h... no checking features.h usability... yes checking features.h presence... yes checking for features.h... yes checking arpa/inet.h usability... yes checking arpa/inet.h presence... yes checking for arpa/inet.h... yes checking fcntl.h usability... yes checking fcntl.h presence... yes checking for fcntl.h... yes checking netinet/in.h usability... yes checking netinet/in.h presence... yes checking for netinet/in.h... yes checking fts.h usability... yes checking fts.h presence... yes checking for fts.h... yes checking for stdint.h... (cached) yes checking for stdlib.h... (cached) yes checking stddef.h usability... yes checking stddef.h presence... yes checking for stddef.h... yes checking for string.h... (cached) yes checking sys/socket.h usability... yes checking sys/socket.h presence... yes checking for sys/socket.h... yes checking syslog.h usability... yes checking syslog.h presence... yes checking for syslog.h... yes checking for unistd.h... (cached) yes checking iso/limits_iso.h usability... no checking iso/limits_iso.h presence... no checking for iso/limits_iso.h... no checking pcap-bpf.h usability... no checking pcap-bpf.h presence... no checking for pcap-bpf.h... no checking net/bpf.h usability... no checking net/bpf.h presence... no checking for net/bpf.h... no checking for sys/types.h... (cached) yes checking for netinet/in.h... (cached) yes checking for arpa/nameser.h... yes checking for arpa/nameser_compat.h... yes checking for netdb.h... yes checking for resolv.h... yes checking for netinet/in_systm.h... yes checking bzlib.h usability... yes checking bzlib.h presence... yes checking for bzlib.h... yes checking size of void ... 8 checking for an ANSI C-conforming const... yes checking for inline... inline checking whether byte ordering is bigendian... no checking for pid_t... yes checking for size_t... yes checking whether struct tm is in sys/time.h or time.h... time.h checking for stdbool.h that conforms to C99... yes checking for _Bool... yes checking whether closedir returns void... no checking vfork.h usability... no checking vfork.h presence... no checking for vfork.h... no checking for fork... yes checking for vfork... yes checking for working fork... yes checking for working vfork... (cached) yes checking for stdlib.h... (cached) yes checking for GNU libc compatible malloc... yes checking whether time.h and sys/time.h may both be included... yes checking for sys/time.h... yes checking for unistd.h... (cached) yes checking for alarm... yes checking for working mktime... yes checking for stdlib.h... (cached) yes checking for GNU libc compatible realloc... yes checking whether lstat correctly handles trailing slash... yes checking whether stat accepts an empty string... no checking for strftime... yes checking for inet_ntoa... yes checking for socket... yes checking for strchr... yes checking for strdup... yes checking for strerror... yes checking for strrchr... yes checking for strstr... yes checking for scandir... yes checking for res_search in -lsocket... no checking for res_search in -lresolv... no checking for dn_skipname in -lresolv... no checking for dn_skipname in -lresolv... yes checking for BZ2_bzCompressInit in -lbz2... yes checking for ptrdiff_t... yes checking for size_t... (cached) yes checking size of short... 2 checking size of int... 4 checking size of long... 8 checking size of long long... 8 checking size of int64... 0 checking size of void ... (cached) 8 checking size of size_t... 8 checking size of ptrdiff_t... 8 checking for an ANSI C-conforming const... (cached) yes checking for memcmp... yes checking for memcpy... yes checking for memmove... yes checking for memset... yes checking for union semun... no checking for the %z format string in printf()... yes checking for doxygen... no checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating doc/Makefile config.status: creating config.h config.status: executing depfiles commands config.status: executing libtool commands checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating doc/Makefile config.status: creating Makefile config.status: creating bin/Makefile config.status: creating man/Makefile config.status: creating config.h config.status: config.h is unchanged config.status: executing depfiles commands config.status: executing libtool commands

phaag commented 6 years ago

--enable-readpcap is actually not a productive switch and for development purpose only. Therefore configure does not all check and you have to make sure yourself, that you have installed all necessary developer file from pcap library as well as the pcap library itself. pcap.h for instance is often required to install separately such as libpcap-dev