c5b5892b6d
Some packages test for CMAKE_SYSTEM explicitly[1] CMAKE_SYSTEM is comprised of CMAKE_SYSTEM_NAME and CMAKE_SYSTEM_VERSION. It defaults to CMAKE_SYSTEM_NAME if CMAKE_SYSTEM_VERSION is not set[2] At the point CMAKE_SYSTEM_NAME is set to "Linux" CMAKE_SYSTEM is already constructed. Setting it explicitly ensures that it is the correct value. This is because we do set CMAKE_SYSTEM_NAME twice, in fact: - first in toolchainfile.cmake, so that we tell cmake to use the "Buildroot" platform, - second, in the Buildroot.cmake platform definition itself, so that we eventually behave like the Linux platform. We also set CMAKE_SYSTEM_VERSION to 1, and so the real CMAKE_SYSTEM value should be set to Linux-1 if we were to follow the documentation to the letter. However, for Linux, the version does not matter, and in some situations may even be harmful (that was reported in one of the commits that introduce Buildroot.cmake and toolchainfile.cmake). [1] Fluidsynth |
||
---|---|---|
.. | ||
config-fragments | ||
dependencies | ||
docker | ||
download | ||
gnuconfig | ||
kconfig | ||
legal-info | ||
libtool | ||
misc | ||
scripts | ||
testing |