11 -MD -MT zephyr/subsys/dfu/boot/CMakeFiles/subsys__dfu__boot.dir/mcuboot.c.obj -MF zephyr/subsys/dfu/boot/CMakeFiles/subsys__dfu__boot.dir/mcuboot.c.obj.d -o zephyr/subsys/dfu/boot/CMakeFiles/subsys__dfu__boot.dir/mcuboot.c.obj -c /opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c
In file included from /opt/nordic/ncs/v2.9.2/zephyr/include/zephyr/storage/flash_map.h:300,
from /opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c:12:
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c: In function 'boot_is_img_confirmed':
/opt/nordic/ncs/v2.9.2/nrf/include/flash_map_pm.h:47:22: error: 'PM_mcuboot_primary_ID' undeclared (first use in this function)
47 | #define PM_ID(label) PM_##label##_ID
| ^~~
/opt/nordic/ncs/v2.9.2/nrf/include/flash_map_pm.h:52:35: note: in expansion of macro 'PM_ID'
52 | #define FIXED_PARTITION_ID(label) PM_ID(label)
| ^~~~~
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot_priv.h:22:34: note: in expansion of macro 'FIXED_PARTITION_ID'
22 | #define FLASH_AREA_IMAGE_PRIMARY FIXED_PARTITION_ID(SLOT0_LABEL)
| ^~~~~~~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c:236:30: note: in expansion of macro 'FLASH_AREA_IMAGE_PRIMARY'
236 | rc = flash_area_open(FLASH_AREA_IMAGE_PRIMARY, &fa);
| ^~~~~~~~~~~~~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.2/nrf/include/flash_map_pm.h:47:22: note: each undeclared identifier is reported only once for each function it appears in
47 | #define PM_ID(label) PM_##label##_ID
| ^~~
/opt/nordic/ncs/v2.9.2/nrf/include/flash_map_pm.h:52:35: note: in expansion of macro 'PM_ID'
52 | #define FIXED_PARTITION_ID(label) PM_ID(label)
| ^~~~~
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot_priv.h:22:34: note: in expansion of macro 'FIXED_PARTITION_ID'
22 | #define FLASH_AREA_IMAGE_PRIMARY FIXED_PARTITION_ID(SLOT0_LABEL)
| ^~~~~~~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c:236:30: note: in expansion of macro 'FLASH_AREA_IMAGE_PRIMARY'
236 | rc = flash_area_open(FLASH_AREA_IMAGE_PRIMARY, &fa);
| ^~~~~~~~~~~~~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c: In function 'boot_write_img_confirmed':
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c:68:49: error: 'PM_MCUBOOT_PRIMARY_ID' undeclared (first use in this function)
68 | #define ACTIVE_SLOT_FLASH_AREA_ID PM_MCUBOOT_PRIMARY_ID
| ^~~~~~~~~~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.2/zephyr/subsys/dfu/boot/mcuboot.c:263:29: note: in expansion of macro 'ACTIVE_SLOT_FLASH_AREA_ID'
263 | if (flash_area_open(ACTIVE_SLOT_FLASH_AREA_ID, &fa) != 0) {
| ^~~~~~~~~~~~~~~~~~~~~~~~~
[176/410] Building C object zephyr/subsys/net/ip/CMakeFiles/subsys__net__ip.dir/net_if.c.obj
After I used the migration script to migrate my boards from the HW V1 to V2 I started getting this issue.
I get it across two diffrent boards, I tired other versions of the sdk and tool chain and same issue.