File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -40,6 +40,7 @@ option(BUILD_FFMPEG_VULKAN_PATCHES "Apply FFmpeg Vulkan patches" ON)
4040
4141# common includes
4242include (${CMAKE_CURRENT_SOURCE_DIR } /cmake/apply_git_patch.cmake )
43+ include (${CMAKE_CURRENT_SOURCE_DIR } /cmake/git_fetch_tags.cmake )
4344include (${CMAKE_CURRENT_SOURCE_DIR } /cmake/unix_path.cmake )
4445
4546# CPM
Original file line number Diff line number Diff line change 1- # x265.pc will not be installed if their cmake cannot detect the latest tag
2- # SVT-AV1 cannot determine version if the git history is not available
3- foreach (repo "x265_git" "SVT-AV1" )
4- execute_process (
5- COMMAND git -C "${CMAKE_CURRENT_SOURCE_DIR } /third-party/FFmpeg/${repo} " fetch --tags --depth=1
6- COMMAND_ERROR_IS_FATAL ANY
7- )
8- endforeach ()
9-
101# the destination directory needs to be same level down as the original source directory
112file (COPY ${CMAKE_CURRENT_SOURCE_DIR } /third-party/FFmpeg DESTINATION ${CMAKE_CURRENT_BINARY_DIR }
123 PATTERN "Vulkan-Loader/tests" EXCLUDE ) # vulkan loader test files contain emojis in file names which can fail
Original file line number Diff line number Diff line change 1+ # SVT-AV1 cannot determine version if the git history is not available
2+ GIT_FETCH_TAGS ("third-party/FFmpeg/SVT-AV1" )
3+
14set (SVT_AV1_GENERATED_SRC_PATH ${CMAKE_CURRENT_BINARY_DIR } /FFmpeg/SVT-AV1)
25
36if (BUILD_FFMPEG_ALL_PATCHES OR BUILD_FFMPEG_SVT_AV1_PATCHES)
Original file line number Diff line number Diff line change 1+ # x265.pc will not be installed if their cmake cannot detect the latest tag
2+ GIT_FETCH_TAGS ("third-party/FFmpeg/x265_git" )
3+
14set (X265_GENERATED_SRC_PATH ${CMAKE_CURRENT_BINARY_DIR } /FFmpeg/x265_git)
25
36file (GLOB X265_GIT_FILES ${CMAKE_CURRENT_SOURCE_DIR } /patches/FFmpeg/x265_git/*.patch )
Original file line number Diff line number Diff line change 1+ # This macro fetches tags for the given git repository
2+ # Arguments are path to git repository
3+
4+ # GIT_FETCH_TAGS: args = `repo_path`
5+ macro (GIT_FETCH_TAGS repo_path )
6+ execute_process (
7+ COMMAND git -C "${CMAKE_CURRENT_SOURCE_DIR } /${repo_path} " fetch --tags --depth=1
8+ COMMAND_ERROR_IS_FATAL ANY
9+ )
10+ endmacro ()
You can’t perform that action at this time.
0 commit comments