The following errors occur when building on Debian 7:
docker: In file included from src/os/unix/ngx_linux_config.h:121:0,
docker: from src/core/ngx_config.h:26,
docker: from src/core/ngx_log.c:8:
docker: /usr/include/linux/in6.h:30:8: error: redefinition of 'struct in6_addr'
docker: In file included from src/os/unix/ngx_linux_config.h:45:0,
docker: from src/core/ngx_config.h:26,
docker: from src/core/ngx_log.c:8:
docker: /usr/include/netinet/in.h:198:8: note: originally defined here
docker: In file included from src/os/unix/ngx_linux_config.h:121:0,
docker: from src/core/ngx_config.h:26,
docker: from src/core/ngx_log.c:8:
docker: /usr/include/linux/in6.h:46:8: error: redefinition of 'struct sockaddr_in6'
docker: In file included from src/os/unix/ngx_linux_config.h:44:0,
docker: from src/core/ngx_config.h:26,
docker: from src/core/ngx_log.c:8:
docker: /usr/include/x86_64-linux-gnu/sys/socket.h:92:17: note: originally defined here
docker: In file included from src/os/unix/ngx_linux_config.h:121:0,
docker: from src/core/ngx_config.h:26,
We must include linux/in6.h before netinet/in.h, since the latter
maintains definition guards around the IPv6 kernel structures:
The following errors occur when building on Debian 7:
We must include
linux/in6.h
beforenetinet/in.h
, since the latter maintains definition guards around the IPv6 kernel structures:https://code.woboq.org/userspace/glibc/inet/netinet/in.h.html#209