diff --git a/ports/ffmpeg/portfile.cmake b/ports/ffmpeg/portfile.cmake index c905401c16892d..0f3121bf4a9628 100644 --- a/ports/ffmpeg/portfile.cmake +++ b/ports/ffmpeg/portfile.cmake @@ -1,3 +1,132 @@ +#Check for unsupported features + +if("ffmpeg" IN_LIST FEATURES) + vcpkg_fail_port_install(ON_TARGET "UWP" MESSAGE "Feature 'ffmpeg' does not support 'uwp'") +endif() + +if("ffplay" IN_LIST FEATURES) + vcpkg_fail_port_install(ON_TARGET "UWP" MESSAGE "Feature 'ffplay' does not support 'uwp'") +endif() + +if("ffprobe" IN_LIST FEATURES) + vcpkg_fail_port_install(ON_TARGET "UWP" MESSAGE "Feature 'ffprobe' does not support 'uwp'") +endif() + + +if("ass" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_IS_UWP) + message(FATAL_ERROR "Feature 'ass' does not support 'uwp | arm'") + endif() +endif() + +if("avisynthplus" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR (NOT VCPKG_TARGET_IS_WINDOWS)) + message(FATAL_ERROR "Feature 'avisynthplus' does not support '!windows | arm | uwp'") + endif() +endif() + +if("dav1d" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x86" OR VCPKG_TARGET_IS_UWP OR VCPKG_TARGET_IS_OSX) + message(FATAL_ERROR "Feature 'dav1d' does not support 'uwp | arm | x86 | osx'") + endif() +endif() + +if("fdk-aac" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_IS_UWP) + message(FATAL_ERROR "Feature 'fdk-aac' does not support 'uwp | arm'") + endif() +endif() + +if("fontconfig" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_IS_UWP OR (VCPKG_TARGET_IS_WINDOWS AND VCPKG_LIBRARY_LINKAGE STREQUAL "static")) + message(FATAL_ERROR "Feature 'fontconfig' does not support 'uwp | arm | (windows & static)'") + endif() +endif() + +if("fribidi" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_IS_UWP) + message(FATAL_ERROR "Feature 'fribidi' does not support 'uwp | arm'") + endif() +endif() + +if("ilbc" IN_LIST FEATURES) + if ((VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64") AND VCPKG_TARGET_IS_UWP) + message(FATAL_ERROR "Feature 'ilbc' does not support 'uwp & arm'") + endif() +endif() + +if("modplug" IN_LIST FEATURES) + if (VCPKG_TARGET_IS_UWP OR (VCPKG_TARGET_IS_WINDOWS AND VCPKG_LIBRARY_LINKAGE STREQUAL "static")) + message(FATAL_ERROR "Feature 'modplug' does not support 'uwp | (windows & static)'") + endif() +endif() + +if("nvcodec" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR ((NOT VCPKG_TARGET_IS_WINDOWS) AND (NOT VCPKG_TARGET_IS_LINUX))) + message(FATAL_ERROR "Feature 'nvcodec' does not support '!(windows | linux) | uwp | arm'") + endif() +endif() + +if("opencl" IN_LIST FEATURES) + vcpkg_fail_port_install(ON_TARGET "UWP" MESSAGE "Feature 'opencl' does not support 'uwp'") +endif() + +if("opengl" IN_LIST FEATURES) + if (((VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64") AND VCPKG_TARGET_IS_WINDOWS) OR VCPKG_TARGET_IS_UWP OR VCPKG_TARGET_IS_OSX) + message(FATAL_ERROR "Feature 'opengl' does not support 'uwp | (windows & arm) | osx'") + endif() +endif() + +if("openh264" IN_LIST FEATURES) + vcpkg_fail_port_install(ON_TARGET "UWP" MESSAGE "Feature 'openh264' does not support 'uwp'") +endif() + +if("sdl2" IN_LIST FEATURES) + vcpkg_fail_port_install(ON_TARGET "OSX" MESSAGE "Feature 'sdl2' does not support 'osx'") +endif() + +if("ssh" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_IS_UWP OR VCPKG_LIBRARY_LINKAGE STREQUAL "static") + message(FATAL_ERROR "Feature 'ssh' does not support 'uwp | arm | static'") + endif() +endif() + +if("tensorflow" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_IS_UWP OR VCPKG_LIBRARY_LINKAGE STREQUAL "static" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x86") + message(FATAL_ERROR "Feature 'tensorflow' does not support 'x86 | arm | uwp | static'") + endif() +endif() + +if("tesseract" IN_LIST FEATURES) + if (((VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64") AND VCPKG_TARGET_IS_WINDOWS) OR VCPKG_TARGET_IS_UWP OR VCPKG_LIBRARY_LINKAGE STREQUAL "static") + message(FATAL_ERROR "Feature 'tesseract' does not support 'uwp | (windows & arm) | static'") + endif() +endif() + +if("wavpack" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64") + message(FATAL_ERROR "Feature 'wavpack' does not support 'arm'") + endif() +endif() + +if("x264" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64") + message(FATAL_ERROR "Feature 'x264' does not support 'arm'") + endif() +endif() + +if("x265" IN_LIST FEATURES) + if (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64" OR VCPKG_TARGET_IS_UWP) + message(FATAL_ERROR "Feature 'x265' does not support 'uwp | arm'") + endif() +endif() + +if("xml2" IN_LIST FEATURES) + if (VCPKG_LIBRARY_LINKAGE STREQUAL "static") + message(FATAL_ERROR "Feature 'xml2' does not support 'static'") + endif() +endif() + if(VCPKG_TARGET_IS_WINDOWS) set(PATCHES 0017-Patch-for-ticket-9019-CUDA-Compile-Broken-Using-MSVC.patch) # https://trac.ffmpeg.org/ticket/9019 endif() @@ -234,18 +363,6 @@ else() set(OPTIONS "${OPTIONS} --disable-libdav1d") endif() -if("iconv" IN_LIST FEATURES) - set(OPTIONS "${OPTIONS} --enable-iconv") -else() - set(OPTIONS "${OPTIONS} --disable-iconv") -endif() - -if("ilbc" IN_LIST FEATURES) - set(OPTIONS "${OPTIONS} --enable-libilbc") -else() - set(OPTIONS "${OPTIONS} --disable-libilbc") -endif() - if("fdk-aac" IN_LIST FEATURES) set(OPTIONS "${OPTIONS} --enable-libfdk-aac") else() @@ -270,6 +387,18 @@ else() set(OPTIONS "${OPTIONS} --disable-libfribidi") endif() +if("iconv" IN_LIST FEATURES) + set(OPTIONS "${OPTIONS} --enable-iconv") +else() + set(OPTIONS "${OPTIONS} --disable-iconv") +endif() + +if("ilbc" IN_LIST FEATURES) + set(OPTIONS "${OPTIONS} --enable-libilbc") +else() + set(OPTIONS "${OPTIONS} --disable-libilbc") +endif() + if("lzma" IN_LIST FEATURES) set(OPTIONS "${OPTIONS} --enable-lzma") else() diff --git a/ports/ffmpeg/vcpkg.json b/ports/ffmpeg/vcpkg.json index d64ac5bb1fd51f..fe16cfed194c3f 100644 --- a/ports/ffmpeg/vcpkg.json +++ b/ports/ffmpeg/vcpkg.json @@ -1,7 +1,7 @@ { "name": "ffmpeg", "version": "4.4", - "port-version": 4, + "port-version": 5, "description": [ "a library to decode, encode, transcode, mux, demux, stream, filter and play pretty much anything that humans and machines have created.", "FFmpeg is the leading multimedia framework, able to decode, encode, transcode, mux, demux, stream, filter and play pretty much anything that humans and machines have created. It supports the most obscure ancient formats up to the cutting edge. No matter if they were designed by some standards committee, the community or a corporation. It is also highly portable: FFmpeg compiles, runs, and passes our testing infrastructure FATE across Linux, Mac OS X, Microsoft Windows, the BSDs, Solaris, etc. under a wide variety of build environments, machine architectures, and configurations." @@ -183,7 +183,7 @@ "features": [ "avisynthplus" ], - "platform": "windows & !arm & !uwp & !static" + "platform": "windows & !arm & !uwp" } ] }, diff --git a/versions/baseline.json b/versions/baseline.json index 8c59d3e7dd1741..8abc09ab2c5478 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -1982,7 +1982,7 @@ }, "ffmpeg": { "baseline": "4.4", - "port-version": 4 + "port-version": 5 }, "ffnvcodec": { "baseline": "10.0.26.0", diff --git a/versions/f-/ffmpeg.json b/versions/f-/ffmpeg.json index 3691438cc31abd..a39b1d79a8f05f 100644 --- a/versions/f-/ffmpeg.json +++ b/versions/f-/ffmpeg.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "234eb0e352d2a7be0a3b34fb9eb8a9f0417ffe94", + "version": "4.4", + "port-version": 5 + }, { "git-tree": "dfea2c203835c55baec68138cc7e8c65ebcce33a", "version": "4.4",