* [dpdk-dev] meson support : cross compile issues
@ 2018-02-27 14:38 Hemant Agrawal
2018-02-27 14:52 ` Bruce Richardson
0 siblings, 1 reply; 3+ messages in thread
From: Hemant Agrawal @ 2018-02-27 14:38 UTC (permalink / raw)
To: Richardson, Bruce, dev
Cc: Shreyansh Jain, Akhil Goyal, Herbert Guan, Bhagavatula, Pavan
Hi,
How do we set CROSS COMPILE kernel path support. E.g. something equivalent to RTE_KERNELDIR for Makefile
* Currently the Igb_uio compilation fails.
* Also, there is no check to disable igb_uio compilation by flag e.g. CONFIG_RTE_EAL_IGB_UIO=n
Other minor issue observed is that though the cross compile is set as 6.3, the gcc 7 flags (which is my host compiler version) is getting enabled. Causing following errors:
../drivers/bus/dpaa/dpaa_bus.c: At top level:
cc1: warning: unrecognized command line option ‘-Wno-format-truncation’
cc1: warning: unrecognized command line option ‘-Wno-address-of-packed-member’
Regards,
Hemant
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] meson support : cross compile issues
2018-02-27 14:38 [dpdk-dev] meson support : cross compile issues Hemant Agrawal
@ 2018-02-27 14:52 ` Bruce Richardson
2018-02-28 5:16 ` Hemant Agrawal
0 siblings, 1 reply; 3+ messages in thread
From: Bruce Richardson @ 2018-02-27 14:52 UTC (permalink / raw)
To: Hemant Agrawal
Cc: dev, Shreyansh Jain, Akhil Goyal, Herbert Guan, Bhagavatula, Pavan
On Tue, Feb 27, 2018 at 02:38:53PM +0000, Hemant Agrawal wrote:
> Hi,
>
> How do we set CROSS COMPILE kernel path support. E.g. something equivalent to RTE_KERNELDIR for Makefile
>
> * Currently the Igb_uio compilation fails.
> * Also, there is no check to disable igb_uio compilation by flag e.g. CONFIG_RTE_EAL_IGB_UIO=n
>
>
I have not had time to look at the cross-compilation of kernel modules
yet, so patches welcome. :-)
However, it should be possible to disable the kernel modules generally
using "enable_kmods" option (see meson_options.txt)
>
> Other minor issue observed is that though the cross compile is set as 6.3, the gcc 7 flags (which is my host compiler version) is getting enabled. Causing following errors:
>
Actually, this is a gcc quirk. GCC does not report an error for
cmdline flags disabling unknown warnings, unless other errors are
displayed. This means that when meson tries the options, GCC reports as
supporting them. It also means that it's not a problem when you do see
them - just fix the other errors and the warnings about the flags will
disappear.
See: https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html
"However, if the -Wno- form is used, the behavior is slightly different:
no diagnostic is produced for -Wno-unknown-warning unless other
diagnostics are being produced. This allows the use of new -Wno- options
with old compilers, but if something goes wrong, the compiler warns that
an unrecognized option is present"
> ../drivers/bus/dpaa/dpaa_bus.c: At top level:
>
> cc1: warning: unrecognized command line option ‘-Wno-format-truncation’
>
> cc1: warning: unrecognized command line option ‘-Wno-address-of-packed-member’
>
> Regards,
> Hemant
>
Regards,
/Bruce
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] meson support : cross compile issues
2018-02-27 14:52 ` Bruce Richardson
@ 2018-02-28 5:16 ` Hemant Agrawal
0 siblings, 0 replies; 3+ messages in thread
From: Hemant Agrawal @ 2018-02-28 5:16 UTC (permalink / raw)
To: Bruce Richardson
Cc: dev, Shreyansh Jain, Akhil Goyal, Herbert Guan, Bhagavatula, Pavan
Hi Bruce,
> On Tue, Feb 27, 2018 at 02:38:53PM +0000, Hemant Agrawal wrote:
> > Hi,
> >
> > How do we set CROSS COMPILE kernel path support. E.g. something
> > equivalent to RTE_KERNELDIR for Makefile
> >
> > * Currently the Igb_uio compilation fails.
> > * Also, there is no check to disable igb_uio compilation by flag e.g.
> CONFIG_RTE_EAL_IGB_UIO=n
> >
> >
>
> I have not had time to look at the cross-compilation of kernel modules yet, so
> patches welcome. :-) However, it should be possible to disable the kernel
> modules generally using "enable_kmods" option (see meson_options.txt)
[Hemant] setting kernel_dir in meson_options.txt worked for me.
>
> >
> > Other minor issue observed is that though the cross compile is set as 6.3, the
> gcc 7 flags (which is my host compiler version) is getting enabled. Causing
> following errors:
> >
>
> Actually, this is a gcc quirk. GCC does not report an error for cmdline flags
> disabling unknown warnings, unless other errors are displayed. This means that
> when meson tries the options, GCC reports as supporting them. It also means
> that it's not a problem when you do see them - just fix the other errors and the
> warnings about the flags will disappear.
>
> See:
> https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgcc.gn
> u.org%2Fonlinedocs%2Fgcc%2FWarning-
> Options.html&data=02%7C01%7Chemant.agrawal%40nxp.com%7Cbe391f8ced
> e54b43679808d57df1b4e4%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C
> 1%7C636553399436715184&sdata=u3wSqw8DJ6dROat%2B%2BUr2EeusPmv90Z
> GPYRvitUuWIHE%3D&reserved=0
> "However, if the -Wno- form is used, the behavior is slightly different:
> no diagnostic is produced for -Wno-unknown-warning unless other diagnostics
> are being produced. This allows the use of new -Wno- options with old
> compilers, but if something goes wrong, the compiler warns that an
> unrecognized option is present"
[Hemant] Thanks it helps.
>
>
> > ../drivers/bus/dpaa/dpaa_bus.c: At top level:
> >
> > cc1: warning: unrecognized command line option ‘-Wno-format-truncation’
> >
> > cc1: warning: unrecognized command line option ‘-Wno-address-of-packed-
> member’
> >
> > Regards,
> > Hemant
> >
> Regards,
> /Bruce
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-02-28 5:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-27 14:38 [dpdk-dev] meson support : cross compile issues Hemant Agrawal
2018-02-27 14:52 ` Bruce Richardson
2018-02-28 5:16 ` Hemant Agrawal
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).