mirror of
https://github.com/wolfpld/tracy.git
synced 2026-09-12 13:28:15 +00:00
Merge pull request #1060 from evan-barentin/eb-fix-git-ref-call-outside-source
Fix profiler compilation when build directory is outside the source directory
This commit is contained in:
@@ -193,7 +193,7 @@ endif()
|
||||
find_package(Git)
|
||||
if(Git_FOUND)
|
||||
add_custom_target(git-ref
|
||||
COMMAND ${GIT_EXECUTABLE} log -1 "--format=#pragma once %nnamespace tracy { static inline const char* GitRef = %x22%h%x22; }" ${GIT_REV} > GitRef.hpp.tmp
|
||||
COMMAND ${GIT_EXECUTABLE} -C ${CMAKE_CURRENT_SOURCE_DIR} log -1 "--format=#pragma once %nnamespace tracy { static inline const char* GitRef = %x22%h%x22; }" ${GIT_REV} > GitRef.hpp.tmp
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different GitRef.hpp.tmp GitRef.hpp
|
||||
BYPRODUCTS GitRef.hpp GitRef.hpp.tmp
|
||||
VERBATIM
|
||||
|
||||
Reference in New Issue
Block a user