betolj / ndpi-netfilter

GNU General Public License v2.0
126 stars 69 forks source link

error running this cmnd sudo NDPI_PATH=/usr/src/ndpi-netfilter-master/nDPI make #79

Open usamazaheer opened 4 years ago

usamazaheer commented 4 years ago

Hi, i am working on some academic project in which i have to run this integrated (ndpi with netfilter) firewall in a Docker Container.i am facing some issues during the installation of nDPI in ubuntu 18.04. it gave an error while running "sudo NDPI path=/usr/src/ndpi-netfilter-master/nDPI make. error is usama@usama-Latitude-E6320:/usr/src/ndpi-netfilter-master$ sudo NDPI_PATH=/usr/src/ndpi-netfilter-master/nDPI make make -C ipt make[1]: Entering directory '/usr/src/ndpi-netfilter-master/ipt' if test -d ndpi_cpy; then \ cp /usr/src/ndpi-netfilter-master/nDPI/src/ ndpi_cpy -R; \ else \ mkdir ndpi_cpy; \ cp /usr/src/ndpi-netfilter-master/nDPI/src/ ndpi_cpy -R; \ fi make libxt_ndpi.so make[2]: Entering directory '/usr/src/ndpi-netfilter-master/ipt' make[2]: 'libxt_ndpi.so' is up to date. make[2]: Leaving directory '/usr/src/ndpi-netfilter-master/ipt' rm -r ndpi_cpy make[1]: Leaving directory '/usr/src/ndpi-netfilter-master/ipt' make -C src make[1]: Entering directory '/usr/src/ndpi-netfilter-master/src' if test -d ndpi_cpy; then \ cp /usr/src/ndpi-netfilter-master/nDPI/src/ ndpi_cpy -R; \ else \ mkdir ndpi_cpy; \ cp /usr/src/ndpi-netfilter-master/nDPI/src/ ndpi_cpy -R; \ fi cp ndpi_cpy/../../nDPI-patch/src/ ndpi_cpy/ -R; cp ndpi_cpy/lib/third_party/src/.c ndpi_cpy/lib -R; cp ndpi_cpy/lib/third_party/include/.h ndpi_cpy/lib -R; cp ndpi_cpy/lib/third_party/include/.h ndpi_cpy/include -R; sed -i "s/^\svoid ndpi_free_flow/\/\/void ndpi_free_flow/" ndpi_cpy/include/ndpi_api.h; make -C /lib/modules/5.0.0-23-generic/build M=$PWD; make[2]: Entering directory '/usr/src/linux-headers-5.0.0-23-generic' CC [M] /usr/src/ndpi-netfilter-master/src/main.o /usr/src/ndpi-netfilter-master/src/main.c: In function ‘ndpi_gc_flow’: /usr/src/ndpi-netfilter-master/src/main.c:388:9: error: implicit declaration of function ‘do_gettimeofday’; did you mean ‘do_settimeofday64’? [-Werror=implicit-function-declaration] do_gettimeofday(&tv); ^~~~~~~ do_settimeofday64 /usr/src/ndpi-netfilter-master/src/main.c: In function ‘ndpi_mt’: /usr/src/ndpi-netfilter-master/src/main.c:633:13: error: implicit declaration of function ‘nf_ct_is_untracked’; did you mean ‘nf_ct_is_expired’? [-Werror=implicit-function-declaration] } else if (nf_ct_is_untracked(ct)){ ^~~~~~ nf_ct_is_expired At top level: /usr/src/ndpi-netfilter-master/src/main.c:99:13: warning: ‘debug_printf’ defined but not used [-Wunused-function] static void debug_printf(u32 protocol, void id_struct, ^~~~ cc1: some warnings being treated as errors scripts/Makefile.build:284: recipe for target '/usr/src/ndpi-netfilter-master/src/main.o' failed make[3]: [/usr/src/ndpi-netfilter-master/src/main.o] Error 1 Makefile:1606: recipe for target 'module/usr/src/ndpi-netfilter-master/src' failed make[2]: [module/usr/src/ndpi-netfilter-master/src] Error 2 make[2]: Leaving directory '/usr/src/linux-headers-5.0.0-23-generic' Makefile:155: recipe for target 'all' failed make[1]: [all] Error 2 make[1]: Leaving directory '/usr/src/ndpi-netfilter-master/src' Makefile:5: recipe for target 'all' failed make: [all] Error 2

houmie commented 3 years ago

I have the same problem. Have you found a solution for it?

Oumayma-crypto commented 3 years ago

I'm having the same issue too!

MuhammadAhsan66 commented 2 years ago

@usamazaheer Hi Have you found the solution?? I am getting the same errors.

MuhammadAhsan66 commented 2 years ago

@usamazaheer Hi Have you found the solution?? I am getting the same errors.

@houmie @Oumayma-crypto @MaartenW

houmie commented 2 years ago

No, I didn't find a solution.

MuhammadAhsan66 commented 2 years ago

Please use this official repository to install and configure nDPI: https://github.com/ntop/nDPI

Clone this repo and just follow the steps in the readme file.