Hi all,
I am trying to build moloch under a CentOS 6.5 x86_64 host, but the
following errors are returned:
[root@c6test moloch]# ./configure --prefix=/opt/moloch
--with-libnids=/opt/libnids --with-yara=/opt/yara
--with-libpcap=/opt/libpcap
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
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 for style of include used by make... GNU
checking dependency style of gcc... none
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... none
checking for main in -lpcre... yes
checking for main in -luuid... yes
checking for main in -lmagic... yes
checking for pfring... no
checking for libpcap... /opt/libpcap
checking for libnids... /opt/libnids
checking for yara... /opt/yara
checking for GeoIP... yes
checking for glib2... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating capture/Makefile
config.status: creating capture/plugins/Makefile
config.status: creating capture/parsers/Makefile
config.status: creating db/Makefile
config.status: creating tests/plugins/Makefile
config.status: creating viewer/Makefile
config.status: creating viewer/version.js
config.status: creating capture/molochconfig.h
config.status: executing depfiles commands
[root@c6test moloch]# make
Makefile:219: warning: overriding commands for target `capture/plugins/Makefile'
Makefile:217: warning: ignoring old commands for target
`capture/plugins/Makefile'
cd . && /bin/sh /tmp/o/moloch/missing --run aclocal-1.9
/tmp/o/moloch/missing: line 52: aclocal-1.9: command not found
WARNING: `aclocal-1.9' is missing on your system. You should only need it if
you modified `acinclude.m4' or `
configure.ac'. You might want
to install the `Automake' and `Perl' packages. Grab them from
any GNU archive site.
cd . && /bin/sh /tmp/o/moloch/missing --run automake-1.9 --foreign
/tmp/o/moloch/missing: line 52: automake-1.9: command not found
WARNING: `automake-1.9' is missing on your system. You should only need it if
you modified `Makefile.am', `acinclude.m4' or `
configure.ac'.
You might want to install the `Automake' and `Perl' packages.
Grab them from any GNU archive site.
cd . && /bin/sh /tmp/o/moloch/missing --run autoconf
/bin/sh ./config.status --recheck
running CONFIG_SHELL=/bin/sh /bin/sh ./configure --prefix=/opt/moloch
--with-libnids=/opt/libnids --with-yara=/opt/yara
--with-libpcap=/opt/libpcap --no-create --no-recursion
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
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 for style of include used by make... GNU
checking dependency style of gcc... none
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... none
checking for main in -lpcre... yes
checking for main in -luuid... yes
checking for main in -lmagic... yes
checking for pfring... no
checking for libpcap... /opt/libpcap
checking for libnids... /opt/libnids
checking for yara... /opt/yara
checking for GeoIP... yes
checking for glib2... yes
configure: creating ./config.status
/bin/sh ./config.status
config.status: creating Makefile
config.status: creating capture/Makefile
config.status: creating capture/plugins/Makefile
config.status: creating capture/parsers/Makefile
config.status: creating db/Makefile
config.status: creating tests/plugins/Makefile
config.status: creating viewer/Makefile
config.status: creating viewer/version.js
config.status: creating capture/molochconfig.h
config.status: capture/molochconfig.h is unchanged
config.status: executing depfiles commands
Makefile:219: warning: overriding commands for target `capture/plugins/Makefile'
Makefile:217: warning: ignoring old commands for target
`capture/plugins/Makefile'
Making all in capture
make[1]: Entering directory `/tmp/o/moloch/capture'
gcc -c thirdparty/js0n.c -o thirdparty/js0n.o
gcc -ggdb -DNDEBUG -DHTTP_PARSER_STRICT=0 -DHTTP_PARSER_DEBUG=0 -O3 -c
thirdparty/http_parser.c -o thirdparty/http_parser.o
gcc -c thirdparty/patricia.c -o thirdparty/patricia.o
gcc -fPIC -O2 -ggdb -Wall -Wextra -D_GNU_SOURCE -c main.c db.c nids.c
yara.c http.c config.c parsers.c plugins.c field.c trie.c \
-I/opt/libpcap/include \
-Ithirdparty -pthread -I/usr/include/glib-2.0
-I/usr/lib64/glib-2.0/include -I/opt/yara/include
-I/opt/libnids/include
yara.c:24: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’
before ‘*’ token
yara.c:25: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’
before ‘*’ token
yara.c:36: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’
before ‘*’ token
yara.c: In function ‘moloch_yara_init’:
yara.c:68: warning: implicit declaration of function ‘yr_init’
yara.c:70: error: ‘yContext’ undeclared (first use in this function)
yara.c:70: error: (Each undeclared identifier is reported only once
yara.c:70: error: for each function it appears in.)
yara.c:70: warning: implicit declaration of function ‘moloch_yara_open’
yara.c:71: error: ‘yEmailContext’ undeclared (first use in this function)
yara.c: At top level:
yara.c:235: error: expected ‘)’ before ‘*’ token
yara.c:260: error: expected ‘)’ before ‘*’ token
yara.c: In function ‘moloch_yara_execute’:
yara.c:264: error: ‘MEMORY_BLOCK’ undeclared (first use in this function)
yara.c:264: error: expected ‘;’ before ‘block’
yara.c:267: error: ‘block’ undeclared (first use in this function)
yara.c:281: warning: implicit declaration of function ‘yr_scan_mem_blocks’
yara.c:281: error: ‘yContext’ undeclared (first use in this function)
yara.c:281: error: ‘YARACALLBACK’ undeclared (first use in this function)
yara.c:281: error: expected ‘)’ before ‘moloch_yara_callback’
yara.c:262: warning: unused parameter ‘session’
yara.c: In function ‘moloch_yara_email_execute’:
yara.c:287: error: ‘MEMORY_BLOCK’ undeclared (first use in this function)
yara.c:287: error: expected ‘;’ before ‘block’
yara.c:293: error: ‘block’ undeclared (first use in this function)
yara.c:307: error: ‘yEmailContext’ undeclared (first use in this function)
yara.c:307: error: ‘YARACALLBACK’ undeclared (first use in this function)
yara.c:307: error: expected ‘)’ before ‘moloch_yara_callback’
yara.c:285: warning: unused parameter ‘session’
yara.c: In function ‘moloch_yara_exit’:
yara.c:313: warning: implicit declaration of function ‘yr_destroy_context’
yara.c:313: error: ‘yContext’ undeclared (first use in this function)
make[1]: *** [all] Error 1
make[1]: Leaving directory `/tmp/o/moloch/capture'
make: *** [all-recursive] Error 1
[root@c6test moloch]#
[root@c6test moloch]#
[root@c6test moloch]#
[root@c6test moloch]# rpm -qa | grep autocnf
[root@c6test moloch]# rpm -qa | grep autoconf
autoconf-2.63-5.1.el6.noarch
[root@c6test moloch]# rpm -qa | grep automake
automake-1.11.1-4.el6.noarch
[root@c6test moloch]#
Yara is release 2.0. Maybe could this be a problem??