Only update signing header if pubkey present

This commit is contained in:
unknown 2022-08-21 15:41:43 +02:00
parent a3c7bc9472
commit f4a6a4586f

View File

@ -228,6 +228,8 @@ env.Append(
is_arduino_pico_build = env.BoardConfig().get("build.core", "arduino") == "earlephilhower" and "arduino" in env.get("PIOFRAMEWORK")
target_gen_header = None
if is_arduino_pico_build:
pubkey = join(env.subst("$PROJECT_SRC_DIR"), "public.key")
if isfile(pubkey):
header_file = join(env.subst("$BUILD_DIR"), "core", "Updater_Signing.h")
env.Prepend(CFLAGS=['-I"%s"' % join("$BUILD_DIR", "core")])
signing_header_cmd = env.Command(