Using NCS 2.6.2
set(PM_STATIC_YML_FILE ${CMAKE_CURRENT_SOURCE_DIR}/configuration/pm_static.yml)
in the CMakeLists.txt works well to use static partitions for a appl+mcuboot.
Migration to NCS 2.9.0 this seems to be ignored (or overwritten).
I tried to find migration hints in, but in Migrating from multi-image builds to sysbuild I could find some advice.
I also read Configuring static partitions , that mentions
"You can set PM_STATIC_YML_FILE to contain exactly the static configuration you want to use."
which seems to doesn't work, at least not if provided in the CMakeLists.txt
So, how could I use a "pm_static.yml" for appl+mcuboot?
(I don't need different files for nRF9160/61/51.)
To reproduce:
Use the demo application "nrf/applications/serial_lte_modem". Copy the "nrf/boards/nordic/thingy91/thingy91_pm_static.yml" as "pm_static.yml" into "nrf/applications/serial_lte_modem".
Add
set(PM_STATIC_YML_FILE ${CMAKE_CURRENT_SOURCE_DIR}/pm_static.yml)
before the find_package. Build with "west build -b thingy91/nrf9160/ns -p" and check the logs. On my machine the log always contains.
-- Build files have been written to: /ncs/v2.9.0/nrf/applications/serial_lte_modem/build/serial_lte_modem
-- Found partition manager static configuration : /ncs/v2.9.0/nrf/boards/nordic/thingy91/thingy91_pm_static.yml
so PM_STATIC_YML_FILE seems to be broken.