dhcpcd-discuss

Re: compile error dhcpcd 6.3.2

Olaf Westrik

Thu Apr 17 10:38:40 2014



sorry, forgot to mention: gcc=4.4.5, glibc=2.11.3, linux headers=3.4


On 2014-04-17 12:07, Roy Marples wrote:

_BSD_SOURCE is defined so that the BSD UDP header definitons are used.
Can you try adding this line in the include section at the top of
dhcpcd.c please?

#include <fcntl.h>

That does not make a difference.

Only after adding -D_GNU_SOURCE (for example in config.mk) __USE_GNU is defined via features.h and O_CLOEXEC is defined.

Adding _GNU_SOURCE results in another problem though:
cc -Os -march=i486 -mtune=pentium -pipe -fomit-frame-pointer -Wall -Wextra -std=c99 -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -D_GNU_SOURCE -DINET -DINET6 -DPLUGIN_DEV -I./crypt -c dhcpcd.c -o dhcpcd.o
In file included from ipv6.h:39,
                 from net.h:41,
                 from dhcp.h:247,
                 from dhcp6.h:100,
                 from dhcpcd.c:59:
/usr/include/linux/ipv6.h:19: error: redefinition of 'struct in6_pktinfo'
/usr/include/linux/ipv6.h:24: error: redefinition of 'struct ip6_mtuinfo'
make: *** [dhcpcd.o] Error 1


Olaf

Follow-Ups:
Re: compile error dhcpcd 6.3.2Roy Marples
References:
compile error dhcpcd 6.3.2Olaf Westrik
Re: compile error dhcpcd 6.3.2Roy Marples
Archive administrator: postmaster@marples.name