I noticed using FetchContent_MakeAvailable instead of FetchContent_Populate as in the example CMakeLists will give way to building tests and examples, which blocked the cmake for downloading and building googletest and generated a lot of binaries irrelevant to my project
So I wonder if it's appropriate to add some conditionals to CMakeLists.txt to control the building process, this PR will turn off the examples and tests building in default mode. After that, if the library users happen to use FetchContent_MakeAvailable incidentally, they won't have to build the tests and examples by default. The test is slow to initialize in regions with poor networks.
Also, when building my project with this library for the first time, I noticed the example code has an include problem, I am not using any IDE, so perhaps this is caused by IDEs?
Hi, the library is great, thanks!
I ran into some trivial problems when including this library, in my CMakeLists.txt I have the following statements:
I noticed using
FetchContent_MakeAvailable
instead ofFetchContent_Populate
as in the example CMakeLists will give way to building tests and examples, which blocked the cmake for downloading and building googletest and generated a lot of binaries irrelevant to my projectSo I wonder if it's appropriate to add some conditionals to CMakeLists.txt to control the building process, this PR will turn off the examples and tests building in default mode. After that, if the library users happen to use
FetchContent_MakeAvailable
incidentally, they won't have to build the tests and examples by default. The test is slow to initialize in regions with poor networks.To enable them, we can run the following command:
Also, when building my project with this library for the first time, I noticed the example code has an include problem, I am not using any IDE, so perhaps this is caused by IDEs?
Best regards!