All of lore.kernel.org
 help / color / mirror / Atom feed
From: "João Henrique Ferreira de Freitas" <joaohf@gmail.com>
To: Otavio Salvador <otavio@ossystems.com.br>
Cc: Patches and discussions about the oe-core layer
	<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH v2 1/2] python-distribute: add nativesdk to BBCLASSEXTEND
Date: Wed, 16 Jul 2014 21:50:23 -0300	[thread overview]
Message-ID: <53C71DCF.9040702@gmail.com> (raw)
In-Reply-To: <CAP9ODKok9mWnjgmdciVJ7GaENzX09VUn17RSwoB7SGJAeipPSw@mail.gmail.com>

Hi Otavio,

Em 15-07-2014 10:35, Otavio Salvador escreveu:
> On Mon, Jul 14, 2014 at 7:55 PM, João Henrique Ferreira de Freitas
> <joaohf@gmail.com> wrote:
>> Without this, python tools that need python-distribute doesn't install
>> in SDK generated by OE.
>>
>> Signed-off-by: João Henrique Ferreira de Freitas <joaohf@gmail.com>
>> ---
>>   meta/recipes-devtools/python/python-distribute_0.6.32.bb | 8 +++++++-
>>   1 file changed, 7 insertions(+), 1 deletion(-)
>>
>> diff --git a/meta/recipes-devtools/python/python-distribute_0.6.32.bb b/meta/recipes-devtools/python/python-distribute_0.6.32.bb
>> index 58bb8b4..7000145 100644
>> --- a/meta/recipes-devtools/python/python-distribute_0.6.32.bb
>> +++ b/meta/recipes-devtools/python/python-distribute_0.6.32.bb
>> @@ -39,6 +39,12 @@ do_install_append() {
>>       echo "./${SRCNAME}-${PV}-py${PYTHON_BASEVERSION}.egg" > ${D}${PYTHON_SITEPACKAGES_DIR}/setuptools.pth
>>   }
>>
>> +do_install_append_class-nativesdk() {
>> +       sed -i -e '1s|^#!.*|#!/usr/bin/env python|' ${D}${PYTHON_SITEPACKAGES_DIR}/distribute-${PV}-py${PYTHON_BASEVERSION}.egg/setuptools/tests/test_resources.py
>> +       sed -i -e '1s|^#!.*|#!/usr/bin/env python|' ${D}${bindir}/easy_install
>> +       sed -i -e '1s|^#!.*|#!/usr/bin/env python|' ${D}${bindir}/easy_install-${PYTHON_BASEVERSION}
>> +}
> Couldn't this be done unconditionally for all target types?
> "/usr/bin/env python" should work fine in target as well, no?
>
I don't know if I fully understood your question...


Do you mean by 'all target types' like native, nativesdk ?

In some recipes (gnome-doc-utils.inc, createrepo_0.4.11.bb) , this 
pattern was used:

----
# Wrap the python script since the native python is
# ${bindir}/python-native/python, and the "#! /usr/bin/env python" can't
# find it since it is not in PATH.
do_install_append_class-native () {
  ...
   sed -i -e 's|^#!.*/usr/bin/env python|#! /usr/bin/env nativepython|' $i
  ...
}
----

Sometimes I feel really lost when need to fixes things like that. What 
is the correct way?

Without do_install_append_class-nativesdk() I got:

Computing transaction...error: Can't install nativesdk-python-distribute-0.6.32-ml5@x86_64_nativesdk: no package provides /usr/bin/python


Thanks.

-- 
João Henrique Ferreira de Freitas - joaohf_at_gmail.com
Campinas-SP-Brasil



  reply	other threads:[~2014-07-17  0:50 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-02  1:58 [PATCH 0/2] add nativesdk to BBCLASSEXTEND to python-distribute and to fix the side effect of it João Henrique Ferreira de Freitas
2014-07-02  1:58 ` [PATCH 1/2] python-distribute: add nativesdk to BBCLASSEXTEND João Henrique Ferreira de Freitas
2014-07-02  1:58 ` [PATCH 2/2] populate_sdk_base: ensure that filenames with empty space character are handled João Henrique Ferreira de Freitas
2014-07-09  0:19   ` Saul Wold
2014-07-09  1:33     ` Otavio Salvador
2014-07-12 13:20       ` João Henrique Ferreira de Freitas
2014-07-14 15:10         ` Otavio Salvador
2014-07-14 22:55 ` [PATCH v2 0/2] add nativesdk to BBCLASSEXTEND to python-distribute and to fix the side effect of it João Henrique Ferreira de Freitas
2014-07-14 22:55   ` [PATCH v2 1/2] python-distribute: add nativesdk to BBCLASSEXTEND João Henrique Ferreira de Freitas
2014-07-15 13:35     ` Otavio Salvador
2014-07-17  0:50       ` João Henrique Ferreira de Freitas [this message]
2014-07-17 11:33         ` Otavio Salvador
2014-07-14 22:55   ` [PATCH v2 2/2] populate_sdk_base: ensure that filenames with empty space character are handled João Henrique Ferreira de Freitas
2014-07-15 13:33     ` Otavio Salvador
2014-07-16  3:01       ` João Henrique Ferreira de Freitas
2014-07-18  3:09   ` [PATCH v3 0/2] add nativesdk to BBCLASSEXTEND to python-distribute and to fix the side effect of it João Henrique Ferreira de Freitas
2014-07-18  3:09     ` [PATCH v3 1/2] python-distribute: add nativesdk to BBCLASSEXTEND João Henrique Ferreira de Freitas
2014-07-18  3:09     ` [PATCH v3 2/2] populate_sdk_base: ensure that filenames with empty space character are handled João Henrique Ferreira de Freitas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53C71DCF.9040702@gmail.com \
    --to=joaohf@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=otavio@ossystems.com.br \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.