All of lore.kernel.org
 help / color / mirror / Atom feed
* [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable
@ 2014-06-19 11:18 Martin Jansa
  2014-07-22 11:20 ` Martin Jansa
  2014-07-23 18:04 ` Khem Raj
  0 siblings, 2 replies; 5+ messages in thread
From: Martin Jansa @ 2014-06-19 11:18 UTC (permalink / raw)
  To: openembedded-core

The original patch says this about MACHINE variables:

    Use MACHINE for sysroot when not building for build host

    Python's machinery replaces directories in sysroot path to match OE's
    staging area sysroots. Earlier we use to have HOST_SYS represent sysroot
    always but now we use MACHINE to represent target sysroots but HOST_SYS
    to represent host sysroot. This patch caters to that difference

But I think we need to find some different solution, because right now the only
user of distutils3 bbclass python3-distribute becames effectivelly MACHINE_ARCH
because of this. Detected with sstate-diff-machines.sh script:

 == Comparing signatures for python3-distribute.do_populate_sysroot.sigdata between qemux86 and qemux86copy ==
  Hash for dependent task python3-distribute_0.6.32.bb.do_install changed from ef2f64ea6aecf1f9c2c6a0f201c52f67 to 7afd17fd366b28cf4a0353c7dd5e1c5b

  $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_install*
    basehash changed from 5311d29c25ff324645de9c17cdefe083 to 2f079b81b13427faddeb040e7a115965
    Variable MACHINE value changed from 'qemux86copy' to 'qemux86'
    Hash for dependent task python3-distribute_0.6.32.bb.do_compile changed from 4fcb29eb2a0df7bef2f9806a0d9cdd92 to e7df3cdd7b82733d69c87f1822b7177b

  $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_compile*
    basehash changed from 870a9e01c2c4eb73dd57451eeb2a7f0c to c061ae11d7f16d74d49f667243a21be0
    Variable MACHINE value changed from 'qemux86copy' to 'qemux86'

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
 meta/classes/distutils3.bbclass | 28 ++++------------------------
 1 file changed, 4 insertions(+), 24 deletions(-)

diff --git a/meta/classes/distutils3.bbclass b/meta/classes/distutils3.bbclass
index bbd645c..8cf29d5 100644
--- a/meta/classes/distutils3.bbclass
+++ b/meta/classes/distutils3.bbclass
@@ -9,14 +9,9 @@ DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
     --install-data=${D}/${datadir}"
 
 distutils3_do_compile() {
-        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
-                SYS=${MACHINE}
-        else
-                SYS=${HOST_SYS}
-        fi
         STAGING_INCDIR=${STAGING_INCDIR} \
         STAGING_LIBDIR=${STAGING_LIBDIR} \
-        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
+        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \
         build ${DISTUTILS_BUILD_ARGS} || \
         bbfatal "${PYTHON_PN} setup.py build_ext execution failed."
@@ -24,42 +19,27 @@ distutils3_do_compile() {
 
 distutils3_stage_headers() {
         install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
-        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
-                SYS=${MACHINE}
-        else
-                SYS=${HOST_SYS}
-        fi
-        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
+        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
         bbfatal "${PYTHON_PN} setup.py install_headers execution failed."
 }
 
 distutils3_stage_all() {
-        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
-                SYS=${MACHINE}
-        else
-                SYS=${HOST_SYS}
-        fi
         STAGING_INCDIR=${STAGING_INCDIR} \
         STAGING_LIBDIR=${STAGING_LIBDIR} \
         install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
         PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
-        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
+        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
         bbfatal "${PYTHON_PN} setup.py install (stage) execution failed."
 }
 
 distutils3_do_install() {
         install -d ${D}${PYTHON_SITEPACKAGES_DIR}
-        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
-                SYS=${MACHINE}
-        else
-                SYS=${HOST_SYS}
-        fi
         STAGING_INCDIR=${STAGING_INCDIR} \
         STAGING_LIBDIR=${STAGING_LIBDIR} \
         PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
-        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
+        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${DISTUTILS_INSTALL_ARGS} || \
         bbfatal "${PYTHON_PN} setup.py install execution failed."
 
-- 
2.0.0



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

* Re: [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable
  2014-06-19 11:18 [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable Martin Jansa
@ 2014-07-22 11:20 ` Martin Jansa
  2014-07-23 18:04 ` Khem Raj
  1 sibling, 0 replies; 5+ messages in thread
From: Martin Jansa @ 2014-07-22 11:20 UTC (permalink / raw)
  To: openembedded-core, Khem Raj

[-- Attachment #1: Type: text/plain, Size: 5038 bytes --]

On Thu, Jun 19, 2014 at 01:18:15PM +0200, Martin Jansa wrote:
> The original patch says this about MACHINE variables:
> 
>     Use MACHINE for sysroot when not building for build host
> 
>     Python's machinery replaces directories in sysroot path to match OE's
>     staging area sysroots. Earlier we use to have HOST_SYS represent sysroot
>     always but now we use MACHINE to represent target sysroots but HOST_SYS
>     to represent host sysroot. This patch caters to that difference
> 
> But I think we need to find some different solution, because right now the only
> user of distutils3 bbclass python3-distribute becames effectivelly MACHINE_ARCH
> because of this. Detected with sstate-diff-machines.sh script:
> 
>  == Comparing signatures for python3-distribute.do_populate_sysroot.sigdata between qemux86 and qemux86copy ==
>   Hash for dependent task python3-distribute_0.6.32.bb.do_install changed from ef2f64ea6aecf1f9c2c6a0f201c52f67 to 7afd17fd366b28cf4a0353c7dd5e1c5b
> 
>   $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_install*
>     basehash changed from 5311d29c25ff324645de9c17cdefe083 to 2f079b81b13427faddeb040e7a115965
>     Variable MACHINE value changed from 'qemux86copy' to 'qemux86'
>     Hash for dependent task python3-distribute_0.6.32.bb.do_compile changed from 4fcb29eb2a0df7bef2f9806a0d9cdd92 to e7df3cdd7b82733d69c87f1822b7177b
> 
>   $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_compile*
>     basehash changed from 870a9e01c2c4eb73dd57451eeb2a7f0c to c061ae11d7f16d74d49f667243a21be0
>     Variable MACHINE value changed from 'qemux86copy' to 'qemux86'

No comment?

+Khem who added this

> 
> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
> ---
>  meta/classes/distutils3.bbclass | 28 ++++------------------------
>  1 file changed, 4 insertions(+), 24 deletions(-)
> 
> diff --git a/meta/classes/distutils3.bbclass b/meta/classes/distutils3.bbclass
> index bbd645c..8cf29d5 100644
> --- a/meta/classes/distutils3.bbclass
> +++ b/meta/classes/distutils3.bbclass
> @@ -9,14 +9,9 @@ DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
>      --install-data=${D}/${datadir}"
>  
>  distutils3_do_compile() {
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
>          STAGING_INCDIR=${STAGING_INCDIR} \
>          STAGING_LIBDIR=${STAGING_LIBDIR} \
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \
>          build ${DISTUTILS_BUILD_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py build_ext execution failed."
> @@ -24,42 +19,27 @@ distutils3_do_compile() {
>  
>  distutils3_stage_headers() {
>          install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py install_headers execution failed."
>  }
>  
>  distutils3_stage_all() {
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
>          STAGING_INCDIR=${STAGING_INCDIR} \
>          STAGING_LIBDIR=${STAGING_LIBDIR} \
>          install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
>          PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py install (stage) execution failed."
>  }
>  
>  distutils3_do_install() {
>          install -d ${D}${PYTHON_SITEPACKAGES_DIR}
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
>          STAGING_INCDIR=${STAGING_INCDIR} \
>          STAGING_LIBDIR=${STAGING_LIBDIR} \
>          PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${DISTUTILS_INSTALL_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py install execution failed."
>  
> -- 
> 2.0.0
> 

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 188 bytes --]

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

* Re: [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable
  2014-06-19 11:18 [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable Martin Jansa
  2014-07-22 11:20 ` Martin Jansa
@ 2014-07-23 18:04 ` Khem Raj
  2014-07-23 19:03   ` Martin Jansa
  1 sibling, 1 reply; 5+ messages in thread
From: Khem Raj @ 2014-07-23 18:04 UTC (permalink / raw)
  To: Martin Jansa; +Cc: Patches and discussions about the oe-core layer

On Thu, Jun 19, 2014 at 4:18 AM, Martin Jansa <martin.jansa@gmail.com> wrote:
> The original patch says this about MACHINE variables:
>
>     Use MACHINE for sysroot when not building for build host
>
>     Python's machinery replaces directories in sysroot path to match OE's
>     staging area sysroots. Earlier we use to have HOST_SYS represent sysroot
>     always but now we use MACHINE to represent target sysroots but HOST_SYS
>     to represent host sysroot. This patch caters to that difference
>
> But I think we need to find some different solution, because right now the only
> user of distutils3 bbclass python3-distribute becames effectivelly MACHINE_ARCH
> because of this. Detected with sstate-diff-machines.sh script:
>
>  == Comparing signatures for python3-distribute.do_populate_sysroot.sigdata between qemux86 and qemux86copy ==
>   Hash for dependent task python3-distribute_0.6.32.bb.do_install changed from ef2f64ea6aecf1f9c2c6a0f201c52f67 to 7afd17fd366b28cf4a0353c7dd5e1c5b
>
>   $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_install*
>     basehash changed from 5311d29c25ff324645de9c17cdefe083 to 2f079b81b13427faddeb040e7a115965
>     Variable MACHINE value changed from 'qemux86copy' to 'qemux86'
>     Hash for dependent task python3-distribute_0.6.32.bb.do_compile changed from 4fcb29eb2a0df7bef2f9806a0d9cdd92 to e7df3cdd7b82733d69c87f1822b7177b
>
>   $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_compile*
>     basehash changed from 870a9e01c2c4eb73dd57451eeb2a7f0c to c061ae11d7f16d74d49f667243a21be0
>     Variable MACHINE value changed from 'qemux86copy' to 'qemux86'
>
> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>


BUILD_SYS is needed in python machinery to construct proper sys root
especially with python3 versions the cross build infra in python is
different. I think this patch would fail to build python3, either we
have to patch it in such a way that whatever sys root OE constructs is
passed directly and used and thereby remove depending on referring to
MACHINE but that would need a bigger patch for python which I was not
willing to carry. if there is another check that can deduce difference
of being compiled native or for target then we can use that check
instead of comparing BUILD_SYS to MACHINE

> ---
>  meta/classes/distutils3.bbclass | 28 ++++------------------------
>  1 file changed, 4 insertions(+), 24 deletions(-)
>
> diff --git a/meta/classes/distutils3.bbclass b/meta/classes/distutils3.bbclass
> index bbd645c..8cf29d5 100644
> --- a/meta/classes/distutils3.bbclass
> +++ b/meta/classes/distutils3.bbclass
> @@ -9,14 +9,9 @@ DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
>      --install-data=${D}/${datadir}"
>
>  distutils3_do_compile() {
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
>          STAGING_INCDIR=${STAGING_INCDIR} \
>          STAGING_LIBDIR=${STAGING_LIBDIR} \
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \
>          build ${DISTUTILS_BUILD_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py build_ext execution failed."
> @@ -24,42 +19,27 @@ distutils3_do_compile() {
>
>  distutils3_stage_headers() {
>          install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py install_headers execution failed."
>  }
>
>  distutils3_stage_all() {
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
>          STAGING_INCDIR=${STAGING_INCDIR} \
>          STAGING_LIBDIR=${STAGING_LIBDIR} \
>          install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
>          PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py install (stage) execution failed."
>  }
>
>  distutils3_do_install() {
>          install -d ${D}${PYTHON_SITEPACKAGES_DIR}
> -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> -                SYS=${MACHINE}
> -        else
> -                SYS=${HOST_SYS}
> -        fi
>          STAGING_INCDIR=${STAGING_INCDIR} \
>          STAGING_LIBDIR=${STAGING_LIBDIR} \
>          PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
> -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
>          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${DISTUTILS_INSTALL_ARGS} || \
>          bbfatal "${PYTHON_PN} setup.py install execution failed."
>
> --
> 2.0.0
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core


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

* Re: [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable
  2014-07-23 18:04 ` Khem Raj
@ 2014-07-23 19:03   ` Martin Jansa
  2014-07-23 19:19     ` Khem Raj
  0 siblings, 1 reply; 5+ messages in thread
From: Martin Jansa @ 2014-07-23 19:03 UTC (permalink / raw)
  To: Khem Raj; +Cc: Patches and discussions about the oe-core layer

[-- Attachment #1: Type: text/plain, Size: 6214 bytes --]

On Wed, Jul 23, 2014 at 11:04:18AM -0700, Khem Raj wrote:
> On Thu, Jun 19, 2014 at 4:18 AM, Martin Jansa <martin.jansa@gmail.com> wrote:
> > The original patch says this about MACHINE variables:
> >
> >     Use MACHINE for sysroot when not building for build host
> >
> >     Python's machinery replaces directories in sysroot path to match OE's
> >     staging area sysroots. Earlier we use to have HOST_SYS represent sysroot
> >     always but now we use MACHINE to represent target sysroots but HOST_SYS
> >     to represent host sysroot. This patch caters to that difference
> >
> > But I think we need to find some different solution, because right now the only
> > user of distutils3 bbclass python3-distribute becames effectivelly MACHINE_ARCH
> > because of this. Detected with sstate-diff-machines.sh script:
> >
> >  == Comparing signatures for python3-distribute.do_populate_sysroot.sigdata between qemux86 and qemux86copy ==
> >   Hash for dependent task python3-distribute_0.6.32.bb.do_install changed from ef2f64ea6aecf1f9c2c6a0f201c52f67 to 7afd17fd366b28cf4a0353c7dd5e1c5b
> >
> >   $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_install*
> >     basehash changed from 5311d29c25ff324645de9c17cdefe083 to 2f079b81b13427faddeb040e7a115965
> >     Variable MACHINE value changed from 'qemux86copy' to 'qemux86'
> >     Hash for dependent task python3-distribute_0.6.32.bb.do_compile changed from 4fcb29eb2a0df7bef2f9806a0d9cdd92 to e7df3cdd7b82733d69c87f1822b7177b
> >
> >   $ bitbake-diffsigs sstate-diff/1403174194/qemux86*/i586*/python3-distribute*/*do_compile*
> >     basehash changed from 870a9e01c2c4eb73dd57451eeb2a7f0c to c061ae11d7f16d74d49f667243a21be0
> >     Variable MACHINE value changed from 'qemux86copy' to 'qemux86'
> >
> > Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
> 
> 
> BUILD_SYS is needed in python machinery to construct proper sys root
> especially with python3 versions the cross build infra in python is
> different. I think this patch would fail to build python3, either we
> have to patch it in such a way that whatever sys root OE constructs is
> passed directly and used and thereby remove depending on referring to
> MACHINE but that would need a bigger patch for python which I was not
> willing to carry. if there is another check that can deduce difference
> of being compiled native or for target then we can use that check
> instead of comparing BUILD_SYS to MACHINE

FWIW: I've this patch in my world builds and I haven't seen any issue
caused by it (python3 builds fine there).

> > ---
> >  meta/classes/distutils3.bbclass | 28 ++++------------------------
> >  1 file changed, 4 insertions(+), 24 deletions(-)
> >
> > diff --git a/meta/classes/distutils3.bbclass b/meta/classes/distutils3.bbclass
> > index bbd645c..8cf29d5 100644
> > --- a/meta/classes/distutils3.bbclass
> > +++ b/meta/classes/distutils3.bbclass
> > @@ -9,14 +9,9 @@ DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
> >      --install-data=${D}/${datadir}"
> >
> >  distutils3_do_compile() {
> > -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> > -                SYS=${MACHINE}
> > -        else
> > -                SYS=${HOST_SYS}
> > -        fi
> >          STAGING_INCDIR=${STAGING_INCDIR} \
> >          STAGING_LIBDIR=${STAGING_LIBDIR} \
> > -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> > +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
> >          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \
> >          build ${DISTUTILS_BUILD_ARGS} || \
> >          bbfatal "${PYTHON_PN} setup.py build_ext execution failed."
> > @@ -24,42 +19,27 @@ distutils3_do_compile() {
> >
> >  distutils3_stage_headers() {
> >          install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
> > -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> > -                SYS=${MACHINE}
> > -        else
> > -                SYS=${HOST_SYS}
> > -        fi
> > -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> > +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
> >          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
> >          bbfatal "${PYTHON_PN} setup.py install_headers execution failed."
> >  }
> >
> >  distutils3_stage_all() {
> > -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> > -                SYS=${MACHINE}
> > -        else
> > -                SYS=${HOST_SYS}
> > -        fi
> >          STAGING_INCDIR=${STAGING_INCDIR} \
> >          STAGING_LIBDIR=${STAGING_LIBDIR} \
> >          install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
> >          PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
> > -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> > +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
> >          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
> >          bbfatal "${PYTHON_PN} setup.py install (stage) execution failed."
> >  }
> >
> >  distutils3_do_install() {
> >          install -d ${D}${PYTHON_SITEPACKAGES_DIR}
> > -        if [ ${BUILD_SYS} != ${HOST_SYS} ]; then
> > -                SYS=${MACHINE}
> > -        else
> > -                SYS=${HOST_SYS}
> > -        fi
> >          STAGING_INCDIR=${STAGING_INCDIR} \
> >          STAGING_LIBDIR=${STAGING_LIBDIR} \
> >          PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
> > -        BUILD_SYS=${BUILD_SYS} HOST_SYS=${SYS} \
> > +        BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
> >          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${DISTUTILS_INSTALL_ARGS} || \
> >          bbfatal "${PYTHON_PN} setup.py install execution failed."
> >
> > --
> > 2.0.0
> >
> > --
> > _______________________________________________
> > Openembedded-core mailing list
> > Openembedded-core@lists.openembedded.org
> > http://lists.openembedded.org/mailman/listinfo/openembedded-core

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 188 bytes --]

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

* Re: [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable
  2014-07-23 19:03   ` Martin Jansa
@ 2014-07-23 19:19     ` Khem Raj
  0 siblings, 0 replies; 5+ messages in thread
From: Khem Raj @ 2014-07-23 19:19 UTC (permalink / raw)
  To: Martin Jansa; +Cc: Patches and discussions about the oe-core layer

On Wed, Jul 23, 2014 at 12:03 PM, Martin Jansa <martin.jansa@gmail.com> wrote:
> FWIW: I've this patch in my world builds and I haven't seen any issue
> caused by it (python3 builds fine there).

thats interesting. Can you make sure that there is no host system
intrusion happening ?


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

end of thread, other threads:[~2014-07-23 19:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-19 11:18 [DO-NOT-MERGE][RFC][PATCH] DO-NOT-MERGE: distutils3.bbclass: Don't use MACHINE variable Martin Jansa
2014-07-22 11:20 ` Martin Jansa
2014-07-23 18:04 ` Khem Raj
2014-07-23 19:03   ` Martin Jansa
2014-07-23 19:19     ` Khem Raj

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.