All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Fix warning for nativesdk distutils recipes
@ 2017-12-05 16:30 Noé Rubinstein
  2017-12-05 17:03 ` ✗ patchtest: failure for " Patchwork
  0 siblings, 1 reply; 2+ messages in thread
From: Noé Rubinstein @ 2017-12-05 16:30 UTC (permalink / raw)
  To: openembedded-core

When building a setuptools-based recipe for the nativesdk, Bitbake
complains about the missing dependency on 'env' (normally provided by
coreutils):

    WARNING: nativesdk-foobar-baz-2.1.0-r0 do_package_qa: QA Issue:
    /opt/foobar-os/sysroots/x86_64-foobarsdk-linux/usr/bin/foobar_baz
    contained in package nativesdk-foobar-baz requires
    /opt/foobar-os/sysroots/x86_64-foobarsdk-linux/usr/bin/env, but no
    providers found in RDEPENDS_nativesdk-foobar-baz? [file-rdeps]

That's because distutils.bbclass modifies the shebang line of all
installed Python scripts, which would otherwise point to python-native's
Python binary instead of the target's Python binary.

Doing so, it introduces a dependency on 'env', which should not be
needed as we know full well which Python binary we want.

This commit replaces the call to env with a direct call to the installed
Python binary.
---
 meta/classes/distutils.bbclass  | 4 ++--
 meta/classes/distutils3.bbclass | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/meta/classes/distutils.bbclass b/meta/classes/distutils.bbclass
index 1930c35292..9f048000ce 100644
--- a/meta/classes/distutils.bbclass
+++ b/meta/classes/distutils.bbclass
@@ -44,7 +44,7 @@ distutils_do_install() {
         if test -e ${D}${bindir} ; then	
             for i in ${D}${bindir}/* ; do \
                 if [ ${PN} != "${BPN}-native" ]; then
-			sed -i -e s:${STAGING_BINDIR_NATIVE}/python-native/python:${USRBINPATH}/env\ python:g $i
+			sed -i -e s:${STAGING_BINDIR_NATIVE}/python-native/python:${USRBINPATH}/python:g $i
 		fi
                 sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
             done
@@ -53,7 +53,7 @@ distutils_do_install() {
         if [ -e ${D}${sbindir} ]; then
             for i in ${D}${sbindir}/* ; do \
                 if [ ${PN} != "${BPN}-native" ]; then
-			sed -i -e s:${STAGING_BINDIR_NATIVE}/python-native/python:${USRBINPATH}/env\ python:g $i
+			sed -i -e s:${STAGING_BINDIR_NATIVE}/python-native/python:${USRBINPATH}/python:g $i
 		fi
                 sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
             done
diff --git a/meta/classes/distutils3.bbclass b/meta/classes/distutils3.bbclass
index 6c30306882..d255bcf225 100644
--- a/meta/classes/distutils3.bbclass
+++ b/meta/classes/distutils3.bbclass
@@ -47,14 +47,14 @@ distutils3_do_install() {
 
         if test -e ${D}${bindir} ; then	
             for i in ${D}${bindir}/* ; do \
-                sed -i -e s:${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}:${USRBINPATH}/env\ ${PYTHON_PN}:g $i
+                sed -i -e s:${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}:${USRBINPATH}/${PYTHON_PN}:g $i
                 sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
             done
         fi
 
         if test -e ${D}${sbindir}; then
             for i in ${D}${sbindir}/* ; do \
-                sed -i -e s:${STAGING_BINDIR_NATIVE}/python-${PYTHON_PN}/${PYTHON_PN}:${USRBINPATH}/env\ ${PYTHON_PN}:g $i
+                sed -i -e s:${STAGING_BINDIR_NATIVE}/python-${PYTHON_PN}/${PYTHON_PN}:${USRBINPATH}/${PYTHON_PN}:g $i
                 sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
             done
         fi
-- 
2.15.0



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

* ✗ patchtest: failure for Fix warning for nativesdk distutils recipes
  2017-12-05 16:30 [PATCH] Fix warning for nativesdk distutils recipes Noé Rubinstein
@ 2017-12-05 17:03 ` Patchwork
  0 siblings, 0 replies; 2+ messages in thread
From: Patchwork @ 2017-12-05 17:03 UTC (permalink / raw)
  To: Noé Rubinstein; +Cc: openembedded-core

== Series Details ==

Series: Fix warning for nativesdk distutils recipes
Revision: 1
URL   : https://patchwork.openembedded.org/series/10080/
State : failure

== Summary ==


Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:



* Patch            Fix warning for nativesdk distutils recipes
 Issue             Shortlog does not follow expected format [test_shortlog_format] 
  Suggested fix    Commit shortlog (first line of commit message) should follow the format "<target>: <summary>"

* Patch            Fix warning for nativesdk distutils recipes
 Issue             Patch is missing Signed-off-by [test_signed_off_by_presence] 
  Suggested fix    Sign off the patch (either manually or with "git commit --amend -s")



If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).

---
Guidelines:     https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite:     http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe



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

end of thread, other threads:[~2017-12-05 17:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-05 16:30 [PATCH] Fix warning for nativesdk distutils recipes Noé Rubinstein
2017-12-05 17:03 ` ✗ patchtest: failure for " Patchwork

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.