From 428df3f1ab3d25ee8079c1ed17c5fd8205e1f675 Mon Sep 17 00:00:00 2001 From: Stephen Seo Date: Sat, 27 Aug 2016 13:32:32 +0900 Subject: [PATCH] Fixed not working as cmake subproject --- src/CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 83f8262..dd47d70 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -17,10 +17,10 @@ set(EntityComponentSystem_HEADERS EC/EC.hpp) add_library(EntityComponentSystem INTERFACE) -target_include_directories(EntityComponentSystem INTERFACE ${CMAKE_SOURCE_DIR}) +target_include_directories(EntityComponentSystem INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}) -include_directories(${CMAKE_SOURCE_DIR}) +include_directories(${CMAKE_CURRENT_SOURCE_DIR}) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -Wall -Wextra") @@ -49,7 +49,7 @@ if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) endif() -install(DIRECTORY ${CMAKE_SOURCE_DIR}/EC DESTINATION include) +install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/EC DESTINATION include) find_package(GTest)