message: Detect RISC-V compiler from PATH environment variable
diff: set(CMAKE_SYSTEM_NAME Linux)
  set(CMAKE_SYSTEM_PROCESSOR riscv64)
  -set(RISCV_GCC_INSTALL_ROOT /opt/RISCV CACHE PATH "Path to GCC for RISC-V cross compiler installation directory")
  -set(CMAKE_SYSROOT ${RISCV_GCC_INSTALL_ROOT}/sysroot CACHE PATH "RISC-V sysroot")
  +if(NOT DEFINED CMAKE_C_COMPILER)
  + find_program(CMAKE_C_COMPILER NAMES riscv64-unknown-linux-gnu-gcc
  + PATHS /opt/RISCV/bin ENV PATH)
  +endif()
  +
  +if(NOT DEFINED CMAKE_CXX_COMPILER)
  + find_program(CMAKE_CXX_COMPILER NAMES riscv64-unknown-linux-gnu-g++
  + PATHS /opt/RISCV/bin ENV PATH)
  +endif()
  -set(CMAKE_C_COMPILER ${RISCV_GCC_INSTALL_ROOT}/bin/riscv64-unknown-linux-gnu-gcc)
  -set(CMAKE_CXX_COMPILER ${RISCV_GCC_INSTALL_ROOT}/bin/riscv64-unknown-linux-gnu-g++)
  +get_filename_component(RISCV_GCC_INSTALL_ROOT ${CMAKE_C_COMPILER} DIRECTORY)
  +get_filename_component(RISCV_GCC_INSTALL_ROOT ${RISCV_GCC_INSTALL_ROOT} DIRECTORY)
  +
  +set(CMAKE_SYSROOT ${RISCV_GCC_INSTALL_ROOT}/sysroot CACHE PATH "RISC-V sysroot")
  # Don't run the linker on compiler check
  set(CMAKE_TRY_COMPILE_TARGET_TYPE STATIC_LIBRARY)
  