partition_table: fix generation of signed partition table

Fixes the issue that signed partition table was not generated when
CONFIG_SECURE_BOOT_BUILD_SIGNED_BINARIES was on, because
partition_table_bin depended on unsigned_partition_bin twice.
Regression from acb7a211.

Also use final_partition_bin variable in esptool_py_flash_target_image
arguments, to avoid issues in the future if final_partition_bin is
changed.
This commit is contained in:
Ivan Grokhotkov 2020-05-31 18:39:30 +02:00
parent 07bf1e23db
commit 754d631247

View File

@ -51,7 +51,7 @@ add_custom_command(OUTPUT "${build_dir}/partition_table/${unsigned_partition_bin
VERBATIM) VERBATIM)
add_custom_target(partition_table_bin DEPENDS "${build_dir}/partition_table/${unsigned_partition_bin}" add_custom_target(partition_table_bin DEPENDS "${build_dir}/partition_table/${unsigned_partition_bin}"
"${build_dir}/partition_table/${unsigned_partition_bin}") "${build_dir}/partition_table/${final_partition_bin}")
if(EXISTS ${partition_csv}) if(EXISTS ${partition_csv})
add_custom_target(partition_table add_custom_target(partition_table
@ -100,7 +100,7 @@ idf_component_get_property(sub_args esptool_py FLASH_SUB_ARGS)
if(CONFIG_APP_BUILD_GENERATE_BINARIES) if(CONFIG_APP_BUILD_GENERATE_BINARIES)
esptool_py_flash_target(partition_table-flash "${main_args}" "${sub_args}") esptool_py_flash_target(partition_table-flash "${main_args}" "${sub_args}")
esptool_py_flash_target_image(partition_table-flash partition_table "${PARTITION_TABLE_OFFSET}" esptool_py_flash_target_image(partition_table-flash partition_table "${PARTITION_TABLE_OFFSET}"
"${build_dir}/partition_table/partition-table.bin") "${build_dir}/partition_table/${final_partition_bin}")
esptool_py_flash_target_image(flash partition_table "${PARTITION_TABLE_OFFSET}" esptool_py_flash_target_image(flash partition_table "${PARTITION_TABLE_OFFSET}"
"${build_dir}/partition_table/partition-table.bin") "${build_dir}/partition_table/${final_partition_bin}")
endif() endif()