From 355d9834377c7ba60ccf30ea325c565d95f8954a Mon Sep 17 00:00:00 2001 From: Yurii Date: Thu, 24 Oct 2024 04:26:46 +0300 Subject: [PATCH] chore: copy elf to build dir --- tools/build.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tools/build.py b/tools/build.py index 8d1b7dc..dede5f9 100644 --- a/tools/build.py +++ b/tools/build.py @@ -6,10 +6,11 @@ Import("env") def post_build(source, target, env): copy_to_build_dir({ - source[0].get_abspath(): "firmware_%s_%s.bin" % (env["PIOENV"], env.GetProjectOption("version")), - env.subst("$BUILD_DIR/${PROGNAME}.factory.bin"): "firmware_%s_%s.factory.bin" % (env["PIOENV"], env.GetProjectOption("version")), + source[0].get_abspath(): "firmware_%s_%s.bin" % (env["PIOENV"], env.GetProjectOption("version")), + env.subst("$BUILD_DIR/${PROGNAME}.factory.bin"): "firmware_%s_%s.factory.bin" % (env["PIOENV"], env.GetProjectOption("version")), + env.subst("$BUILD_DIR/${PROGNAME}.elf"): "firmware_%s_%s.elf" % (env["PIOENV"], env.GetProjectOption("version")) }, os.path.join(env["PROJECT_DIR"], "build")); - + env.Execute("pio run --target buildfs --environment %s" % env["PIOENV"]);