-
Notifications
You must be signed in to change notification settings - Fork 26
Open
Description
I'm trying to add libmemcached target in my project by
add_subdirectory(${AWESOMIZED_MEMCACHED_DIR})
and it seems that it fails to find _Configure:
CMake Error at cmake-build-debug/_deps/libmemcached-src/CMake/_Include.cmake:1 (include):
include could not find requested file:
_Configure
that is included from CMake/_Include like so:
include(_Configure)
I found that this fixes the issue:
set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)
And this is how I learned about difference :D
There is a difference between these variables. CMAKE_SOURCE_DIR does indeed refer to the folder where the top-level CMakeLists.txt is defined. However, PROJECT_SOURCE_DIR refers to the folder of the CMakeLists.txt containing the most recent project() command.
Thus in most cases PROJCET_SOURCE_DIR variable should be used
Metadata
Metadata
Assignees
Labels
No labels