From 8db5d2d1f13aa6413be11bc13c94df72296a0070 Mon Sep 17 00:00:00 2001 From: MikeTeachman Date: Tue, 3 Mar 2020 11:21:13 -0800 Subject: [PATCH] tools/makemanifest.py: Fix build on Windows by adding .exe to mpy-cross. When using a manifest on Windows the reference to mpy-cross compiler was missing the .exe file extension, so add it when appropriate. Also allow the default path to mpy-cross to be overridden by the (optional) MICROPY_MPYCROSS environment variable, to allow full flexibility on any OS. --- tools/makemanifest.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/makemanifest.py b/tools/makemanifest.py index a8b310ad65..2cee6aebc7 100644 --- a/tools/makemanifest.py +++ b/tools/makemanifest.py @@ -235,6 +235,9 @@ def main(): # Get paths to tools MAKE_FROZEN = VARS["MPY_DIR"] + "/tools/make-frozen.py" MPY_CROSS = VARS["MPY_DIR"] + "/mpy-cross/mpy-cross" + if sys.platform == "win32": + MPY_CROSS += ".exe" + MPY_CROSS = os.getenv("MICROPY_MPYCROSS", MPY_CROSS) MPY_TOOL = VARS["MPY_DIR"] + "/tools/mpy-tool.py" # Ensure mpy-cross is built