* [PATCH] {python,python3}-native: fix TypeError
@ 2015-06-09 5:08 Changhyeok Bae
2015-06-15 6:48 ` [PATCH] {python, python3}-native: " Changhyeok Bae
2015-06-15 6:54 ` Richard Purdie
0 siblings, 2 replies; 5+ messages in thread
From: Changhyeok Bae @ 2015-06-09 5:08 UTC (permalink / raw)
To: openembedded-core
g-ir-core in meta-gir is building with python-native.
When the g-ir-core(v1.42.0) is building, following error is occurred.
Error in g-ir-core:
EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
| TypeError: expected a character buffer object
Signed-off-by: Changhyeok Bae <changhyeok.bae@lge.com>
---
...2-distutils-prefix-is-inside-staging-area.patch | 4 ++--
.../recipes-devtools/python/python-native_2.7.9.bb | 2 +-
.../python/python3-native_3.4.3.bb | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-inside-staging-area.patch b/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-inside-staging-area.patch
index f89aaff..b9cc4d9 100644
--- a/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-inside-staging-area.patch
+++ b/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-inside-staging-area.patch
@@ -12,8 +12,8 @@ Upstream-Status: Inappropriate [embedded specific]
# These are needed in a couple of spots, so just compute them once.
-PREFIX = os.path.normpath(sys.prefix)
-EXEC_PREFIX = os.path.normpath(sys.exec_prefix)
-+PREFIX = os.path.normpath(sys.prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
-+EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
++PREFIX = os.path.normpath(sys.prefix).replace( str(os.getenv("BUILD_SYS")), str(os.getenv("HOST_SYS")) )
++EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace( str(os.getenv("BUILD_SYS")), str(os.getenv("HOST_SYS")) )
# Path to the base directory of the project. On Windows the binary may
# live in project/PCBuild9. If we're dealing with an x64 Windows build,
diff --git a/meta/recipes-devtools/python/python-native_2.7.9.bb b/meta/recipes-devtools/python/python-native_2.7.9.bb
index 34f5c29..5be7bb9 100644
--- a/meta/recipes-devtools/python/python-native_2.7.9.bb
+++ b/meta/recipes-devtools/python/python-native_2.7.9.bb
@@ -2,7 +2,7 @@ require python.inc
EXTRANATIVEPATH += "bzip2-native"
DEPENDS = "openssl-native bzip2-replacement-native zlib-native readline-native sqlite3-native"
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
SRC_URI += "\
file://05-enable-ctypes-cross-build.patch \
diff --git a/meta/recipes-devtools/python/python3-native_3.4.3.bb b/meta/recipes-devtools/python/python3-native_3.4.3.bb
index 464ff05..105c0c9 100644
--- a/meta/recipes-devtools/python/python3-native_3.4.3.bb
+++ b/meta/recipes-devtools/python/python3-native_3.4.3.bb
@@ -1,6 +1,6 @@
require recipes-devtools/python/python.inc
-PR = "${INC_PR}.0"
+PR = "${INC_PR}.1"
PYTHON_MAJMIN = "3.4"
DISTRO_SRC_URI ?= "file://sitecustomize.py"
DISTRO_SRC_URI_linuxstdbase = ""
--
1.7.9.5
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] {python, python3}-native: fix TypeError
2015-06-09 5:08 [PATCH] {python,python3}-native: fix TypeError Changhyeok Bae
@ 2015-06-15 6:48 ` Changhyeok Bae
2015-06-15 6:54 ` Richard Purdie
1 sibling, 0 replies; 5+ messages in thread
From: Changhyeok Bae @ 2015-06-15 6:48 UTC (permalink / raw)
To: openembedded-core
ping
-----Original Message-----
From: Changhyeok Bae [mailto:changhyeok.bae@lge.com]
Sent: Tuesday, June 09, 2015 2:08 PM
To: openembedded-core@lists.openembedded.org
Cc: Changhyeok Bae
Subject: [OE-Core][PATCH] {python,python3}-native: fix TypeError
g-ir-core in meta-gir is building with python-native.
When the g-ir-core(v1.42.0) is building, following error is occurred.
Error in g-ir-core:
EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace(
os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
| TypeError: expected a character buffer object
Signed-off-by: Changhyeok Bae <changhyeok.bae@lge.com>
---
...2-distutils-prefix-is-inside-staging-area.patch | 4 ++--
.../recipes-devtools/python/python-native_2.7.9.bb | 2 +-
.../python/python3-native_3.4.3.bb | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git
a/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-inside-s
taging-area.patch
b/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-inside-s
taging-area.patch
index f89aaff..b9cc4d9 100644
---
a/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-inside-s
taging-area.patch
+++ b/meta/recipes-devtools/python/python-native/12-distutils-prefix-is-
+++ inside-staging-area.patch
@@ -12,8 +12,8 @@ Upstream-Status: Inappropriate [embedded specific]
# These are needed in a couple of spots, so just compute them once.
-PREFIX = os.path.normpath(sys.prefix)
-EXEC_PREFIX = os.path.normpath(sys.exec_prefix)
-+PREFIX = os.path.normpath(sys.prefix).replace( os.getenv("BUILD_SYS"),
-+os.getenv("HOST_SYS") ) EXEC_PREFIX =
-+os.path.normpath(sys.exec_prefix).replace( os.getenv("BUILD_SYS"),
-+os.getenv("HOST_SYS") )
++PREFIX = os.path.normpath(sys.prefix).replace(
++str(os.getenv("BUILD_SYS")), str(os.getenv("HOST_SYS")) ) EXEC_PREFIX
++= os.path.normpath(sys.exec_prefix).replace(
++str(os.getenv("BUILD_SYS")), str(os.getenv("HOST_SYS")) )
# Path to the base directory of the project. On Windows the binary may
# live in project/PCBuild9. If we're dealing with an x64 Windows build,
diff --git a/meta/recipes-devtools/python/python-native_2.7.9.bb
b/meta/recipes-devtools/python/python-native_2.7.9.bb
index 34f5c29..5be7bb9 100644
--- a/meta/recipes-devtools/python/python-native_2.7.9.bb
+++ b/meta/recipes-devtools/python/python-native_2.7.9.bb
@@ -2,7 +2,7 @@ require python.inc
EXTRANATIVEPATH += "bzip2-native"
DEPENDS = "openssl-native bzip2-replacement-native zlib-native
readline-native sqlite3-native"
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
SRC_URI += "\
file://05-enable-ctypes-cross-build.patch \ diff --git
a/meta/recipes-devtools/python/python3-native_3.4.3.bb
b/meta/recipes-devtools/python/python3-native_3.4.3.bb
index 464ff05..105c0c9 100644
--- a/meta/recipes-devtools/python/python3-native_3.4.3.bb
+++ b/meta/recipes-devtools/python/python3-native_3.4.3.bb
@@ -1,6 +1,6 @@
require recipes-devtools/python/python.inc
-PR = "${INC_PR}.0"
+PR = "${INC_PR}.1"
PYTHON_MAJMIN = "3.4"
DISTRO_SRC_URI ?= "file://sitecustomize.py"
DISTRO_SRC_URI_linuxstdbase = ""
--
1.7.9.5
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] {python, python3}-native: fix TypeError
2015-06-09 5:08 [PATCH] {python,python3}-native: fix TypeError Changhyeok Bae
2015-06-15 6:48 ` [PATCH] {python, python3}-native: " Changhyeok Bae
@ 2015-06-15 6:54 ` Richard Purdie
2015-06-16 5:33 ` Changhyeok Bae
1 sibling, 1 reply; 5+ messages in thread
From: Richard Purdie @ 2015-06-15 6:54 UTC (permalink / raw)
To: Changhyeok Bae; +Cc: openembedded-core
On Tue, 2015-06-09 at 14:08 +0900, Changhyeok Bae wrote:
> g-ir-core in meta-gir is building with python-native.
> When the g-ir-core(v1.42.0) is building, following error is occurred.
>
> Error in g-ir-core:
> EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
> | TypeError: expected a character buffer object
Doesn't this mean BUILD_SYS or HOST_SYS weren't set in the environment?
Wouldn't this patch just mean you get a value of something like "None"?
Cheers,
Richard
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] {python, python3}-native: fix TypeError
2015-06-15 6:54 ` Richard Purdie
@ 2015-06-16 5:33 ` Changhyeok Bae
2015-06-16 14:32 ` Richard Purdie
0 siblings, 1 reply; 5+ messages in thread
From: Changhyeok Bae @ 2015-06-16 5:33 UTC (permalink / raw)
To: 'Richard Purdie'; +Cc: 이명구, openembedded-core
Doesn't this mean BUILD_SYS or HOST_SYS weren't set in the environment?
-> You're right. The default env value of BUILD_SYS and HOST_SYS is "" (empty).
-> I wonder that the original patch (12-distutils-prefix-is-inside-staging-area.patch) to add is required?
Wouldn't this patch just mean you get a value of something like "None"?
-> My patch is to prevent errors in runtime.
-> Do you have any other good idea?
Thanks
Changhyeok
-----Original Message-----
From: Richard Purdie [mailto:richard.purdie@linuxfoundation.org]
Sent: Monday, June 15, 2015 3:55 PM
To: Changhyeok Bae
Cc: openembedded-core@lists.openembedded.org
Subject: Re: [OE-core] [OE-Core][PATCH] {python,python3}-native: fix TypeError
On Tue, 2015-06-09 at 14:08 +0900, Changhyeok Bae wrote:
> g-ir-core in meta-gir is building with python-native.
> When the g-ir-core(v1.42.0) is building, following error is occurred.
>
> Error in g-ir-core:
> EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
> | TypeError: expected a character buffer object
Doesn't this mean BUILD_SYS or HOST_SYS weren't set in the environment?
Wouldn't this patch just mean you get a value of something like "None"?
Cheers,
Richard
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] {python, python3}-native: fix TypeError
2015-06-16 5:33 ` Changhyeok Bae
@ 2015-06-16 14:32 ` Richard Purdie
0 siblings, 0 replies; 5+ messages in thread
From: Richard Purdie @ 2015-06-16 14:32 UTC (permalink / raw)
To: Changhyeok Bae; +Cc: 이명구, openembedded-core
On Tue, 2015-06-16 at 14:33 +0900, Changhyeok Bae wrote:
> Doesn't this mean BUILD_SYS or HOST_SYS weren't set in the environment?
> -> You're right. The default env value of BUILD_SYS and HOST_SYS is "" (empty).
> -> I wonder that the original patch (12-distutils-prefix-is-inside-staging-area.patch) to add is required?
>
> Wouldn't this patch just mean you get a value of something like "None"?
> -> My patch is to prevent errors in runtime.
> -> Do you have any other good idea?
My concern is that just having a value of "None" means the code trying
to use this variable will probably do the wrong thing. We should try and
fix the underlying problem of BUILD_SYS bot being set when it should be,
rather than just hide the runtime error.
How you do that depends on when the runtime error is occurring which I
know little about...
Cheers,
Richard
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-06-16 14:32 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-09 5:08 [PATCH] {python,python3}-native: fix TypeError Changhyeok Bae
2015-06-15 6:48 ` [PATCH] {python, python3}-native: " Changhyeok Bae
2015-06-15 6:54 ` Richard Purdie
2015-06-16 5:33 ` Changhyeok Bae
2015-06-16 14:32 ` Richard Purdie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox