From 60306450b7a7354825660e69a30877760c48395a Mon Sep 17 00:00:00 2001 From: Sascha Cunz Date: Wed, 29 Jan 2014 23:47:20 +0000 Subject: [PATCH] Use relative path to set cmake module path This has actually no effect on a "normal" build, but allows to use libgit2 as a part of a larger project via CMake's ADD_SUBDIRECTORY() Closes #2087 --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index f1c81eb6f..611cd9eec 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -15,7 +15,7 @@ PROJECT(libgit2 C) CMAKE_MINIMUM_REQUIRED(VERSION 2.6) # Add find modules to the path -SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/") +SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_LIST_DIR}/cmake/Modules/") # Build options #