summaryrefslogtreecommitdiff
path: root/CMake
diff options
context:
space:
mode:
authorVladimir Glavnyy <31897320+vglavnyy@users.noreply.github.com>2018-06-01 22:22:17 +0700
committerWouter van Oortmerssen <aardappel@gmail.com>2018-06-01 08:22:17 -0700
commitecc07e77939b465b98dab1e7ec4de2013c84b253 (patch)
tree4d28d0c77424ff571a2b5dafabc56fb8312be083 /CMake
parent43944a0ab1d10082b04b06543bcd5340c4a80a11 (diff)
downloadflatbuffers-ecc07e77939b465b98dab1e7ec4de2013c84b253.tar.gz
flatbuffers-ecc07e77939b465b98dab1e7ec4de2013c84b253.tar.bz2
flatbuffers-ecc07e77939b465b98dab1e7ec4de2013c84b253.zip
Fix a small problem with add_subdirectory(${FLATBUFFERS_DIR}) from top level project. (#4764)
Diffstat (limited to 'CMake')
-rw-r--r--CMake/Version.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/CMake/Version.cmake b/CMake/Version.cmake
index 3522ec6a..db6613b8 100644
--- a/CMake/Version.cmake
+++ b/CMake/Version.cmake
@@ -1,7 +1,7 @@
find_program(GIT git)
execute_process(
COMMAND ${GIT} describe
- WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
+ WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
OUTPUT_VARIABLE GIT_DESCRIBE_DIRTY
OUTPUT_STRIP_TRAILING_WHITESPACE
)