Compilation failed if ftxui was used in projects that were not git repositories. Since, in CMakeLists.txt working directory to execute command was (#61)

set as the parent directory and not the FTXUI project directory.

* Changed the working directory variable to ${CMAKE_CURRENT_SOURCE_DIR}, so as to get the version of FTXUI and not that of parent project
This commit is contained in:
Vedant Paranjape 2020-11-14 19:30:38 +05:30 committed by GitHub
parent 406355df8c
commit afd53e0508
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.0)
execute_process( execute_process(
COMMAND git rev-list --count HEAD COMMAND git rev-list --count HEAD
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
OUTPUT_VARIABLE git_version OUTPUT_VARIABLE git_version
OUTPUT_STRIP_TRAILING_WHITESPACE OUTPUT_STRIP_TRAILING_WHITESPACE
) )