diff options
author | Etienne Cordonnier <ecordonnier@snap.com> | 2024-01-12 16:33:08 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-01-15 21:42:15 +0000 |
commit | 3db106c41b22f9152b7253a1310467589eacf9d3 (patch) | |
tree | da841ea7e33bc6f5077c1fd0686044aff8331969 /meta/classes | |
parent | 5031cf42ffb221b52e527d8afc54138c1fb161a1 (diff) | |
download | poky-3db106c41b22f9152b7253a1310467589eacf9d3.tar.gz |
chrpath.bbclass: fix Darwin support
Ported from the meta-darwin layer:
The call to out.split("\n") expects a string, thus the parameter text=True is
needed (otherwise Popen returns a bytes object).
Note that "text" is just a more readable alias for universal_newlines.
(From OE-Core rev: 0abaa7bf7f7d9a5ac96e6fdbe99334cb2fb0e4db)
Signed-off-by: Dominik Schnitzer <dominik@snap.com>
Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/chrpath.bbclass | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/classes/chrpath.bbclass b/meta/classes/chrpath.bbclass index 1aecb4df66..16729dcf61 100644 --- a/meta/classes/chrpath.bbclass +++ b/meta/classes/chrpath.bbclass | |||
@@ -62,7 +62,7 @@ def process_file_linux(cmd, fpath, rootdir, baseprefix, tmpdir, d, break_hardlin | |||
62 | def process_file_darwin(cmd, fpath, rootdir, baseprefix, tmpdir, d, break_hardlinks = False): | 62 | def process_file_darwin(cmd, fpath, rootdir, baseprefix, tmpdir, d, break_hardlinks = False): |
63 | import subprocess as sub | 63 | import subprocess as sub |
64 | 64 | ||
65 | p = sub.Popen([d.expand("${HOST_PREFIX}otool"), '-L', fpath],stdout=sub.PIPE,stderr=sub.PIPE) | 65 | p = sub.Popen([d.expand("${HOST_PREFIX}otool"), '-L', fpath],stdout=sub.PIPE,stderr=sub.PIPE, text=True) |
66 | out, err = p.communicate() | 66 | out, err = p.communicate() |
67 | # If returned successfully, process stdout for results | 67 | # If returned successfully, process stdout for results |
68 | if p.returncode != 0: | 68 | if p.returncode != 0: |