CMake не получит библиотеки / функциональность, связанные с Zephyr RTOS - PullRequest
1 голос
/ 02 апреля 2019

Я унаследовал кодовую базу , и автор недоступен для вопросов: /

Всякий раз, когда я пытаюсь его скомпилировать:

source ~/source/path-to-zephyr/zephyr-env.sh
cd ~/source/path-to-wallet/
mkdir build; cd build; cmake -GNinja -DBOARD=qemu_x86 -DBUILD_XCOMPILE=1 ../

CMake Error at cmake/zephyr.cmake:7 (zephyr_get_include_directories_for_lang_as_string):
  Unknown CMake command "zephyr_get_include_directories_for_lang_as_string".
Call Stack (most recent call first):
  CMakeLists.txt:15 (include)


CMake Warning (dev) in CMakeLists.txt:
  No cmake_minimum_required command is present.  A line of code such as

    cmake_minimum_required(VERSION 3.13)

  should be added at the top of the file.  The version specified may be lower
  if you wish to support older CMake versions for this project.  For more
  information run "cmake --help-policy CMP0000".
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Configuring incomplete, errors occurred!
See also "/home/shinichi/source/wallet/build/CMakeFiles/CMakeOutput.log".

Почему можно 't CMake найти $ ZEPHYR_BASE?Конечно, он знает, как найти функцию с именем zephyr_get_include_directories_for_lang_as_string, иначе в инструкциях по компиляции были бы упомянуты некоторые дополнительные необходимые шаги.

Поэтому я немного исследовал cmake и подумал, что добавлю эту строку в wallet /CMakeLists.txt: include($ENV{ZEPHYR_BASE}/cmake/extensions.cmake)

Но это только дало мне больше ошибок, что указывает на нечто более глубокое, не найдя код RTOS Zephyr:

...
 get_property could not find TARGET zephyr_interface.  Perhaps it has not
  yet been created.
Call Stack (most recent call first):
  /home/shinichi/source/zephyrproject/zephyr/cmake/extensions.cmake:187 (get_property_and_add_prefix)
  /home/shinichi/source/zephyrproject/zephyr/cmake/extensions.cmake:155 (zephyr_get_include_directories_for_lang)
  cmake/zephyr.cmake:7 (zephyr_get_include_directories_for_lang_as_string)
  CMakeLists.txt:16 (include)


CMake Error at /home/shinichi/source/zephyrproject/zephyr/cmake/extensions.cmake:301 (get_property):
  get_property could not find TARGET zephyr_interface.  Perhaps it has not
  yet been created.
Call Stack (most recent call first):
  /home/shinichi/source/zephyrproject/zephyr/cmake/extensions.cmake:198 (get_property_and_add_prefix)
  /home/shinichi/source/zephyrproject/zephyr/cmake/extensions.cmake:163 (zephyr_get_system_include_directories_for_lang)
  cmake/zephyr.cmake:8 (zephyr_get_system_include_directories_for_lang_as_string)
  CMakeLists.txt:16 (include)
...

Есть идеи?

...