blechschmidt / massdns

A high-performance DNS stub resolver for bulk lookups and reconnaissance (subdomain enumeration)
GNU General Public License v3.0
3.13k stars 462 forks source link

Centos 7 make Issue #124

Closed soufianeEL closed 2 years ago

soufianeEL commented 2 years ago
[root@m11092 massdns]#
[root@m11092 massdns]# make
mkdir -p bin
cc    -DMASSDNS_REVISION=\"v1.0.0-59-g59c18ae\" -O3 -std=c11 -DHAVE_EPOLL -DHAVE_SYSINFO -Wall -fstack-protector-strong src/main.c -o bin/massdns
src/main.c: In function âadd_default_socketâ:
src/main.c:504:54: error: âIPV6_HDRINCLâ undeclared (first use in this function)
         if(setsockopt(info.descriptor, IPPROTO_IPV6, IPV6_HDRINCL, &enable, sizeof(enable)) < 0)
                                                      ^
src/main.c:504:54: note: each undeclared identifier is reported only once for each function it appears in
make: *** [all] Error 1
[root@m11092 massdns]#
[root@m11092 massdns]# echo $?
2

why i get that error when i'm trying to compile source ? could you please help me ?``

g1t01 commented 2 years ago

I also get a similar error on Ubuntu 20.04 AWS Lightsail instance: ubuntu@ip-172-26-0-245:/usr/local/bin/massdns$ makemkdir -p bincc -DMASSDNS_REVISION=\"v1.0.0-59-g59c18ae\" -O3 -std=c11 -DHAVE_EPOLL -DHAVE_SYSINFO -Wall -fstack-protector-strong src/main.c -o bin/massdnsmake: cc: Command not foundmake: *** [Makefile:6: all] Error 127

blechschmidt commented 2 years ago

The CentOS issue is fixed by a5a17668c05b2485e9e1b25abf4d2eb0f7a773c0 as described in https://github.com/blechschmidt/massdns/issues/127#issuecomment-1073249014.

Regarding Ubuntu, it looks like the build-essential package, in particular gcc, is not installed. Please make sure that cc points to your C compiler, e.g. by checking which cc.