diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2018-05-20 09:40:19 +0200 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2018-05-21 21:50:07 +0200 |
commit | 93757adee94f4be06a9c1a17b69db00e96e36fa9 (patch) | |
tree | 474a6b52f70319ecff630cc00e93cba363dc2585 /scripts/configure_helper.py | |
parent | 68333d32acd9414080ee9ce4c6cef6b04a0a64a3 (diff) | |
download | ptxdist-93757adee94f4be06a9c1a17b69db00e96e36fa9.tar.gz ptxdist-93757adee94f4be06a9c1a17b69db00e96e36fa9.tar.xz |
configure_helper.py: use meson from sysroot-host
Otherwise the version may not match.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Diffstat (limited to 'scripts/configure_helper.py')
-rwxr-xr-x | scripts/configure_helper.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/scripts/configure_helper.py b/scripts/configure_helper.py index 7c22aa7b2..612151c1a 100755 --- a/scripts/configure_helper.py +++ b/scripts/configure_helper.py @@ -146,7 +146,8 @@ def ask_ptxdist(pkg): "/print-%s_AUTOCONF" % pkg, "/print-%s_CONF_TOOL" %pkg, "/print-CROSS_MESON_USR", - "/print-CROSS_AUTOCONF_USR"], + "/print-CROSS_AUTOCONF_USR", + "/print-PTXDIST_SYSROOT_HOST"], stdout=subprocess.PIPE, universal_newlines=True) @@ -158,6 +159,7 @@ def ask_ptxdist(pkg): tool = "autoconf" meson_default = shlex.split(p.stdout.readline().strip()) autoconf_default = shlex.split(p.stdout.readline().strip()) + sysroot_host = p.stdout.readline().strip() if tool == "meson" and not opt: opt = meson_default if tool == "autoconf" and not opt: @@ -166,7 +168,7 @@ def ask_ptxdist(pkg): abort("'%s' is not a valid package: %s_DIR is undefined" % (pkg, pkg)) if not opt: abort("'%s' is not a autoconf/meson package: %s_CONF_OPT and %s_AUTOCONF are undefined" % (pkg, pkg, pkg)) - return (tool, d, subdir, opt) + return (tool, d, subdir, opt, sysroot_host) def blacklist_hit(name, blacklist): for e in blacklist: @@ -306,7 +308,7 @@ def handle_dir_meson(d): abort("package must be configured") exit(1) args = [] - p = subprocess.Popen([ "meson", "introspect", meson_builddir, "--buildoptions" ], stdout=subprocess.PIPE, universal_newlines=True) + p = subprocess.Popen([ os.path.join(sysroot_host, "bin", "meson"), "introspect", meson_builddir, "--buildoptions" ], stdout=subprocess.PIPE, universal_newlines=True) options = json.load(p.stdout) for option in options: try: @@ -408,7 +410,7 @@ ptx_pkg_conf_opt = [] pkg_subdir = "" tool = None if args.pkg: - (tool, d, pkg_subdir, pkg_conf_opt) = ask_ptxdist(ptx_PKG) + (tool, d, pkg_subdir, pkg_conf_opt, sysroot_host) = ask_ptxdist(ptx_PKG) ptx_pkg_label = "rules/%s.make" % ptx_pkg if tool == "autoconf": parsed_pkg_conf_opt = parse_configure_args(pkg_conf_opt, []) |