mirror of
https://github.com/netdata/netdata.git
synced 2025-04-13 17:19:11 +00:00
![]() If not explicitly set using exported environment variables, the choice of compilers and compiler targets used by CMake does not get propagated to sub-porjects created with ExternalProject_Add or FetchContent_Declare. In most cases this does not matter, because very few people are building using non-default compilers for their environment, but it can cause issues in two specific cases: - If building for the same system that the build is happening on, but using a non-default compiler specified using CMake arguments (instead of via exported environment variables), sub-projects will still use the default compiler for the system, which may result in linking errors (or runtime failures even if the link succeeds). - If cross-compiling and not using the preferred approaches of either a toolchain file or exported environment variables, sub-projects may not even build for the correct CPU architecture, causing the build to fail. This adds logic to ensure that the compiler and compiler targets get propagated correctly even if they are just specified on the command line, thus avoiding the above two possibilities. |
||
---|---|---|
.. | ||
FindGo.cmake | ||
NetdataCompilerFlags.cmake | ||
NetdataDetectSystemd.cmake | ||
NetdataEBPFCORE.cmake | ||
NetdataEBPFLegacy.cmake | ||
NetdataFetchContentExtra.cmake | ||
NetdataGoTools.cmake | ||
NetdataJSONC.cmake | ||
NetdataLibBPF.cmake | ||
NetdataProtobuf.cmake | ||
NetdataSentry.cmake | ||
NetdataUtil.cmake | ||
NetdataVersion.cmake | ||
NetdataYAML.cmake | ||
Packaging.cmake |