1if( FREERTOS_PORT STREQUAL "GCC_RISC_V_GENERIC" )
2    set( VALID_CHIP_EXTENSIONS
3            "Pulpino_Vega_RV32M1RM"
4            "RISCV_MTIME_CLINT_no_extensions"
5            "RISCV_no_extensions"
6            "RV32I_CLINT_no_extensions" )
7
8    if( ( NOT FREERTOS_RISCV_EXTENSION ) OR ( NOT ( ${FREERTOS_RISCV_EXTENSION} IN_LIST VALID_CHIP_EXTENSIONS ) ) )
9        message(FATAL_ERROR
10                "FREERTOS_RISCV_EXTENSION \"${FREERTOS_RISCV_EXTENSION}\" is not set or unsupported.\n"
11                "Please specify it from top-level CMake file (example):\n"
12                "   set(FREERTOS_RISCV_EXTENSION RISCV_MTIME_CLINT_no_extensions CACHE STRING \"\")\n"
13                " or from CMake command line option:\n"
14                "   -DFREERTOS_RISCV_EXTENSION=RISCV_MTIME_CLINT_no_extensions\n"
15                "\n"
16                " Available extension options:\n"
17                "   ${VALID_CHIP_EXTENSIONS} \n")
18    endif()
19endif()
20