fln / addrwatch

A tool similar to arpwatch for IPv4/IPv6 and ethernet address pairing monitoring.
GNU General Public License v3.0
184 stars 30 forks source link

no config file for ./configure #10

Closed larieu closed 6 years ago

larieu commented 6 years ago

I git cloned into a Centos 7 system and tried to run ./configure and got the "not exist error" it exist only a non executable ./configure.ac

any recommendation?

larieu commented 6 years ago

I have tried with automake

aclocal autoconf autoheader automake --add-missing

it generates ./configure running this seems to end OK

but at make [root@vm-7104 addrwatch]# make Making all in src make[1]: Entering directory /root/addrwatch/src' make all-am make[2]: Entering directory/root/addrwatch/src' gcc -DHAVE_CONFIG_H -I. -g -O2 -MT addrwatch.o -MD -MP -MF .deps/addrwatch.Tpo -c -o addrwatch.o addrwatch.c In file included from addrwatch.c:13:0: addrwatch.h:7:18: fatal error: pcap.h: No such file or directory

include

              ^

compilation terminated. make[2]: [addrwatch.o] Error 1 make[2]: Leaving directory `/root/addrwatch/src' make[1]: [all] Error 2 make[1]: Leaving directory `/root/addrwatch/src' make: *** [all-recursive] Error 1

larieu commented 6 years ago

the missing part is provided by libpcap-devel but now

gcc -g -O2 -o addrwatch addrwatch.o util.o parse.o check.o process.o base64.o storage.o mcache.o output_flatfile.o output_sqlite.o output_shm.o -levent -lrt addrwatch.o: In function read_cb': /root/addrwatch_01/src/addrwatch.c:204: undefined reference topcap_next' addrwatch.o: In function add_iface': /root/addrwatch_01/src/addrwatch.c:228: undefined reference topcap_open_live' /root/addrwatch_01/src/addrwatch.c:234: undefined reference to pcap_datalink' /root/addrwatch_01/src/addrwatch.c:236: undefined reference topcap_datalink_val_to_description' /root/addrwatch_01/src/addrwatch.c:236: undefined reference to pcap_datalink_val_to_name' /root/addrwatch_01/src/addrwatch.c:291: undefined reference topcap_close' /root/addrwatch_01/src/addrwatch.c:243: undefined reference to pcap_compile' /root/addrwatch_01/src/addrwatch.c:250: undefined reference topcap_setfilter' /root/addrwatch_01/src/addrwatch.c:257: undefined reference to pcap_fileno' /root/addrwatch_01/src/addrwatch.c:282: undefined reference topcap_datalink' /root/addrwatch_01/src/addrwatch.c:282: undefined reference to pcap_datalink_val_to_description' /root/addrwatch_01/src/addrwatch.c:245: undefined reference topcap_geterr' /root/addrwatch_01/src/addrwatch.c:252: undefined reference to pcap_geterr' /root/addrwatch_01/src/addrwatch.c:289: undefined reference topcap_freecode' addrwatch.o: In function del_iface': /root/addrwatch_01/src/addrwatch.c:306: undefined reference topcap_freecode' /root/addrwatch_01/src/addrwatch.c:307: undefined reference to pcap_close' addrwatch.o: In functionmain': /root/addrwatch_01/src/addrwatch.c:515: undefined reference to pcap_lookupdev' collect2: error: ld returned 1 exit status make[2]: *** [addrwatch] Error 1 make[2]: Leaving directory/root/addrwatch_01/src' make[1]: [all] Error 2 make[1]: Leaving directory `/root/addrwatch_01/src' make: [all-recursive] Error 1

fln commented 6 years ago

To compile addrwatch from the source repository on a CentOS 7 system execute the following commands:

yum install git gcc autoconf automake libpcap-devel libevent-devel
git clone https://github.com/fln/addrwatch
cd addrwatch/
./bootstrap.sh
./configure
make

You can then install binaries with make install or use them directly from src directory.

Script bootstrap.sh invokes autoconf/automake to create configure script.

If you need MySQL/MariaDB support use ./configure --enable-mysql.

larieu commented 6 years ago

confirm this is the solution