[yocto] How should we handle GCC 6 and -isystem /usr/include?

Khem Raj raj.khem at gmail.com
Wed Apr 26 10:11:34 PDT 2017


On Wed, Apr 26, 2017 at 9:50 AM Martin Kelly <mkelly at xevo.com> wrote:

> On 04/25/2017 05:44 PM, Khem Raj wrote:
> >
> >
> > On 4/20/17 5:04 PM, Martin Kelly wrote:
> >> Hi,
> >>
> >> After compiling a package with GCC 6, I noticed the following error,
> >> which is a known issue:
> >>
> >> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70129
> >>
> >> The problem is caused by adding -isystem /usr/include, which breaks the
> >> GCC 6's #include_next. I see that Khem Raj already removed this for the
> >> nativesdk [1], but it seems we need a similar fix for other packages, as
> >> we are still adding -isystem in meta/conf/bitbake.conf:
> >>
> >> [snip]
> >> BUILDSDK_CPPFLAGS = "-isystem${STAGING_INCDIR}"
> >> [snip]
> >
> > You must be not using master since it has been fixed by
> >
> http://git.openembedded.org/openembedded-core/commit/meta/conf/bitbake.conf?id=88ec93d152762aedeaa231d2732e9d4b9843795a
> >
>
> The bug is referenced is actually exactly that commit (just in poky
> rather than oe-core); it looks like I mistyped, as I should have said:
>
> [snip]
> export BUILD_CPPFLAGS = "-isystem${STAGING_INCDIR_NATIVE}"
> [snip]


Those are used for building native packages only


> That said, after further root causing the issue, I found that -isystem
> /usr/include was *not* coming from BUILD_CPPFLAGS but instead from QMake
> translating -I /usr/include into -isystem /usr/include, as is mentioned
> in this Qt bug:
>
> https://bugreports.qt.io/browse/QTBUG-53375
>
> So, AFAICT, what I referenced in bitbake is not really an issue, and the
> real problem is related to QMake.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20170426/b1613d18/attachment.html>


More information about the yocto mailing list