Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Richard Tollerton <rich.tollerton@ni.com>
Cc: paul.eggleton@linux.intel.com, gratian.crisan@ni.com,
	ken.sharp@ni.com, openembedded-core@lists.openembedded.org
Subject: Re: [dylan, master][PATCH] populate_sdk_base: Fix relocate_sdk.py execution on Arch
Date: Fri, 04 Oct 2013 12:33:36 +0100	[thread overview]
Message-ID: <1380886416.18603.598.camel@ted> (raw)
In-Reply-To: <1380755881-17842-1-git-send-email-rich.tollerton@ni.com>

On Wed, 2013-10-02 at 18:18 -0500, Richard Tollerton wrote:
> relocate_sdk.py is #!/usr/bin/env python, but is not python3-compatible.
> The PEP 394 alias `python2` is sadly not universally supported, so
> instead of modifying relocate_sdk.py directly, change the `exec` in
> relocate_sdk.sh to use it if it exists.
> 
> Signed-off-by: Richard Tollerton <rich.tollerton@ni.com>
> ---
>  meta/classes/populate_sdk_base.bbclass | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)

Wasn't the script fixed in master to avoid this problem?

Cheers,

Richard

> diff --git a/meta/classes/populate_sdk_base.bbclass b/meta/classes/populate_sdk_base.bbclass
> index e5bc0b4..e67d8b6 100644
> --- a/meta/classes/populate_sdk_base.bbclass
> +++ b/meta/classes/populate_sdk_base.bbclass
> @@ -256,8 +256,9 @@ if [ x$tdir = x ] ; then
>     echo "SDK relocate failed, could not create a temporary directory"
>     exit 1
>  fi
> +python_bin="$(command -v python2 2>/dev/null)" || python_bin=python
>  echo "#!/bin/bash" > $tdir/relocate_sdk.sh
> -echo exec ${env_setup_script%/*}/relocate_sdk.py $target_sdk_dir $dl_path $executable_files >> $tdir/relocate_sdk.sh
> +echo exec $python_bin ${env_setup_script%/*}/relocate_sdk.py $target_sdk_dir $dl_path $executable_files >> $tdir/relocate_sdk.sh
>  $SUDO_EXEC mv $tdir/relocate_sdk.sh ${env_setup_script%/*}/relocate_sdk.sh
>  $SUDO_EXEC chmod 755 ${env_setup_script%/*}/relocate_sdk.sh
>  rm -rf $tdir




  reply	other threads:[~2013-10-04 11:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-02 23:18 [dylan, master][PATCH] populate_sdk_base: Fix relocate_sdk.py execution on Arch Richard Tollerton
2013-10-04 11:33 ` Richard Purdie [this message]
2013-10-04 16:25   ` Rich Tollerton

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=1380886416.18603.598.camel@ted \
    --to=richard.purdie@linuxfoundation.org \
    --cc=gratian.crisan@ni.com \
    --cc=ken.sharp@ni.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=paul.eggleton@linux.intel.com \
    --cc=rich.tollerton@ni.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox