Skip to content

Commit

Permalink
cmake: Don't build nv-codec headers unless ENABLE_NVDEC is set.
Browse files Browse the repository at this point in the history
Fixes #1021.
  • Loading branch information
linuxdude42 committed Jan 30, 2025
1 parent d6faefe commit ae1c92d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cmake/embeddedlibs/FindOrBuildNvCodecHeaders.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@
# the FFmpeg configure script will disable nvdec, nvec, and ffnvcodec, so
# there's no point in setting up the headers.
#
if(NOT CMAKE_SYSTEM_NAME MATCHES "Linux|Windows" OR NOT CMAKE_SYSTEM_PROCESSOR
MATCHES "x86|aarch64")
if(NOT ENABLE_NVDEC
OR NOT CMAKE_SYSTEM_NAME MATCHES "Linux|Windows"
OR NOT CMAKE_SYSTEM_PROCESSOR MATCHES "x86|aarch64")
list(APPEND FF_ARGS --disable-nvdec --disable-nvenc --disable-ffnvcodec)
return()
endif()
Expand Down
1 change: 1 addition & 0 deletions mythtv/cmake/MythFindPackages.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ find_package(PkgConfig REQUIRED)
# have already been compiled and installed by the super-package.
#
if(NOT CMAKE_CROSSCOMPILING
AND ENABLE_NVDEC
AND CMAKE_SYSTEM_NAME MATCHES "Linux|Windows"
AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86|aarch64")
pkg_check_modules(FFNVCODEC ffnvcodec REQUIRED IMPORTED_TARGET)
Expand Down

0 comments on commit ae1c92d

Please sign in to comment.