Hi,
I have problem to build the application when I migrate from ncs 2.0.2 to ncs 2.5.2. Inc ncs2.0.2 there is no devicetree_generated.h, I guess devicetree_generated.h is a new file for ncs 2.5.2 .
The following are the error logs I got
[58/149] Building C object CMakeFiles/app.dir/src/main.c.obj
FAILED: CMakeFiles/app.dir/src/main.c.obj
C:\ncs\toolchains\c57af46cb7\opt\zephyr-sdk\arm-zephyr-eabi\bin\arm-zephyr-eabi-gcc.exe -DKERNEL -DNRF5340_XXAA_APPLICATION -DNRF_SKIP_FICR_NS_COPY_TO_RAM -DPICOLIBC_INTEGER_PRINTF_SCANF -D_FORTIFY_SOURCE=1 -D_POSIX_C_SOURCE=200809 -D__LINUX_ERRNO_EXTENSIONS__ -D__PROGRAM_START -D__ZEPHYR__=1 -IC:/ncs/v2.5.2/zephyr/include -Izephyr/include/generated -IC:/ncs/v2.5.2/zephyr/soc/arm/nordic_nrf/nrf53 -IC:/ncs/v2.5.2/zephyr/soc/arm/nordic_nrf/common/. -IC:/ncs/v2.5.2/nrf/include -IC:/ncs/v2.5.2/nrf/tests/include -IC:/ncs/v2.5.2/modules/hal/cmsis/CMSIS/Core/Include -IC:/ncs/v2.5.2/zephyr/modules/cmsis/. -IC:/ncs/v2.5.2/modules/hal/nordic/nrfx -IC:/ncs/v2.5.2/modules/hal/nordic/nrfx/drivers/include -IC:/ncs/v2.5.2/modules/hal/nordic/nrfx/mdk -IC:/ncs/v2.5.2/zephyr/modules/hal_nordic/nrfx/. -isystem C:/ncs/v2.5.2/nrfxlib/crypto/nrf_cc312_platform/include -fno-strict-aliasing -Os -imacros C:/Skisens/nrf_code/spi_flash_nrf/build/zephyr/include/generated/autoconf.h -fno-printf-return-value -fno-common -g -gdwarf-4 -fdiagnostics-color=always -mcpu=cortex-m33 -mthumb -mabi=aapcs -mfp16-format=ieee --sysroot=C:/ncs/toolchains/c57af46cb7/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi -imacros C:/ncs/v2.5.2/zephyr/include/zephyr/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-pointer-sign -Wpointer-arith -Wexpansion-to-defined -Wno-unused-but-set-variable -Werror=implicit-int -fno-pic -fno-pie -fno-asynchronous-unwind-tables -ftls-model=local-exec -fno-reorder-functions --param=min-pagesize=0 -fno-defer-pop -fmacro-prefix-map=C:/Skisens/nrf_code/spi_flash_nrf=CMAKE_SOURCE_DIR -fmacro-prefix-map=C:/ncs/v2.5.2/zephyr=ZEPHYR_BASE -fmacro-prefix-map=C:/ncs/v2.5.2=WEST_TOPDIR -ffunction-sections -fdata-sections --specs=picolibc.specs -std=c99 -MD -MT CMakeFiles/app.dir/src/main.c.obj -MF CMakeFiles\app.dir\src\main.c.obj.d -o CMakeFiles/app.dir/src/main.c.obj -c ../src/main.c
In file included from ../src/main.c:7:
C:/ncs/v2.5.2/zephyr/include/zephyr/zephyr.h:12:2: warning: #warning "<zephyr/zephyr.h> is deprecated, include <zephyr/kernel.h> instead" [-Wcpp]
12 | #warning "<zephyr/zephyr.h> is deprecated, include <zephyr/kernel.h> instead"
| ^~~~~~~
../src/main.c:34:6: warning: return type of 'main' is not 'int' [-Wmain]
34 | void main(void)
| ^~~~
../src/main.c: In function 'main':
../src/main.c:53:20: warning: Macro is deprecated
53 | flash_dev = device_get_binding(FLASH_DEVICE);
| ^~~~~~~~~~~~~~~~~~~~~
In file included from C:/ncs/v2.5.2/zephyr/include/zephyr/arch/arm/aarch32/arch.h:20,
from C:/ncs/v2.5.2/zephyr/include/zephyr/arch/cpu.h:19,
from C:/ncs/v2.5.2/zephyr/include/zephyr/kernel_includes.h:33,
from C:/ncs/v2.5.2/zephyr/include/zephyr/kernel.h:17,
from C:/ncs/v2.5.2/zephyr/include/zephyr/zephyr.h:10:
zephyr/include/generated/devicetree_generated.h:14433:37: error: 'DT_N_S_soc_S_peripheral_50000000_S_qspi_2b000_S_mx25r6435f_0_P_label' undeclared (first use in this function); did you mean 'DT_N_S_soc_S_peripheral_50000000_S_qspi_2b000_S_mx25r6435f_0_P_size'?
14433 | #define DT_N_INST_0_nordic_qspi_nor DT_N_S_soc_S_peripheral_50000000_S_qspi_2b000_S_mx25r6435f_0
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/ncs/v2.5.2/zephyr/include/zephyr/devicetree.h:4231:29: note: in definition of macro 'DT_CAT3'
4231 | #define DT_CAT3(a1, a2, a3) a1 ## a2 ## a3
| ^~
C:/ncs/v2.5.2/zephyr/include/zephyr/devicetree.h:789:27: note: in expansion of macro 'DT_PROP'
789 | #define DT_LABEL(node_id) DT_PROP(node_id, label) __DEPRECATED_MACRO
| ^~~~~~~
../src/main.c:20:22: note: in expansion of macro 'DT_LABEL'
20 | #define FLASH_DEVICE DT_LABEL(DT_INST(0, nordic_qspi_nor))
| ^~~~~~~~
C:/ncs/v2.5.2/zephyr/include/zephyr/sys/util_internal.h:105:36: note: in expansion of macro 'DT_N_INST_0_nordic_qspi_nor'
105 | #define UTIL_PRIMITIVE_CAT(a, ...) a##__VA_ARGS__
| ^
C:/ncs/v2.5.2/zephyr/include/zephyr/sys/util_internal.h:104:26: note: in expansion of macro 'UTIL_PRIMITIVE_CAT'
104 | #define UTIL_CAT(a, ...) UTIL_PRIMITIVE_CAT(a, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
C:/ncs/v2.5.2/zephyr/include/zephyr/devicetree.h:333:31: note: in expansion of macro 'UTIL_CAT'
333 | #define DT_INST(inst, compat) UTIL_CAT(DT_N_INST, DT_DASH(inst, compat))
| ^~~~~~~~
../src/main.c:20:31: note: in expansion of macro 'DT_INST'
20 | #define FLASH_DEVICE DT_LABEL(DT_INST(0, nordic_qspi_nor))
| ^~~~~~~
../src/main.c:53:40: note: in expansion of macro 'FLASH_DEVICE'
53 | flash_dev = device_get_binding(FLASH_DEVICE);
| ^~~~~~~~~~~~
zephyr/include/generated/devicetree_generated.h:14433:37: note: each undeclared identifier is reported only once for each function it appears in
14433 | #define DT_N_INST_0_nordic_qspi_nor DT_N_S_soc_S_peripheral_50000000_S_qspi_2b000_S_mx25r6435f_0
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/ncs/v2.5.2/zephyr/include/zephyr/devicetree.h:4231:29: note: in definition of macro 'DT_CAT3'
4231 | #define DT_CAT3(a1, a2, a3) a1 ## a2 ## a3
| ^~
C:/ncs/v2.5.2/zephyr/include/zephyr/devicetree.h:789:27: note: in expansion of macro 'DT_PROP'
789 | #define DT_LABEL(node_id) DT_PROP(node_id, label) __DEPRECATED_MACRO
| ^~~~~~~
../src/main.c:20:22: note: in expansion of macro 'DT_LABEL'
20 | #define FLASH_DEVICE DT_LABEL(DT_INST(0, nordic_qspi_nor))
| ^~~~~~~~
C:/ncs/v2.5.2/zephyr/include/zephyr/sys/util_internal.h:105:36: note: in expansion of macro 'DT_N_INST_0_nordic_qspi_nor'
105 | #define UTIL_PRIMITIVE_CAT(a, ...) a##__VA_ARGS__
| ^
C:/ncs/v2.5.2/zephyr/include/zephyr/sys/util_internal.h:104:26: note: in expansion of macro 'UTIL_PRIMITIVE_CAT'
104 | #define UTIL_CAT(a, ...) UTIL_PRIMITIVE_CAT(a, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
C:/ncs/v2.5.2/zephyr/include/zephyr/devicetree.h:333:31: note: in expansion of macro 'UTIL_CAT'
333 | #define DT_INST(inst, compat) UTIL_CAT(DT_N_INST, DT_DASH(inst, compat))
| ^~~~~~~~
../src/main.c:20:31: note: in expansion of macro 'DT_INST'
20 | #define FLASH_DEVICE DT_LABEL(DT_INST(0, nordic_qspi_nor))
| ^~~~~~~
../src/main.c:53:40: note: in expansion of macro 'FLASH_DEVICE'
53 | flash_dev = device_get_binding(FLASH_DEVICE);
| ^~~~~~~~~~~~
../src/main.c:57:27: warning: Macro is deprecated
57 | FLASH_DEVICE);
| ^~~~~~~~~~~
[67/149] Building C object zephyr/drivers/flash/CMakeFiles/drivers__flash.dir/nrf_qspi_nor.c.obj
Please help