From: Alexander Aring <aar@pengutronix.de>
To: ptxdist@pengutronix.de
Subject: Re: [ptxdist] iproute2 build errors when updating to 4.6
Date: Tue, 24 May 2016 09:20:40 +0200 [thread overview]
Message-ID: <d8d1e247-a68b-bf85-e1c1-247e4afe734f@pengutronix.de> (raw)
In-Reply-To: <20160521235513.GA410@archie.localdomain>
Hi,
I think I know what's going on here. :-)
On 05/22/2016 01:55 AM, Clemens Gruber wrote:
> Hi,
>
> I need some features from the new iproute2 4.6, but there seem to be
> some kernel header vs glibc header incompatibilities occuring when
> building the new iproute2 4.6 for ptxdist.
>
> Two examples of the numerous build errors on ptxdist 2016.04.0, a
> toolchain with glibc 2.22 and kernel + kernel-headers version 4.6.
>
> In file included from m_ipt.c:17:0:
> ../include/linux/if.h:106:19: error: redeclaration of enumerator 'IFF_UP'
> #define IFF_UP IFF_UP
> ^
> ../include/linux/if.h:79:2: note: previous definition of 'IFF_UP' was here
> IFF_UP = 1<<0, /* sysfs */
> ^~~~~~
>
> In file included from ../include/xtables.h:16:0,
> from ../include/iptables.h:5,
> from m_ipt.c:18:
> TOOLCHAIN/sysroot-arm-v7a-linux-gnueabihf/usr/include/net/if.h:111:8: error: redefinition of 'struct ifmap'
here, you already replaced the TOOLCHAIN path and it uses the
kernel-headers from toolchain, not ptxdist.
> struct ifmap
> ^~~~~
> In file included from m_ipt.c:17:0:
> ../include/linux/if.h:189:8: note: originally defined here
I suppose it's a relative include from your TOOLCHAIN kernel-headers.
The solution would be that you need to tell the iproute2 buildsystem
where the kernel-headers are which you want to use.
E.g. (running fast grep on ptxdist dir)
rules/bridge-utils.make: --with-linux-headers=$(KERNEL_HEADERS_DIR)
which can be checked by:
ptxdist print KERNEL_HEADERS_DIR
in your BSP and this directory should be use to search kernel headers.
> struct ifmap {
> ^~~~~
>
> There is a commit in version 4.6 of iproute2, which should already have fixed
> these build errors:
> http://git.kernel.org/cgit/linux/kernel/git/shemminger/iproute2.git/commit/?id=8a781d7e2580e14f097b23a7c4731bafc800a824
>
That's a fallback and it seems that iproute2 prefers the toolchain one.
- Alex
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
next prev parent reply other threads:[~2016-05-24 7:20 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-21 23:55 Clemens Gruber
2016-05-24 7:20 ` Alexander Aring [this message]
2016-05-24 7:30 ` Alexander Aring
2016-05-24 13:01 ` Clemens Gruber
2016-05-24 15:24 ` Alexander Aring
2016-05-24 18:08 ` Alexander Aring
2016-05-25 17:42 ` Clemens Gruber
2016-05-29 18:31 ` Alexander Aring
2016-05-30 19:59 ` Clemens Gruber
2016-06-15 18:37 ` Alexander Aring
2016-06-16 16:19 ` Clemens Gruber
2016-05-24 10:04 ` Michael Olbrich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d8d1e247-a68b-bf85-e1c1-247e4afe734f@pengutronix.de \
--to=aar@pengutronix.de \
--cc=ptxdist@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox