All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/1] bitbake wrapper: exit if python v3 is detected
@ 2011-06-15  1:42 Scott Garman
  2011-06-15  1:42 ` [PATCH 1/1] " Scott Garman
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Scott Garman @ 2011-06-15  1:42 UTC (permalink / raw)
  To: poky

Make sure we're not using python v3.x. This check can't go into
sanity.bbclass because bitbake's source code doesn't even pass
parsing stage when used with python v3, so we catch it here so we
can offer a meaningful error message.

This fixes bug [YOCTO #1128]

I did attempt to make changes to bitbake to get the source code to
parse under python v3, but there are issues which make it too
difficult to get the code to work with python v2 and v3. For example,
importing modules within a package has changed significantly in v3
in such a way that breaks compatability with v2.

The following changes since commit 7aa7673459376aff911cef820c9417c998d1aa96:

  meta-yocto/linux-yocto: update to match the renamed linux-yocto recipes (2011-06-14 09:21:32 -0700)

are available in the git repository at:
  git://git.pokylinux.org/poky-contrib sgarman/bb-python-v3
  http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=sgarman/bb-python-v3

Scott Garman (1):
  bitbake wrapper: exit if python v3 is detected

 scripts/bitbake |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)



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

* [PATCH 1/1] bitbake wrapper: exit if python v3 is detected
  2011-06-15  1:42 [PATCH 0/1] bitbake wrapper: exit if python v3 is detected Scott Garman
@ 2011-06-15  1:42 ` Scott Garman
  2011-06-27 20:01 ` [PATCH 0/1] " Scott Garman
  2011-06-28 11:10 ` Richard Purdie
  2 siblings, 0 replies; 5+ messages in thread
From: Scott Garman @ 2011-06-15  1:42 UTC (permalink / raw)
  To: poky

Make sure we're not using python v3.x. This check can't go into
sanity.bbclass because bitbake's source code doesn't even pass
parsing stage when used with python v3, so we catch it here so we
can offer a meaningful error message.

This fixes bug [YOCTO #1128]

Signed-off-by: Scott Garman <scott.a.garman@intel.com>
---
 scripts/bitbake |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/scripts/bitbake b/scripts/bitbake
index 3923421..587428c 100755
--- a/scripts/bitbake
+++ b/scripts/bitbake
@@ -16,6 +16,17 @@ done
 [ $needpseudo = "0" ] && break
 done
 
+# Make sure we're not using python v3.x. This check can't go into
+# sanity.bbclass because bitbake's source code doesn't even pass
+# parsing stage when used with python v3, so we catch it here so we
+# can offer a meaningful error message.
+py_v3_check=`/usr/bin/env python --version 2>&1 | grep "Python 3"`
+if [ "$py_v3_check" != "" ]; then
+	echo "Bitbake is not compatible with python v3"
+	echo "Please set up python v2 as your default python interpreter"
+	exit 1
+fi
+
 needtar="1"
 TARVERSION=`tar --version | head -n 1 | cut -d ' ' -f 4`
 float_test() {
-- 
1.7.1



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

* Re: [PATCH 0/1] bitbake wrapper: exit if python v3 is detected
  2011-06-15  1:42 [PATCH 0/1] bitbake wrapper: exit if python v3 is detected Scott Garman
  2011-06-15  1:42 ` [PATCH 1/1] " Scott Garman
@ 2011-06-27 20:01 ` Scott Garman
  2011-06-28 10:27   ` Koen Kooi
  2011-06-28 11:10 ` Richard Purdie
  2 siblings, 1 reply; 5+ messages in thread
From: Scott Garman @ 2011-06-27 20:01 UTC (permalink / raw)
  To: poky

On 06/14/2011 06:42 PM, Scott Garman wrote:
> Make sure we're not using python v3.x. This check can't go into
> sanity.bbclass because bitbake's source code doesn't even pass
> parsing stage when used with python v3, so we catch it here so we
> can offer a meaningful error message.
>
> This fixes bug [YOCTO #1128]
>
> I did attempt to make changes to bitbake to get the source code to
> parse under python v3, but there are issues which make it too
> difficult to get the code to work with python v2 and v3. For example,
> importing modules within a package has changed significantly in v3
> in such a way that breaks compatability with v2.

Ping?

Scott

-- 
Scott Garman
Embedded Linux Engineer - Yocto Project
Intel Open Source Technology Center


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

* Re: [PATCH 0/1] bitbake wrapper: exit if python v3 is detected
  2011-06-27 20:01 ` [PATCH 0/1] " Scott Garman
@ 2011-06-28 10:27   ` Koen Kooi
  0 siblings, 0 replies; 5+ messages in thread
From: Koen Kooi @ 2011-06-28 10:27 UTC (permalink / raw)
  To: Scott Garman; +Cc: poky


Op 27 jun 2011, om 22:01 heeft Scott Garman het volgende geschreven:

> On 06/14/2011 06:42 PM, Scott Garman wrote:
>> Make sure we're not using python v3.x. This check can't go into
>> sanity.bbclass because bitbake's source code doesn't even pass
>> parsing stage when used with python v3, so we catch it here so we
>> can offer a meaningful error message.
>> 
>> This fixes bug [YOCTO #1128]
>> 
>> I did attempt to make changes to bitbake to get the source code to
>> parse under python v3, but there are issues which make it too
>> difficult to get the code to work with python v2 and v3. For example,
>> importing modules within a package has changed significantly in v3
>> in such a way that breaks compatability with v2.
> 
> Ping?

Try posting it on the OE-core list?


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

* Re: [PATCH 0/1] bitbake wrapper: exit if python v3 is detected
  2011-06-15  1:42 [PATCH 0/1] bitbake wrapper: exit if python v3 is detected Scott Garman
  2011-06-15  1:42 ` [PATCH 1/1] " Scott Garman
  2011-06-27 20:01 ` [PATCH 0/1] " Scott Garman
@ 2011-06-28 11:10 ` Richard Purdie
  2 siblings, 0 replies; 5+ messages in thread
From: Richard Purdie @ 2011-06-28 11:10 UTC (permalink / raw)
  To: Scott Garman; +Cc: poky

On Tue, 2011-06-14 at 18:42 -0700, Scott Garman wrote:
> Make sure we're not using python v3.x. This check can't go into
> sanity.bbclass because bitbake's source code doesn't even pass
> parsing stage when used with python v3, so we catch it here so we
> can offer a meaningful error message.
> 
> This fixes bug [YOCTO #1128]
> 
> I did attempt to make changes to bitbake to get the source code to
> parse under python v3, but there are issues which make it too
> difficult to get the code to work with python v2 and v3. For example,
> importing modules within a package has changed significantly in v3
> in such a way that breaks compatability with v2.
> 
> The following changes since commit 7aa7673459376aff911cef820c9417c998d1aa96:
> 
>   meta-yocto/linux-yocto: update to match the renamed linux-yocto recipes (2011-06-14 09:21:32 -0700)
> 
> are available in the git repository at:
>   git://git.pokylinux.org/poky-contrib sgarman/bb-python-v3
>   http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=sgarman/bb-python-v3
> 
> Scott Garman (1):
>   bitbake wrapper: exit if python v3 is detected

Merged to master but please send OE-Core related patches to the OE-Core
list in future.

Cheers,

Richard



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

end of thread, other threads:[~2011-06-28 11:10 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-15  1:42 [PATCH 0/1] bitbake wrapper: exit if python v3 is detected Scott Garman
2011-06-15  1:42 ` [PATCH 1/1] " Scott Garman
2011-06-27 20:01 ` [PATCH 0/1] " Scott Garman
2011-06-28 10:27   ` Koen Kooi
2011-06-28 11:10 ` Richard Purdie

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.