Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Iptables headers not found. You may need to specify --ipt-inc=... #64

Closed
jura22 opened this issue Oct 4, 2016 · 5 comments
Closed

Iptables headers not found. You may need to specify --ipt-inc=... #64

jura22 opened this issue Oct 4, 2016 · 5 comments

Comments

@jura22
Copy link

jura22 commented Oct 4, 2016

Hello.

I cant configure ipt-netflow-2.2 on centos 7.

uname -a

Linux maticni-gate 3.10.0-327.36.1.el7.x86_64 #1 SMP Sun Sep 18 13:04:29 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

[root@maticni-gate ipt-netflow]# pwd
/usr/local/src/ipt-netflow
[root@maticni-gate ipt-netflow]# ./configure
Kernel version: 3.10.0-327.36.1.el7.x86_64 (uname)
Kernel sources: /lib/modules/3.10.0-327.36.1.el7.x86_64/build (found)
Checking for presence of include/linux/llist.h... Yes
Checking for presence of include/linux/grsecurity.h... No
Iptables binary version: 1.4.21 (detected from /sbin/iptables)
pkg-config for version 1.4.21 exists: Yes
Checking for presence of xtables.h... No
Checking for presence of iptables.h... No
! Iptables headers not found. You may need to specify --ipt-inc=...
!
! Under Centos simply run this:
! root# yum install iptables-devel.x86_64 pkgconfig
[root@maticni-gate ipt-netflow]# rpm -ql iptables-devel
/usr/include/ip6tables.h
/usr/include/iptables
/usr/include/iptables.h
/usr/include/iptables/internal.h
/usr/include/libiptc
/usr/include/libiptc/ipt_kernel_headers.h
/usr/include/libiptc/libip6tc.h
/usr/include/libiptc/libiptc.h
/usr/include/libiptc/libxtc.h
/usr/include/libiptc/xtcshared.h
/usr/include/libipulog
/usr/include/libipulog/libipulog.h
/usr/include/xtables-version.h
/usr/include/xtables.h
/usr/lib64/libip4tc.so
/usr/lib64/libip6tc.so
/usr/lib64/libiptc.so
/usr/lib64/libxtables.so
/usr/lib64/pkgconfig/libip4tc.pc
/usr/lib64/pkgconfig/libip6tc.pc
/usr/lib64/pkgconfig/libiptc.pc
/usr/lib64/pkgconfig/xtables.pc
[root@maticni-gate ipt-netflow]# rpm -ql pkgconfig
/usr/bin/pkg-config
/usr/lib64/pkgconfig
/usr/share/aclocal/pkg.m4
/usr/share/doc/pkgconfig-0.27.1
/usr/share/doc/pkgconfig-0.27.1/AUTHORS
/usr/share/doc/pkgconfig-0.27.1/COPYING
/usr/share/doc/pkgconfig-0.27.1/NEWS
/usr/share/doc/pkgconfig-0.27.1/README
/usr/share/doc/pkgconfig-0.27.1/pkg-config-guide.html
/usr/share/man/man1/pkg-config.1.gz
/usr/share/pkgconfig

[root@maticni-gate ipt-netflow]# ./configure --ipt-inc=/usr/include
Kernel version: 3.10.0-327.36.1.el7.x86_64 (uname)
Kernel sources: /lib/modules/3.10.0-327.36.1.el7.x86_64/build (found)
Checking for presence of include/linux/llist.h... Yes
Checking for presence of include/linux/grsecurity.h... No
Iptables binary version: 1.4.21 (detected from /sbin/iptables)
pkg-config for version 1.4.21 exists: Yes
Checking for presence of xtables.h... No
Checking for presence of iptables.h... No
! Iptables headers not found. You may need to specify --ipt-inc=...
!
! Under Centos simply run this:
! root# yum install iptables-devel.x86_64 pkgconfig

Any idea ?

@aabc
Copy link
Owner

aabc commented Oct 4, 2016

Could you paste output of pkg-config --cflags xtables|od -x pls?

@jura22
Copy link
Author

jura22 commented Oct 5, 2016

[root@maticni-gate ipt-netflow-2.2]# pkg-config --cflags xtables|od -x
0000000 0a20
0000002

@aabc
Copy link
Owner

aabc commented Oct 5, 2016

Thanks. Could you also show output of:

$ ls -l /usr/include/xtables.h
$ echo -e '#define __EXPORTED_HEADERS__\n#include <xtables.h>\n' > test.c
$ gcc -c test.c

@jura22
Copy link
Author

jura22 commented Oct 5, 2016

Good job. Its my fault. Missing gcc. Please insert in to README first step for CentOS/RHEL:
yum group install "Development Tools"
Thanks

@aabc
Copy link
Owner

aabc commented Oct 5, 2016

Thanks!

@aabc aabc closed this as completed Oct 5, 2016
aabc added a commit that referenced this issue Oct 26, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants