This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

processing error related to NRF5340 Kit

in fact the error that i posted is related to this file and exactly to the bloc in grey on nvic.h file

"  C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/arch/arm/aarch32/cortex_m/nvic.h:15:44: error: pasting ")" and "_P_arm_num_irq_priority_bits" does not give a valid preprocessing token  "

C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/arch/arm/aarch32/cortex_m/nvic.h:15:32: error: 'arm_v8m_nvic' undeclared (first use in this function)

 C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/devicetree.h:463:48: error: expected ')' before '_P_arm_num_irq_priority_bits'

C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/arch/arm/aarch32/exc.h:24:36: note: to match this '('

1> C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/arch/arm/aarch32/cortex_m/nvic.h:15:28: error: missing binary operator before token "("

i'm getting these couple of errors do you know if there's a link between them 
because my error is certainly a processing error 
can you help with this please

knowing that i just tried to open another project from a different directory then the BME280 project 
it went all on collapse ! 

can you please help me please 

this is the message i'm getting
 i really need help 

Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/misc/empty_file.c’ from solution ‘build’ in configuration ‘Common’
Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/dt-bindings/gpio/gpio.h’ from solution ‘build’ in configuration ‘Common’
Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/dt-bindings/i2c/i2c.h’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/misc/generated/syscalls.json’ from solution ‘build’ in configuration ‘Common’
1> 'zephyr/misc/generated/syscalls.json' is up to date
Building ‘zephyr/misc/generated/struct_tags.json’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/CMakeFiles/parse_syscalls_target’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/parse_syscalls_target’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/driver-validation.h’ from solution ‘build’ in configuration ‘Common’
1> 'zephyr/include/generated/driver-validation.h' is up to date
Building ‘zephyr/CMakeFiles/driver_validation_h_target’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/driver_validation_h_target’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/kobj-types-enum.h’ from solution ‘build’ in configuration ‘Common’
1> 'zephyr/include/generated/kobj-types-enum.h' is up to date
Building ‘zephyr/include/generated/otype-to-str.h’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/CMakeFiles/kobj_types_h_target’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/kobj_types_h_target’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/syscall_list.h’ from solution ‘build’ in configuration ‘Common’
1> 'zephyr/include/generated/syscall_dispatch.c' is up to date
Building ‘zephyr/CMakeFiles/syscall_list_h_target’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/syscall_dispatch.c’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/syscall_list_h_target’ from solution ‘build’ in configuration ‘Common’
Building ‘cmake_object_order_depends_target_offsets’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj’ from solution ‘build’ in configuration ‘Common’
1> zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj does not exist.
1> Compiling ‘offsets.c’
1> C:\Users\rzaafouri\ncs\v1.5.1-rc1\toolchain\opt/bin/arm-none-eabi-gcc -DBUILD_VERSION=v2.4.99-ncs2 -DKERNEL -DNRF5340_XXAA_APPLICATION -DUSE_PARTITION_MANAGER=0 -D_FORTIFY_SOURCE=2 -D__PROGRAM_START -D__ZEPHYR__=1 -I../../../kernel/include -I../../../arch/arm/include -I../../../include -Izephyr/include/generated -I../../../soc/arm/nordic_nrf/nrf53 -IC:/Users/rzaafouri/ncs/v1.5.1/nrf/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/drivers/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/mdk -I../../../modules/hal_nordic/nrfx/. -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/cmsis/CMSIS/Core/Include -isystem ../../../lib/libc/minimal/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include-fixed -isystem C:/Users/rzaafouri/ncs/v1.5.1/nrfxlib/crypto/nrf_cc312_platform/include -Os -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/autoconf.h -ffreestanding -fno-common -g -mcpu=cortex-m33 -mthumb -mabi=aapcs -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-main -Wno-pointer-sign -Wpointer-arith -Wno-address-of-packed-member -Wno-unused-but-set-variable -Werror=implicit-int -fno-asynchronous-unwind-tables -fno-pie -fno-pic -fno-strict-overflow -fno-reorder-functions -fno-defer-pop -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world=CMAKE_SOURCE_DIR -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr=ZEPHYR_BASE -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1=WEST_TOPDIR -ffunction-sections -fdata-sections -std=c99 -nostdinc -MD -MF C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr\CMakeFiles\offsets.dir\arch\arm\core\offsets\offsets.c.obj.d -fno-diagnostics-show-caret -o zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj -c C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c
1> In file included from ../../../include/arch/arm/aarch32/arch.h:20,
1>                  from ../../../include/arch/cpu.h:19,
1>                  from ../../../include/kernel_includes.h:33,
1>                  from ../../../include/kernel.h:17,
1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:21: warning: implicit declaration of function 'DT_INST' [-Wimplicit-function-declaration]
1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:44: error: pasting ")" and "_P_arm_num_irq_priority_bits" does not give a valid preprocessing token
1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: error: 'arm_v8m_nvic' undeclared (first use in this function)
1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: note: each undeclared identifier is reported only once for each function it appears in
1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
1> ../../../include/devicetree.h:463:48: error: expected ')' before '_P_arm_num_irq_priority_bits'
1> ../../../include/devicetree.h:2176:30: note: in definition of macro 'DT_CAT'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
1> In file included from ../../../include/arch/arm/aarch32/arch.h:26,
1>                  from ../../../include/arch/cpu.h:19,
1>                  from ../../../include/kernel_includes.h:33,
1>                  from ../../../include/kernel.h:17,
1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
1> ../../../include/arch/arm/aarch32/exc.h:24:36: note: to match this '('
1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
1> In file included from ../../../include/arch/arm/aarch32/arch.h:20,
1>                  from ../../../include/arch/cpu.h:19,
1>                  from ../../../include/kernel_includes.h:33,
1>                  from ../../../include/kernel.h:17,
1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:28: error: missing binary operator before token "("
1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
1> ../../../include/arch/arm/aarch32/cortex_m/cmsis.h:96:25: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
Build failed

Parents
  • Hi,

    Could I see your prj.conf file? Is your project based on a sample, or is it something you built from scratch? And which board version are you using? There should be a sticker on your board with "PCA10095 0.11.0" or something similar.

    I also just noticed that you are using two different SDKs. "ncs/v1.5.1/zephyr" and "ncs\v1.5.1-rc1\toolchain" are both used. I assume you are building with Segger Embedded Studio, when you open your project, make sure that both "nRF Connect SDK Release" and "nRF Connect Toolchain Version" are set to the same SDK. It is a known issue that they may be set to different SDKs by default, when you have multiple versions installed.

  • Hi,
    thank you Oivind
    my prj.conf file looks like this

    and it's a project took from samples 
    m using PCA10095 0.11.0

    how do i set  "nRF Connect SDK Release" and "nRF Connect Toolchain Version" to the same SDK please !

  • i don't know

    C:\Users\rzaafouri\ncs\v1.5.1-rc1\toolchain\opt/bin/arm-none-eabi-gcc -DBUILD_VERSION=v2.4.99-ncs2 -DKERNEL -DNRF5340_XXAA_APPLICATION -DUSE_PARTITION_MANAGER=0 -D_FORTIFY_SOURCE=2 -D__PROGRAM_START -D__ZEPHYR__=1 -I../../../kernel/include -I../../../arch/arm/include -I../../../include -Izephyr/include/generated -I../../../soc/arm/nordic_nrf/nrf53 -IC:/Users/rzaafouri/ncs/v1.5.1/nrf/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/drivers/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/mdk -I../../../modules/hal_nordic/nrfx/. -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/cmsis/CMSIS/Core/Include -isystem ../../../lib/libc/minimal/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include-fixed -isystem C:/Users/rzaafouri/ncs/v1.5.1/nrfxlib/crypto/nrf_cc312_platform/include -Os -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/autoconf.h -ffreestanding -fno-common -g -mcpu=cortex-m33 -mthumb -mabi=aapcs -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-main -Wno-pointer-sign -Wpointer-arith -Wno-address-of-packed-member -Wno-unused-but-set-variable -Werror=implicit-int -fno-asynchronous-unwind-tables -fno-pie -fno-pic -fno-strict-overflow -fno-reorder-functions -fno-defer-pop -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world=CMAKE_SOURCE_DIR -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr=ZEPHYR_BASE -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1=WEST_TOPDIR -ffunction-sections -fdata-sections -std=c99 -nostdinc -MD -MF C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr\CMakeFiles\offsets.dir\arch\arm\core\offsets\offsets.c.obj.d -fno-diagnostics-show-caret -o zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj -c C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c
    i don't know why the version v1.5.1-rc1 appears although i'm just using the v1.5.1 
    i don't know what can be causing this or how to fix it 

  • Ok, open SEGGER Embedded Studio, through the Toolchain Manager's "Open IDE" button, click "File" in the top-left and click "Open nRF Connect SDK Project".

    Then make sure you have the same SDK set for both "nRF Connect SDK Release" and "nRF Connect Toolchain Version", and that you are building for the nrf5340dk and not the nrf5340pdk. Here is a picture to go by:

  • my project was on the good version in both "nRF Connect SDK Release" and "nRF Connect Toolchain Version" 
    i re-builded the project and the error remain the same 

    here's a look on it 

    Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/misc/empty_file.c’ from solution ‘build’ in configuration ‘Common’
    Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/dt-bindings/gpio/gpio.h’ from solution ‘build’ in configuration ‘Common’
    Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/dt-bindings/i2c/i2c.h’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/misc/generated/syscalls.json’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/misc/generated/syscalls.json does not exist.
    1> Combining ‘zephyr/misc/generated/syscalls.json’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/parse_syscalls.py --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/drivers --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/subsys/net --json-file C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/syscalls.json --tag-struct-file C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/struct_tags.json
    Building ‘zephyr/misc/generated/struct_tags.json’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/CMakeFiles/parse_syscalls_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/parse_syscalls_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/driver-validation.h’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/include/generated/driver-validation.h does not exist.
    1> Combining ‘zephyr/include/generated/driver-validation.h’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/gen_kobject_list.py --validation-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/driver-validation.h --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/struct_tags.json
    Building ‘zephyr/CMakeFiles/driver_validation_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/driver_validation_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/kobj-types-enum.h’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/include/generated/kobj-types-enum.h does not exist.
    1> Combining ‘zephyr/include/generated/kobj-types-enum.h’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/gen_kobject_list.py --kobj-types-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/kobj-types-enum.h --kobj-otype-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/otype-to-str.h --kobj-size-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/otype-to-size.h --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/struct_tags.json
    Building ‘zephyr/include/generated/otype-to-str.h’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/CMakeFiles/kobj_types_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/kobj_types_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/syscall_list.h’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/include/generated/syscall_dispatch.c does not exist.
    1> Combining ‘zephyr/include/generated/syscall_list.h’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/gen_syscalls.py --json-file C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/syscalls.json --base-output include/generated/syscalls --syscall-dispatch include/generated/syscall_dispatch.c --syscall-list C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/syscall_list.h --split-type k_timeout_t
    Building ‘zephyr/CMakeFiles/syscall_list_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/syscall_dispatch.c’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/syscall_list_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘cmake_object_order_depends_target_offsets’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj does not exist.
    1> Compiling ‘offsets.c’
    1> C:\Users\rzaafouri\ncs\v1.5.1-rc1\toolchain\opt/bin/arm-none-eabi-gcc -DBUILD_VERSION=v2.4.99-ncs2 -DKERNEL -DNRF5340_XXAA_APPLICATION -DUSE_PARTITION_MANAGER=0 -D_FORTIFY_SOURCE=2 -D__PROGRAM_START -D__ZEPHYR__=1 -I../../../kernel/include -I../../../arch/arm/include -I../../../include -Izephyr/include/generated -I../../../soc/arm/nordic_nrf/nrf53 -IC:/Users/rzaafouri/ncs/v1.5.1/nrf/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/drivers/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/mdk -I../../../modules/hal_nordic/nrfx/. -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/cmsis/CMSIS/Core/Include -isystem ../../../lib/libc/minimal/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include-fixed -isystem C:/Users/rzaafouri/ncs/v1.5.1/nrfxlib/crypto/nrf_cc312_platform/include -Os -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/autoconf.h -ffreestanding -fno-common -g -mcpu=cortex-m33 -mthumb -mabi=aapcs -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-main -Wno-pointer-sign -Wpointer-arith -Wno-address-of-packed-member -Wno-unused-but-set-variable -Werror=implicit-int -fno-asynchronous-unwind-tables -fno-pie -fno-pic -fno-strict-overflow -fno-reorder-functions -fno-defer-pop -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world=CMAKE_SOURCE_DIR -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr=ZEPHYR_BASE -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1=WEST_TOPDIR -ffunction-sections -fdata-sections -std=c99 -nostdinc -MD -MF C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr\CMakeFiles\offsets.dir\arch\arm\core\offsets\offsets.c.obj.d -fno-diagnostics-show-caret -o zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj -c C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c
    1> In file included from ../../../include/arch/arm/aarch32/arch.h:20,
    1>                  from ../../../include/arch/cpu.h:19,
    1>                  from ../../../include/kernel_includes.h:33,
    1>                  from ../../../include/kernel.h:17,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:21: warning: implicit declaration of function 'DT_INST' [-Wimplicit-function-declaration]
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:44: error: pasting ")" and "_P_arm_num_irq_priority_bits" does not give a valid preprocessing token
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: error: 'arm_v8m_nvic' undeclared (first use in this function)
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: note: each undeclared identifier is reported only once for each function it appears in
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/devicetree.h:463:48: error: expected ')' before '_P_arm_num_irq_priority_bits'
    1> ../../../include/devicetree.h:2176:30: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> In file included from ../../../include/arch/arm/aarch32/arch.h:26,
    1>                  from ../../../include/arch/cpu.h:19,
    1>                  from ../../../include/kernel_includes.h:33,
    1>                  from ../../../include/kernel.h:17,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    1> ../../../include/arch/arm/aarch32/exc.h:24:36: note: to match this '('
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> In file included from ../../../include/arch/arm/aarch32/arch.h:20,
    1>                  from ../../../include/arch/cpu.h:19,
    1>                  from ../../../include/kernel_includes.h:33,
    1>                  from ../../../include/kernel.h:17,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:28: error: missing binary operator before token "("
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/cortex_m/cmsis.h:96:25: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    Build failed
    

Reply
  • my project was on the good version in both "nRF Connect SDK Release" and "nRF Connect Toolchain Version" 
    i re-builded the project and the error remain the same 

    here's a look on it 

    Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/misc/empty_file.c’ from solution ‘build’ in configuration ‘Common’
    Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/dt-bindings/gpio/gpio.h’ from solution ‘build’ in configuration ‘Common’
    Building ‘C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/dt-bindings/i2c/i2c.h’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/misc/generated/syscalls.json’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/misc/generated/syscalls.json does not exist.
    1> Combining ‘zephyr/misc/generated/syscalls.json’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/parse_syscalls.py --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/drivers --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/subsys/net --json-file C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/syscalls.json --tag-struct-file C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/struct_tags.json
    Building ‘zephyr/misc/generated/struct_tags.json’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/CMakeFiles/parse_syscalls_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/parse_syscalls_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/driver-validation.h’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/include/generated/driver-validation.h does not exist.
    1> Combining ‘zephyr/include/generated/driver-validation.h’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/gen_kobject_list.py --validation-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/driver-validation.h --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/struct_tags.json
    Building ‘zephyr/CMakeFiles/driver_validation_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/driver_validation_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/kobj-types-enum.h’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/include/generated/kobj-types-enum.h does not exist.
    1> Combining ‘zephyr/include/generated/kobj-types-enum.h’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/gen_kobject_list.py --kobj-types-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/kobj-types-enum.h --kobj-otype-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/otype-to-str.h --kobj-size-output C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/otype-to-size.h --include C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/struct_tags.json
    Building ‘zephyr/include/generated/otype-to-str.h’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/CMakeFiles/kobj_types_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/kobj_types_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/syscall_list.h’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/include/generated/syscall_dispatch.c does not exist.
    1> Combining ‘zephyr/include/generated/syscall_list.h’
    1> C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\python.exe C:/Users/rzaafouri/ncs/v1.5.1/zephyr/scripts/gen_syscalls.py --json-file C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/misc/generated/syscalls.json --base-output include/generated/syscalls --syscall-dispatch include/generated/syscall_dispatch.c --syscall-list C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/syscall_list.h --split-type k_timeout_t
    Building ‘zephyr/CMakeFiles/syscall_list_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/include/generated/syscall_dispatch.c’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/syscall_list_h_target’ from solution ‘build’ in configuration ‘Common’
    Building ‘cmake_object_order_depends_target_offsets’ from solution ‘build’ in configuration ‘Common’
    Building ‘zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj’ from solution ‘build’ in configuration ‘Common’
    1> zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj does not exist.
    1> Compiling ‘offsets.c’
    1> C:\Users\rzaafouri\ncs\v1.5.1-rc1\toolchain\opt/bin/arm-none-eabi-gcc -DBUILD_VERSION=v2.4.99-ncs2 -DKERNEL -DNRF5340_XXAA_APPLICATION -DUSE_PARTITION_MANAGER=0 -D_FORTIFY_SOURCE=2 -D__PROGRAM_START -D__ZEPHYR__=1 -I../../../kernel/include -I../../../arch/arm/include -I../../../include -Izephyr/include/generated -I../../../soc/arm/nordic_nrf/nrf53 -IC:/Users/rzaafouri/ncs/v1.5.1/nrf/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/drivers/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/mdk -I../../../modules/hal_nordic/nrfx/. -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/cmsis/CMSIS/Core/Include -isystem ../../../lib/libc/minimal/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include -isystem c:/users/rzaafouri/ncs/v1.5.1/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include-fixed -isystem C:/Users/rzaafouri/ncs/v1.5.1/nrfxlib/crypto/nrf_cc312_platform/include -Os -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr/include/generated/autoconf.h -ffreestanding -fno-common -g -mcpu=cortex-m33 -mthumb -mabi=aapcs -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-main -Wno-pointer-sign -Wpointer-arith -Wno-address-of-packed-member -Wno-unused-but-set-variable -Werror=implicit-int -fno-asynchronous-unwind-tables -fno-pie -fno-pic -fno-strict-overflow -fno-reorder-functions -fno-defer-pop -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world=CMAKE_SOURCE_DIR -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr=ZEPHYR_BASE -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1=WEST_TOPDIR -ffunction-sections -fdata-sections -std=c99 -nostdinc -MD -MF C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build_nrf5340dk_nrf5340_cpuapp/zephyr\CMakeFiles\offsets.dir\arch\arm\core\offsets\offsets.c.obj.d -fno-diagnostics-show-caret -o zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj -c C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c
    1> In file included from ../../../include/arch/arm/aarch32/arch.h:20,
    1>                  from ../../../include/arch/cpu.h:19,
    1>                  from ../../../include/kernel_includes.h:33,
    1>                  from ../../../include/kernel.h:17,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:21: warning: implicit declaration of function 'DT_INST' [-Wimplicit-function-declaration]
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:44: error: pasting ")" and "_P_arm_num_irq_priority_bits" does not give a valid preprocessing token
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: error: 'arm_v8m_nvic' undeclared (first use in this function)
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: note: each undeclared identifier is reported only once for each function it appears in
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> ../../../include/devicetree.h:463:48: error: expected ')' before '_P_arm_num_irq_priority_bits'
    1> ../../../include/devicetree.h:2176:30: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> In file included from ../../../include/arch/arm/aarch32/arch.h:26,
    1>                  from ../../../include/arch/cpu.h:19,
    1>                  from ../../../include/kernel_includes.h:33,
    1>                  from ../../../include/kernel.h:17,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    1> ../../../include/arch/arm/aarch32/exc.h:24:36: note: to match this '('
    1> ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
    1> ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
    1> In file included from ../../../include/arch/arm/aarch32/arch.h:20,
    1>                  from ../../../include/arch/cpu.h:19,
    1>                  from ../../../include/kernel_includes.h:33,
    1>                  from ../../../include/kernel.h:17,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
    1>                  from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:28: error: missing binary operator before token "("
    1> ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
    1> ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
    1> ../../../include/arch/arm/aarch32/cortex_m/cmsis.h:96:25: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
    Build failed
    

Children
  • i also tried to build it from cmd prompt in order to show what's happening exactly 
    and i just got this 

    C:\Users\rzaafouri\ncs\v1.5.1\zephyr\samples>cd hello_world
    
    C:\Users\rzaafouri\ncs\v1.5.1\zephyr\samples\hello_world>west build -b nrf5340dk_nrf5340_cpuapp
    [2/109] Building C object zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj
    FAILED: zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj
    C:\Users\rzaafouri\ncs\v1.6.0\toolchain\opt\bin\arm-none-eabi-gcc.exe -DBUILD_VERSION=v2.4.99-ncs2 -DKERNEL -DNRF5340_XXAA_APPLICATION -DUSE_PARTITION_MANAGER=0 -D_FORTIFY_SOURCE=2 -D__PROGRAM_START -D__ZEPHYR__=1 -I../../../kernel/include -I../../../arch/arm/include -I../../../include -Izephyr/include/generated -I../../../soc/arm/nordic_nrf/nrf53 -IC:/Users/rzaafouri/ncs/v1.5.1/nrf/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/drivers/include -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/nordic/nrfx/mdk -I../../../modules/hal_nordic/nrfx/. -IC:/Users/rzaafouri/ncs/v1.5.1/modules/hal/cmsis/CMSIS/Core/Include -isystem ../../../lib/libc/minimal/include -isystem c:/users/rzaafouri/ncs/v1.6.0/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include -isystem c:/users/rzaafouri/ncs/v1.6.0/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/include-fixed -isystem C:/Users/rzaafouri/ncs/v1.5.1/nrfxlib/crypto/nrf_cc312_platform/include -Os -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world/build/zephyr/include/generated/autoconf.h -ffreestanding -fno-common -g -mcpu=cortex-m33 -mthumb -mabi=aapcs -imacros C:/Users/rzaafouri/ncs/v1.5.1/zephyr/include/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-main -Wno-pointer-sign -Wpointer-arith -Wno-address-of-packed-member -Wno-unused-but-set-variable -Werror=implicit-int -fno-asynchronous-unwind-tables -fno-pie -fno-pic -fno-strict-overflow -fno-reorder-functions -fno-defer-pop -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr/samples/hello_world=CMAKE_SOURCE_DIR -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1/zephyr=ZEPHYR_BASE -fmacro-prefix-map=C:/Users/rzaafouri/ncs/v1.5.1=WEST_TOPDIR -ffunction-sections -fdata-sections -std=c99 -nostdinc -MD -MT zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj -MF zephyr\CMakeFiles\offsets.dir\arch\arm\core\offsets\offsets.c.obj.d -o zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj   -c C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c
    In file included from ../../../include/arch/arm/aarch32/arch.h:20,
                     from ../../../include/arch/cpu.h:19,
                     from ../../../include/kernel_includes.h:33,
                     from ../../../include/kernel.h:17,
                     from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
                     from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    ../../../include/arch/arm/aarch32/asm_inline_gcc.h: In function 'arch_irq_lock':
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:21: warning: implicit declaration of function 'DT_INST' [-Wimplicit-function-declaration]
       15 | #define NVIC_NODEID DT_INST(0, arm_v8m_nvic)
          |                     ^~~~~~~
    ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
     2176 | #define DT_CAT(a1, a2) a1 ## a2
          |                        ^~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                           ^~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                                   ^~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
       24 | #define Z_EXC_PRIO(pri) (((pri) << (8 - NUM_IRQ_PRIO_BITS)) & 0xff)
          |                                         ^~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
       60 | #define _EXC_IRQ_DEFAULT_PRIO Z_EXC_PRIO(_IRQ_PRIO_OFFSET)
          |                               ^~~~~~~~~~
    ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
       62 |   : "i"(_EXC_IRQ_DEFAULT_PRIO)
          |         ^~~~~~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:44: error: pasting ")" and "_P_arm_num_irq_priority_bits" does not give a valid preprocessing token
       15 | #define NVIC_NODEID DT_INST(0, arm_v8m_nvic)
          |                                            ^
    ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
     2176 | #define DT_CAT(a1, a2) a1 ## a2
          |                        ^~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                           ^~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                                   ^~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
       24 | #define Z_EXC_PRIO(pri) (((pri) << (8 - NUM_IRQ_PRIO_BITS)) & 0xff)
          |                                         ^~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
       60 | #define _EXC_IRQ_DEFAULT_PRIO Z_EXC_PRIO(_IRQ_PRIO_OFFSET)
          |                               ^~~~~~~~~~
    ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
       62 |   : "i"(_EXC_IRQ_DEFAULT_PRIO)
          |         ^~~~~~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: error: 'arm_v8m_nvic' undeclared (first use in this function)
       15 | #define NVIC_NODEID DT_INST(0, arm_v8m_nvic)
          |                                ^~~~~~~~~~~~
    ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
     2176 | #define DT_CAT(a1, a2) a1 ## a2
          |                        ^~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                           ^~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                                   ^~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
       24 | #define Z_EXC_PRIO(pri) (((pri) << (8 - NUM_IRQ_PRIO_BITS)) & 0xff)
          |                                         ^~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
       60 | #define _EXC_IRQ_DEFAULT_PRIO Z_EXC_PRIO(_IRQ_PRIO_OFFSET)
          |                               ^~~~~~~~~~
    ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
       62 |   : "i"(_EXC_IRQ_DEFAULT_PRIO)
          |         ^~~~~~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:32: note: each undeclared identifier is reported only once for each function it appears in
       15 | #define NVIC_NODEID DT_INST(0, arm_v8m_nvic)
          |                                ^~~~~~~~~~~~
    ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
     2176 | #define DT_CAT(a1, a2) a1 ## a2
          |                        ^~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                           ^~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                                   ^~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
       24 | #define Z_EXC_PRIO(pri) (((pri) << (8 - NUM_IRQ_PRIO_BITS)) & 0xff)
          |                                         ^~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
       60 | #define _EXC_IRQ_DEFAULT_PRIO Z_EXC_PRIO(_IRQ_PRIO_OFFSET)
          |                               ^~~~~~~~~~
    ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
       62 |   : "i"(_EXC_IRQ_DEFAULT_PRIO)
          |         ^~~~~~~~~~~~~~~~~~~~~
    ../../../include/devicetree.h:463:48: error: expected ')' before '_P_arm_num_irq_priority_bits'
      463 | #define DT_PROP(node_id, prop) DT_CAT(node_id, _P_##prop)
          |                                                ^~~
    ../../../include/devicetree.h:2176:30: note: in definition of macro 'DT_CAT'
     2176 | #define DT_CAT(a1, a2) a1 ## a2
          |                              ^~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                           ^~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:24:41: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
       24 | #define Z_EXC_PRIO(pri) (((pri) << (8 - NUM_IRQ_PRIO_BITS)) & 0xff)
          |                                         ^~~~~~~~~~~~~~~~~
    ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
       60 | #define _EXC_IRQ_DEFAULT_PRIO Z_EXC_PRIO(_IRQ_PRIO_OFFSET)
          |                               ^~~~~~~~~~
    ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
       62 |   : "i"(_EXC_IRQ_DEFAULT_PRIO)
          |         ^~~~~~~~~~~~~~~~~~~~~
    In file included from ../../../include/arch/arm/aarch32/arch.h:26,
                     from ../../../include/arch/cpu.h:19,
                     from ../../../include/kernel_includes.h:33,
                     from ../../../include/kernel.h:17,
                     from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
                     from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    ../../../include/arch/arm/aarch32/exc.h:24:36: note: to match this '('
       24 | #define Z_EXC_PRIO(pri) (((pri) << (8 - NUM_IRQ_PRIO_BITS)) & 0xff)
          |                                    ^
    ../../../include/arch/arm/aarch32/exc.h:60:31: note: in expansion of macro 'Z_EXC_PRIO'
       60 | #define _EXC_IRQ_DEFAULT_PRIO Z_EXC_PRIO(_IRQ_PRIO_OFFSET)
          |                               ^~~~~~~~~~
    ../../../include/arch/arm/aarch32/asm_inline_gcc.h:62:9: note: in expansion of macro '_EXC_IRQ_DEFAULT_PRIO'
       62 |   : "i"(_EXC_IRQ_DEFAULT_PRIO)
          |         ^~~~~~~~~~~~~~~~~~~~~
    In file included from ../../../include/arch/arm/aarch32/arch.h:20,
                     from ../../../include/arch/cpu.h:19,
                     from ../../../include/kernel_includes.h:33,
                     from ../../../include/kernel.h:17,
                     from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets_aarch32.c:28,
                     from C:/Users/rzaafouri/ncs/v1.5.1/zephyr/arch/arm/core/offsets/offsets.c:12:
    ../../../include/arch/arm/aarch32/cortex_m/cmsis.h: At top level:
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:15:28: error: missing binary operator before token "("
       15 | #define NVIC_NODEID DT_INST(0, arm_v8m_nvic)
          |                            ^
    ../../../include/devicetree.h:2176:24: note: in definition of macro 'DT_CAT'
     2176 | #define DT_CAT(a1, a2) a1 ## a2
          |                        ^~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:27: note: in expansion of macro 'DT_PROP'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                           ^~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/nvic.h:22:35: note: in expansion of macro 'NVIC_NODEID'
       22 | #define NUM_IRQ_PRIO_BITS DT_PROP(NVIC_NODEID, arm_num_irq_priority_bits)
          |                                   ^~~~~~~~~~~
    ../../../include/arch/arm/aarch32/cortex_m/cmsis.h:96:25: note: in expansion of macro 'NUM_IRQ_PRIO_BITS'
       96 | #if __NVIC_PRIO_BITS != NUM_IRQ_PRIO_BITS
          |                         ^~~~~~~~~~~~~~~~~
    ninja: build stopped: subcommand failed.
    FATAL ERROR: command exited with status 1: 'C:\Users\rzaafouri\ncs\v1.5.1\toolchain\opt\bin\cmake.EXE' --build 'C:\Users\rzaafouri\ncs\v1.5.1\zephyr\samples\hello_world\build'

    PS : this happening for all the projects i try to run

  • Back-up anything you have added and want to keep, then remove and reinstall the SDK.

  • Really, there's no other way ! 
    it will cause me many problems i will lose the west config Disappointed

    can you explain to me a little bit the problem please 
    because in this error i didn't really get what happened

  • What do you mean when you say you "will lost the west config"? Did you install the SDK manually? And not through the Toolchain Manager?

  • i did install everything through toolchain manager except west because it didn't work for me in the beginning so i added it manually

Related