diff --git a/CMakeLists.txt b/CMakeLists.txt index ea6bdb971..20e1684c6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -71,7 +71,7 @@ FOREACH(subdir ${sub_DIRS}) continue() endif() - STRING(REGEX REPLACE "^${CMAKE_SOURCE_DIR}/" "" subdir_rel ${subdir}) + STRING(REPLACE "${CMAKE_SOURCE_DIR}/" "" subdir_rel ${subdir}) if(EXISTS "${subdir}/CMakeLists.txt") add_subdirectory("${subdir_rel}") endif()