rapidjson
rapidjson copied to clipboard
Remove CMakeLists.txt from NAMES in FIND_PATH call
FIND_PATH will search for satisfying directories in $PATH before any of the PATHS variables (i.e. ${GTEST_SEARCH_PATH}) [1]. So if you have any directory in your $PATH that contains a CMakeLists.txt it will be the result.
I ran into this issue when trying to build with the vendored gtest, since I had an unrelated directory in my $PATH that contained a CMakeLists.txt.
[1] https://cmake.org/cmake/help/v3.17/command/find_path.html