Skip to content

Commit

Permalink
[ffmpeg] Disable vdpau in UNIX (#10161)
Browse files Browse the repository at this point in the history
* [ffmpeg] Disable vdpau in UNIX

* [ffmpeg] Disable vdpau in OSX only

* [freerdp] Add warning message when building in non-windows

* revert 1ec7785 changes
  • Loading branch information
JackBoosY authored Mar 28, 2020
1 parent 7b0dea5 commit 9efff11
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ports/ffmpeg/FindFFMPEG.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ set(FFMPEG_VERSION "4.2")

find_dependency(Threads)
if(UNIX)
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS -pthread -lvdpau -lX11)
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS -pthread -lX11)
endif()

if(@ENABLE_BZIP2@)
Expand Down
8 changes: 6 additions & 2 deletions ports/ffmpeg/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,10 @@ if("avresample" IN_LIST FEATURES)
set(OPTIONS "${OPTIONS} --enable-avresample")
endif()

if (VCPKG_TARGET_IS_OSX)
set(OPTIONS "${OPTIONS} --disable-vdpau") # disable vdpau in OSX
endif()

if("nvcodec" IN_LIST FEATURES)
set(OPTIONS "${OPTIONS} --enable-cuda --enable-nvenc --enable-cuvid --disable-libnpp")
else()
Expand All @@ -152,7 +156,7 @@ else()
message(FATAL_ERROR "Unsupported architecture")
endif()

if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
if(VCPKG_TARGET_IS_UWP)
set(ENV{LIBPATH} "$ENV{LIBPATH};$ENV{_WKITS10}references\\windows.foundation.foundationcontract\\2.0.0.0\\;$ENV{_WKITS10}references\\windows.foundation.universalapicontract\\3.0.0.0\\")
set(OPTIONS "${OPTIONS} --disable-programs")
set(OPTIONS "${OPTIONS} --extra-cflags=-DWINAPI_FAMILY=WINAPI_FAMILY_APP --extra-cflags=-D_WIN32_WINNT=0x0A00")
Expand All @@ -166,7 +170,7 @@ set(OPTIONS "${OPTIONS} ${OPTIONS_CROSS}")

if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
set(OPTIONS "${OPTIONS} --disable-static --enable-shared")
if (VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
if (VCPKG_TARGET_IS_UWP)
set(OPTIONS "${OPTIONS} --extra-ldflags=-APPCONTAINER --extra-ldflags=WindowsApp.lib")
endif()
endif()
Expand Down

0 comments on commit 9efff11

Please sign in to comment.