Netdev List
 help / color / mirror / Atom feed
* userspace build broken by include changes
@ 2016-10-15 11:40 Pascal Terjan
  2016-10-15 14:02 ` Mikko Rapeli
  0 siblings, 1 reply; 2+ messages in thread
From: Pascal Terjan @ 2016-10-15 11:40 UTC (permalink / raw)
  To: Mikko Rapeli, David S. Miller; +Cc: netdev

rp-pppoe plugin of ppp no longer builds:

In file included from pppoe.h:87:0,
                 from plugin.c:29:
/usr/include/linux/in.h:28:3: error: redeclaration of enumerator 'IPPROTO_IP'
   IPPROTO_IP = 0,  /* Dummy protocol for TCP  */
   ^
/usr/include/netinet/in.h:42:5: note: previous definition of
'IPPROTO_IP' was here
     IPPROTO_IP = 0,    /* Dummy protocol for TCP.  */

Short reproducer:

#include <sys/cdefs.h>
#include <sys/socket.h>
#include <linux/if.h>
#include <netinet/in.h>
#include <linux/ppp_defs.h>
#include <linux/if_pppox.h>

Full log:
http://pkgsubmit.mageia.org/autobuild/cauldron/x86_64/core/2016-10-12/ppp-2.4.7-8.mga6.src.rpm/build.0.20161012185227.log

Moving the include of linux/if.h after netinet/in.h fixes it.

I guess the breakage is caused by
http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/include/uapi/linux?id=eafe92114308acf14e45c6c3d154a5dad5523d1a
but the commit doesn't look wrong to me.

This is indeed enough to cause the error:

#include <linux/if.h>
#include <netinet/in.h>
#include <linux/in.h>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-10-15 14:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-15 11:40 userspace build broken by include changes Pascal Terjan
2016-10-15 14:02 ` Mikko Rapeli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox