Message ID | 20180731170541.13620-2-ross.burton@intel.com |
---|---|
State | Accepted |
Commit | 96ccdadb8473daa3c9c2e1cb42fbdff1edd270d6 |
Headers | show |
Series | [1/2] meson: don't dump full error log on failure | expand |
On Tue, Jul 31, 2018 at 10:06 AM Ross Burton <ross.burton@intel.com> wrote: > Instead of both classes using ${PYTHON_PN} (which is set by python-dir and > python3-dir), hardcode the right values so that it is possible to inherit > both > pythonnative and python3native at the same time. > > If both are inherited then both native Pythons are available, but the last > to be > inherited will be the one to set PYTHON. Not particularly thrilled about this usage it seems error prone > > > Signed-off-by: Ross Burton <ross.burton@intel.com> > --- > meta/classes/python3native.bbclass | 6 +++--- > meta/classes/pythonnative.bbclass | 6 +++--- > 2 files changed, 6 insertions(+), 6 deletions(-) > > diff --git a/meta/classes/python3native.bbclass > b/meta/classes/python3native.bbclass > index 89665efee8b..da12a714703 100644 > --- a/meta/classes/python3native.bbclass > +++ b/meta/classes/python3native.bbclass > @@ -1,8 +1,8 @@ > inherit python3-dir > > -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" > -EXTRANATIVEPATH += "${PYTHON_PN}-native" > -DEPENDS_append = " ${PYTHON_PN}-native " > +PYTHON="${STAGING_BINDIR_NATIVE}/python3-native/python3" > +EXTRANATIVEPATH += "python3-native" > +DEPENDS_append = " python3-native " > > # python-config and other scripts are using distutils modules > # which we patch to access these variables > diff --git a/meta/classes/pythonnative.bbclass > b/meta/classes/pythonnative.bbclass > index 4cc8b2769c2..ae6600cd155 100644 > --- a/meta/classes/pythonnative.bbclass > +++ b/meta/classes/pythonnative.bbclass > @@ -1,11 +1,11 @@ > > inherit python-dir > > -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" > +PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python" > # PYTHON_EXECUTABLE is used by cmake > PYTHON_EXECUTABLE="${PYTHON}" > -EXTRANATIVEPATH += "${PYTHON_PN}-native" > -DEPENDS_append = " ${PYTHON_PN}-native " > +EXTRANATIVEPATH += "python-native" > +DEPENDS_append = " python-native " > > # python-config and other scripts are using distutils modules > # which we patch to access these variables > -- > 2.11.0 > > -- > _______________________________________________ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org > http://lists.openembedded.org/mailman/listinfo/openembedded-core > <div><br></div><div><br><div class="gmail_quote"><div dir="ltr">On Tue, Jul 31, 2018 at 10:06 AM Ross Burton <<a href="mailto:ross.burton@intel.com">ross.burton@intel.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Instead of both classes using ${PYTHON_PN} (which is set by python-dir and<br> python3-dir), hardcode the right values so that it is possible to inherit both<br> pythonnative and python3native at the same time.<br> <br> If both are inherited then both native Pythons are available, but the last to be<br> inherited will be the one to set PYTHON.</blockquote><div dir="auto"><br></div><div dir="auto">Not particularly thrilled about this usage it seems error prone</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br> <br> Signed-off-by: Ross Burton <<a href="mailto:ross.burton@intel.com" target="_blank">ross.burton@intel.com</a>><br> ---<br> meta/classes/python3native.bbclass | 6 +++---<br> meta/classes/pythonnative.bbclass | 6 +++---<br> 2 files changed, 6 insertions(+), 6 deletions(-)<br> <br> diff --git a/meta/classes/python3native.bbclass b/meta/classes/python3native.bbclass<br> index 89665efee8b..da12a714703 100644<br> --- a/meta/classes/python3native.bbclass<br> +++ b/meta/classes/python3native.bbclass<br> @@ -1,8 +1,8 @@<br> inherit python3-dir<br> <br> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}"<br> -EXTRANATIVEPATH += "${PYTHON_PN}-native"<br> -DEPENDS_append = " ${PYTHON_PN}-native "<br> +PYTHON="${STAGING_BINDIR_NATIVE}/python3-native/python3"<br> +EXTRANATIVEPATH += "python3-native"<br> +DEPENDS_append = " python3-native "<br> <br> # python-config and other scripts are using distutils modules<br> # which we patch to access these variables<br> diff --git a/meta/classes/pythonnative.bbclass b/meta/classes/pythonnative.bbclass<br> index 4cc8b2769c2..ae6600cd155 100644<br> --- a/meta/classes/pythonnative.bbclass<br> +++ b/meta/classes/pythonnative.bbclass<br> @@ -1,11 +1,11 @@<br> <br> inherit python-dir<br> <br> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}"<br> +PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python"<br> # PYTHON_EXECUTABLE is used by cmake<br> PYTHON_EXECUTABLE="${PYTHON}"<br> -EXTRANATIVEPATH += "${PYTHON_PN}-native"<br> -DEPENDS_append = " ${PYTHON_PN}-native "<br> +EXTRANATIVEPATH += "python-native"<br> +DEPENDS_append = " python-native "<br> <br> # python-config and other scripts are using distutils modules<br> # which we patch to access these variables<br> -- <br> 2.11.0<br> <br> -- <br> _______________________________________________<br> Openembedded-core mailing list<br> <a href="mailto:Openembedded-core@lists.openembedded.org" target="_blank">Openembedded-core@lists.openembedded.org</a><br> <a href="http://lists.openembedded.org/mailman/listinfo/openembedded-core" rel="noreferrer" target="_blank">http://lists.openembedded.org/mailman/listinfo/openembedded-core</a><br> </blockquote></div></div> -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
The last to be inherited behaviour? That's the same as the current behaviour, apart from after my change both pythons are available via PATH. The only change is that inheriting the second class doesn't wipe out the first class. Ross On 2 August 2018 at 22:05, Khem Raj <raj.khem@gmail.com> wrote: > > > On Tue, Jul 31, 2018 at 10:06 AM Ross Burton <ross.burton@intel.com> wrote: >> >> Instead of both classes using ${PYTHON_PN} (which is set by python-dir and >> python3-dir), hardcode the right values so that it is possible to inherit >> both >> pythonnative and python3native at the same time. >> >> If both are inherited then both native Pythons are available, but the last >> to be >> inherited will be the one to set PYTHON. > > > Not particularly thrilled about this usage it seems error prone >> >> >> >> Signed-off-by: Ross Burton <ross.burton@intel.com> >> --- >> meta/classes/python3native.bbclass | 6 +++--- >> meta/classes/pythonnative.bbclass | 6 +++--- >> 2 files changed, 6 insertions(+), 6 deletions(-) >> >> diff --git a/meta/classes/python3native.bbclass >> b/meta/classes/python3native.bbclass >> index 89665efee8b..da12a714703 100644 >> --- a/meta/classes/python3native.bbclass >> +++ b/meta/classes/python3native.bbclass >> @@ -1,8 +1,8 @@ >> inherit python3-dir >> >> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" >> -EXTRANATIVEPATH += "${PYTHON_PN}-native" >> -DEPENDS_append = " ${PYTHON_PN}-native " >> +PYTHON="${STAGING_BINDIR_NATIVE}/python3-native/python3" >> +EXTRANATIVEPATH += "python3-native" >> +DEPENDS_append = " python3-native " >> >> # python-config and other scripts are using distutils modules >> # which we patch to access these variables >> diff --git a/meta/classes/pythonnative.bbclass >> b/meta/classes/pythonnative.bbclass >> index 4cc8b2769c2..ae6600cd155 100644 >> --- a/meta/classes/pythonnative.bbclass >> +++ b/meta/classes/pythonnative.bbclass >> @@ -1,11 +1,11 @@ >> >> inherit python-dir >> >> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" >> +PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python" >> # PYTHON_EXECUTABLE is used by cmake >> PYTHON_EXECUTABLE="${PYTHON}" >> -EXTRANATIVEPATH += "${PYTHON_PN}-native" >> -DEPENDS_append = " ${PYTHON_PN}-native " >> +EXTRANATIVEPATH += "python-native" >> +DEPENDS_append = " python-native " >> >> # python-config and other scripts are using distutils modules >> # which we patch to access these variables >> -- >> 2.11.0 >> >> -- >> _______________________________________________ >> Openembedded-core mailing list >> Openembedded-core@lists.openembedded.org >> http://lists.openembedded.org/mailman/listinfo/openembedded-core -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
On Thu, Aug 2, 2018 at 3:50 PM Burton, Ross <ross.burton@intel.com> wrote: > The last to be inherited behaviour? That's the same as the current > behaviour, apart from after my change both pythons are available via > PATH. > > The only change is that inheriting the second class doesn't wipe out > the first class. Ok may be then this variable should be made overridable so a recipe can select it to be one of two otherwise the default remains as you said > > > Ross > > On 2 August 2018 at 22:05, Khem Raj <raj.khem@gmail.com> wrote: > > > > > > On Tue, Jul 31, 2018 at 10:06 AM Ross Burton <ross.burton@intel.com> > wrote: > >> > >> Instead of both classes using ${PYTHON_PN} (which is set by python-dir > and > >> python3-dir), hardcode the right values so that it is possible to > inherit > >> both > >> pythonnative and python3native at the same time. > >> > >> If both are inherited then both native Pythons are available, but the > last > >> to be > >> inherited will be the one to set PYTHON. > > > > > > Not particularly thrilled about this usage it seems error prone > >> > >> > >> > >> Signed-off-by: Ross Burton <ross.burton@intel.com> > >> --- > >> meta/classes/python3native.bbclass | 6 +++--- > >> meta/classes/pythonnative.bbclass | 6 +++--- > >> 2 files changed, 6 insertions(+), 6 deletions(-) > >> > >> diff --git a/meta/classes/python3native.bbclass > >> b/meta/classes/python3native.bbclass > >> index 89665efee8b..da12a714703 100644 > >> --- a/meta/classes/python3native.bbclass > >> +++ b/meta/classes/python3native.bbclass > >> @@ -1,8 +1,8 @@ > >> inherit python3-dir > >> > >> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" > >> -EXTRANATIVEPATH += "${PYTHON_PN}-native" > >> -DEPENDS_append = " ${PYTHON_PN}-native " > >> +PYTHON="${STAGING_BINDIR_NATIVE}/python3-native/python3" > >> +EXTRANATIVEPATH += "python3-native" > >> +DEPENDS_append = " python3-native " > >> > >> # python-config and other scripts are using distutils modules > >> # which we patch to access these variables > >> diff --git a/meta/classes/pythonnative.bbclass > >> b/meta/classes/pythonnative.bbclass > >> index 4cc8b2769c2..ae6600cd155 100644 > >> --- a/meta/classes/pythonnative.bbclass > >> +++ b/meta/classes/pythonnative.bbclass > >> @@ -1,11 +1,11 @@ > >> > >> inherit python-dir > >> > >> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" > >> +PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python" > >> # PYTHON_EXECUTABLE is used by cmake > >> PYTHON_EXECUTABLE="${PYTHON}" > >> -EXTRANATIVEPATH += "${PYTHON_PN}-native" > >> -DEPENDS_append = " ${PYTHON_PN}-native " > >> +EXTRANATIVEPATH += "python-native" > >> +DEPENDS_append = " python-native " > >> > >> # python-config and other scripts are using distutils modules > >> # which we patch to access these variables > >> -- > >> 2.11.0 > >> > >> -- > >> _______________________________________________ > >> Openembedded-core mailing list > >> Openembedded-core@lists.openembedded.org > >> http://lists.openembedded.org/mailman/listinfo/openembedded-core > <div><br></div><div><br><div class="gmail_quote"><div dir="ltr">On Thu, Aug 2, 2018 at 3:50 PM Burton, Ross <<a href="mailto:ross.burton@intel.com">ross.burton@intel.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">The last to be inherited behaviour? That's the same as the current<br> behaviour, apart from after my change both pythons are available via<br> PATH.<br> <br> The only change is that inheriting the second class doesn't wipe out<br> the first class.</blockquote><div dir="auto"><br></div><div dir="auto">Ok may be then this variable should be made overridable so a recipe can select it to be one of two otherwise the default remains as you said </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br> <br> Ross<br> <br> On 2 August 2018 at 22:05, Khem Raj <<a href="mailto:raj.khem@gmail.com" target="_blank">raj.khem@gmail.com</a>> wrote:<br> ><br> ><br> > On Tue, Jul 31, 2018 at 10:06 AM Ross Burton <<a href="mailto:ross.burton@intel.com" target="_blank">ross.burton@intel.com</a>> wrote:<br> >><br> >> Instead of both classes using ${PYTHON_PN} (which is set by python-dir and<br> >> python3-dir), hardcode the right values so that it is possible to inherit<br> >> both<br> >> pythonnative and python3native at the same time.<br> >><br> >> If both are inherited then both native Pythons are available, but the last<br> >> to be<br> >> inherited will be the one to set PYTHON.<br> ><br> ><br> > Not particularly thrilled about this usage it seems error prone<br> >><br> >><br> >><br> >> Signed-off-by: Ross Burton <<a href="mailto:ross.burton@intel.com" target="_blank">ross.burton@intel.com</a>><br> >> ---<br> >> meta/classes/python3native.bbclass | 6 +++---<br> >> meta/classes/pythonnative.bbclass | 6 +++---<br> >> 2 files changed, 6 insertions(+), 6 deletions(-)<br> >><br> >> diff --git a/meta/classes/python3native.bbclass<br> >> b/meta/classes/python3native.bbclass<br> >> index 89665efee8b..da12a714703 100644<br> >> --- a/meta/classes/python3native.bbclass<br> >> +++ b/meta/classes/python3native.bbclass<br> >> @@ -1,8 +1,8 @@<br> >> inherit python3-dir<br> >><br> >> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}"<br> >> -EXTRANATIVEPATH += "${PYTHON_PN}-native"<br> >> -DEPENDS_append = " ${PYTHON_PN}-native "<br> >> +PYTHON="${STAGING_BINDIR_NATIVE}/python3-native/python3"<br> >> +EXTRANATIVEPATH += "python3-native"<br> >> +DEPENDS_append = " python3-native "<br> >><br> >> # python-config and other scripts are using distutils modules<br> >> # which we patch to access these variables<br> >> diff --git a/meta/classes/pythonnative.bbclass<br> >> b/meta/classes/pythonnative.bbclass<br> >> index 4cc8b2769c2..ae6600cd155 100644<br> >> --- a/meta/classes/pythonnative.bbclass<br> >> +++ b/meta/classes/pythonnative.bbclass<br> >> @@ -1,11 +1,11 @@<br> >><br> >> inherit python-dir<br> >><br> >> -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}"<br> >> +PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python"<br> >> # PYTHON_EXECUTABLE is used by cmake<br> >> PYTHON_EXECUTABLE="${PYTHON}"<br> >> -EXTRANATIVEPATH += "${PYTHON_PN}-native"<br> >> -DEPENDS_append = " ${PYTHON_PN}-native "<br> >> +EXTRANATIVEPATH += "python-native"<br> >> +DEPENDS_append = " python-native "<br> >><br> >> # python-config and other scripts are using distutils modules<br> >> # which we patch to access these variables<br> >> --<br> >> 2.11.0<br> >><br> >> --<br> >> _______________________________________________<br> >> Openembedded-core mailing list<br> >> <a href="mailto:Openembedded-core@lists.openembedded.org" target="_blank">Openembedded-core@lists.openembedded.org</a><br> >> <a href="http://lists.openembedded.org/mailman/listinfo/openembedded-core" rel="noreferrer" target="_blank">http://lists.openembedded.org/mailman/listinfo/openembedded-core</a><br> </blockquote></div></div> -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
diff --git a/meta/classes/python3native.bbclass b/meta/classes/python3native.bbclass index 89665efee8b..da12a714703 100644 --- a/meta/classes/python3native.bbclass +++ b/meta/classes/python3native.bbclass @@ -1,8 +1,8 @@ inherit python3-dir -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" -EXTRANATIVEPATH += "${PYTHON_PN}-native" -DEPENDS_append = " ${PYTHON_PN}-native " +PYTHON="${STAGING_BINDIR_NATIVE}/python3-native/python3" +EXTRANATIVEPATH += "python3-native" +DEPENDS_append = " python3-native " # python-config and other scripts are using distutils modules # which we patch to access these variables diff --git a/meta/classes/pythonnative.bbclass b/meta/classes/pythonnative.bbclass index 4cc8b2769c2..ae6600cd155 100644 --- a/meta/classes/pythonnative.bbclass +++ b/meta/classes/pythonnative.bbclass @@ -1,11 +1,11 @@ inherit python-dir -PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" +PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python" # PYTHON_EXECUTABLE is used by cmake PYTHON_EXECUTABLE="${PYTHON}" -EXTRANATIVEPATH += "${PYTHON_PN}-native" -DEPENDS_append = " ${PYTHON_PN}-native " +EXTRANATIVEPATH += "python-native" +DEPENDS_append = " python-native " # python-config and other scripts are using distutils modules # which we patch to access these variables
Instead of both classes using ${PYTHON_PN} (which is set by python-dir and python3-dir), hardcode the right values so that it is possible to inherit both pythonnative and python3native at the same time. If both are inherited then both native Pythons are available, but the last to be inherited will be the one to set PYTHON. Signed-off-by: Ross Burton <ross.burton@intel.com> --- meta/classes/python3native.bbclass | 6 +++--- meta/classes/pythonnative.bbclass | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core