2023-02-16 17:41:37 +00:00
|
|
|
|
{ lib, stdenv, buildPackages, removeReferencesTo, addOpenGLRunpath, pkg-config, perl, texinfo, yasm
|
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
|
# You can fetch any upstream version using this derivation by specifying version and hash
|
|
|
|
|
# NOTICE: Always use this argument to override the version. Do not use overrideAttrs.
|
|
|
|
|
, version # ffmpeg ABI version. Also declare this if you're overriding the source.
|
|
|
|
|
, hash ? "" # hash of the upstream source for the given ABI version
|
|
|
|
|
, source ? fetchgit {
|
|
|
|
|
url = "https://git.ffmpeg.org/ffmpeg.git";
|
|
|
|
|
rev = "n${version}";
|
|
|
|
|
inherit hash;
|
|
|
|
|
}
|
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, ffmpegVariant ? "small" # Decides which dependencies are enabled by default
|
|
|
|
|
|
|
|
|
|
# Build with headless deps; excludes dependencies that are only necessary for
|
|
|
|
|
# GUI applications. To be used for purposes that don't generally need such
|
|
|
|
|
# components and i.e. only depend on libav
|
|
|
|
|
, withHeadlessDeps ? ffmpegVariant == "headless" || withSmallDeps
|
|
|
|
|
|
|
|
|
|
# Dependencies a user might customarily expect from a regular ffmpeg build.
|
|
|
|
|
# /All/ packages that depend on ffmpeg and some of its feaures should depend
|
|
|
|
|
# on the small variant. Small means the minimal set of features that satisfies
|
|
|
|
|
# all dependants in Nixpkgs
|
|
|
|
|
, withSmallDeps ? ffmpegVariant == "small" || withFullDeps
|
|
|
|
|
|
|
|
|
|
# Everything enabled; only guarded behind platform exclusivity or brokeness.
|
|
|
|
|
# If you need to depend on ffmpeg-full because ffmpeg is missing some feature
|
|
|
|
|
# your package needs, you should enable that feature in regular ffmpeg
|
|
|
|
|
# instead.
|
|
|
|
|
, withFullDeps ? ffmpegVariant == "full"
|
|
|
|
|
|
|
|
|
|
, fetchgit
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, fetchpatch2
|
2023-02-16 17:41:37 +00:00
|
|
|
|
|
|
|
|
|
# Feature flags
|
|
|
|
|
, withAlsa ? withHeadlessDeps && stdenv.isLinux # Alsa in/output supporT
|
|
|
|
|
, withAom ? withFullDeps # AV1 reference encoder
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withAppKit ? withHeadlessDeps && stdenv.isDarwin # Apple AppKit framework
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, withAribcaption ? withFullDeps && lib.versionAtLeast version "6.1" # ARIB STD-B24 Caption Decoder/Renderer
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withAss ? withHeadlessDeps && stdenv.hostPlatform == stdenv.buildPlatform # (Advanced) SubStation Alpha subtitle rendering
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withAudioToolbox ? withHeadlessDeps && stdenv.isDarwin # Apple AudioToolbox
|
|
|
|
|
, withAvFoundation ? withHeadlessDeps && stdenv.isDarwin # Apple AVFoundation framework
|
2024-05-15 15:35:15 +00:00
|
|
|
|
, withAvisynth ? withFullDeps # AviSynth script files reading
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withBluray ? withFullDeps # BluRay reading
|
|
|
|
|
, withBs2b ? withFullDeps # bs2b DSP library
|
|
|
|
|
, withBzlib ? withHeadlessDeps
|
|
|
|
|
, withCaca ? withFullDeps # Textual display (ASCII art)
|
|
|
|
|
, withCelt ? withFullDeps # CELT decoder
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withChromaprint ? withFullDeps # Audio fingerprinting
|
2024-05-15 15:35:15 +00:00
|
|
|
|
, withCodec2 ? withFullDeps # codec2 en/decoding
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withCoreImage ? withHeadlessDeps && stdenv.isDarwin # Apple CoreImage framework
|
|
|
|
|
, withCuda ? withFullDeps && withNvcodec
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withCudaLLVM ? withFullDeps
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withCuvid ? withHeadlessDeps && withNvcodec
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withDav1d ? withHeadlessDeps # AV1 decoder (focused on speed and correctness)
|
|
|
|
|
, withDc1394 ? withFullDeps && !stdenv.isDarwin # IIDC-1394 grabbing (ieee 1394)
|
|
|
|
|
, withDrm ? withHeadlessDeps && (with stdenv; isLinux || isFreeBSD) # libdrm support
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withDvdnav ? withFullDeps && withGPL && lib.versionAtLeast version "7" # needed for DVD demuxing
|
|
|
|
|
, withDvdread ? withFullDeps && withGPL && lib.versionAtLeast version "7" # needed for DVD demuxing
|
|
|
|
|
, withFdkAac ? withFullDeps && (!withGPL || withUnfree) # Fraunhofer FDK AAC de/encoder
|
|
|
|
|
, withNvcodec ? withHeadlessDeps && (with stdenv; !isDarwin && !isAarch32 && !hostPlatform.isRiscV && hostPlatform == buildPlatform) # dynamically linked Nvidia code
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withFlite ? withFullDeps # Voice Synthesis
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withFontconfig ? withHeadlessDeps # Needed for drawtext filter
|
|
|
|
|
, withFreetype ? withHeadlessDeps # Needed for drawtext filter
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withFrei0r ? withFullDeps && withGPL # frei0r video filtering
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withFribidi ? withFullDeps # Needed for drawtext filter
|
|
|
|
|
, withGme ? withFullDeps # Game Music Emulator
|
|
|
|
|
, withGnutls ? withHeadlessDeps
|
|
|
|
|
, withGsm ? withFullDeps # GSM de/encoder
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withHarfbuzz ? withHeadlessDeps && lib.versionAtLeast version "6.1" # Needed for drawtext filter
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withIconv ? withHeadlessDeps
|
|
|
|
|
, withJack ? withFullDeps && !stdenv.isDarwin # Jack audio
|
2024-05-15 15:35:15 +00:00
|
|
|
|
, withJxl ? withFullDeps && lib.versionAtLeast version "5" # JPEG XL de/encoding
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withLadspa ? withFullDeps # LADSPA audio filtering
|
|
|
|
|
, withLzma ? withHeadlessDeps # xz-utils
|
2024-01-02 11:29:13 +00:00
|
|
|
|
, withMfx ? withFullDeps && (with stdenv.hostPlatform; isLinux && !isAarch) # Hardware acceleration via intel-media-sdk/libmfx
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withModplug ? withFullDeps && !stdenv.isDarwin # ModPlug support
|
|
|
|
|
, withMp3lame ? withHeadlessDeps # LAME MP3 encoder
|
|
|
|
|
, withMysofa ? withFullDeps # HRTF support via SOFAlizer
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withNvdec ? withHeadlessDeps && withNvcodec
|
|
|
|
|
, withNvenc ? withHeadlessDeps && withNvcodec
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withOgg ? withHeadlessDeps # Ogg container used by vorbis & theora
|
|
|
|
|
, withOpenal ? withFullDeps # OpenAL 1.1 capture support
|
|
|
|
|
, withOpencl ? withFullDeps
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withOpencoreAmrnb ? withFullDeps && withVersion3 # AMR-NB de/encoder
|
|
|
|
|
, withOpencoreAmrwb ? withFullDeps && withVersion3 # AMR-WB decoder
|
|
|
|
|
, withOpengl ? withFullDeps && !stdenv.isDarwin # OpenGL rendering
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withOpenh264 ? withFullDeps # H.264/AVC encoder
|
|
|
|
|
, withOpenjpeg ? withFullDeps # JPEG 2000 de/encoder
|
|
|
|
|
, withOpenmpt ? withFullDeps # Tracked music files decoder
|
|
|
|
|
, withOpus ? withHeadlessDeps # Opus de/encoder
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withPlacebo ? withFullDeps && !stdenv.isDarwin # libplacebo video processing library
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withPulse ? withSmallDeps && stdenv.isLinux # Pulseaudio input support
|
|
|
|
|
, withQrencode ? withFullDeps && lib.versionAtLeast version "7" # QR encode generation
|
|
|
|
|
, withQuirc ? withFullDeps && lib.versionAtLeast version "7" # QR decoding
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withRav1e ? withFullDeps # AV1 encoder (focused on speed and safety)
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withRtmp ? withFullDeps # RTMP[E] support
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withSamba ? withFullDeps && !stdenv.isDarwin && withGPLv3 # Samba protocol
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withSdl2 ? withSmallDeps
|
2024-01-25 14:12:00 +00:00
|
|
|
|
, withShaderc ? withFullDeps && !stdenv.isDarwin && lib.versionAtLeast version "5.0"
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withSoxr ? withHeadlessDeps # Resampling via soxr
|
|
|
|
|
, withSpeex ? withHeadlessDeps # Speex de/encoder
|
|
|
|
|
, withSrt ? withHeadlessDeps # Secure Reliable Transport (SRT) protocol
|
|
|
|
|
, withSsh ? withHeadlessDeps # SFTP protocol
|
|
|
|
|
, withSvg ? withFullDeps # SVG protocol
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withSvtav1 ? withHeadlessDeps && !stdenv.isAarch64 && !stdenv.hostPlatform.isMinGW # AV1 encoder/decoder (focused on speed and correctness)
|
|
|
|
|
, withTensorflow ? false # Tensorflow dnn backend support (Increases closure size by ~390 MiB)
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withTheora ? withHeadlessDeps # Theora encoder
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withV4l2 ? withHeadlessDeps && stdenv.isLinux # Video 4 Linux support
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withV4l2M2m ? withV4l2
|
|
|
|
|
, withVaapi ? withHeadlessDeps && (with stdenv; isLinux || isFreeBSD) # Vaapi hardware acceleration
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withVdpau ? withSmallDeps && !stdenv.hostPlatform.isMinGW # Vdpau hardware acceleration
|
|
|
|
|
, withVideoToolbox ? withHeadlessDeps && stdenv.isDarwin # Apple VideoToolbox
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withVidStab ? withFullDeps && withGPL # Video stabilization
|
|
|
|
|
, withVmaf ? withFullDeps && !stdenv.isAarch64 && lib.versionAtLeast version "5" # Netflix's VMAF (Video Multi-Method Assessment Fusion)
|
|
|
|
|
, withVoAmrwbenc ? withFullDeps && withVersion3 # AMR-WB encoder
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withVorbis ? withHeadlessDeps # Vorbis de/encoding, native encoder exists
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withVpl ? false # Hardware acceleration via intel libvpl
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withVpx ? withHeadlessDeps && stdenv.buildPlatform == stdenv.hostPlatform # VP8 & VP9 de/encoding
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withVulkan ? withSmallDeps && !stdenv.isDarwin
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withWebp ? withFullDeps # WebP encoder
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withX264 ? withHeadlessDeps && withGPL # H.264/AVC encoder
|
|
|
|
|
, withX265 ? withHeadlessDeps && withGPL # H.265/HEVC encoder
|
|
|
|
|
, withXavs ? withFullDeps && withGPL # AVS encoder
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withXcb ? withXcbShm || withXcbxfixes || withXcbShape # X11 grabbing using XCB
|
|
|
|
|
, withXcbShape ? withFullDeps # X11 grabbing shape rendering
|
|
|
|
|
, withXcbShm ? withFullDeps # X11 grabbing shm communication
|
|
|
|
|
, withXcbxfixes ? withFullDeps # X11 grabbing mouse rendering
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, withXevd ? withFullDeps && lib.versionAtLeast version "7" && stdenv.hostPlatform.isx86 # MPEG-5 EVC decoding
|
|
|
|
|
, withXeve ? withFullDeps && lib.versionAtLeast version "7" && stdenv.hostPlatform.isx86 # MPEG-5 EVC encoding
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withXlib ? withFullDeps # Xlib support
|
|
|
|
|
, withXml2 ? withFullDeps # libxml2 support, for IMF and DASH demuxers
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withXvid ? withHeadlessDeps && withGPL # Xvid encoder, native encoder exists
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withZimg ? withHeadlessDeps
|
|
|
|
|
, withZlib ? withHeadlessDeps
|
|
|
|
|
, withZmq ? withFullDeps # Message passing
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* Licensing options (yes some are listed twice, filters and such are not listed)
|
|
|
|
|
*/
|
|
|
|
|
, withGPL ? true
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withVersion3 ? true # When withGPL is set this implies GPLv3 otherwise it is LGPLv3
|
|
|
|
|
, withGPLv3 ? withGPL && withVersion3
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, withUnfree ? false
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* Build options
|
|
|
|
|
*/
|
|
|
|
|
, withSmallBuild ? false # Optimize for size instead of speed
|
|
|
|
|
, withRuntimeCPUDetection ? true # Detect CPU capabilities at runtime (disable to compile natively)
|
|
|
|
|
, withGrayscale ? withFullDeps # Full grayscale support
|
|
|
|
|
, withSwscaleAlpha ? buildSwscale # Alpha channel support in swscale. You probably want this when buildSwscale.
|
|
|
|
|
, withHardcodedTables ? withHeadlessDeps # Hardcode decode tables instead of runtime generation
|
|
|
|
|
, withSafeBitstreamReader ? withHeadlessDeps # Buffer boundary checking in bitreaders
|
|
|
|
|
, withMultithread ? true # Multithreading via pthreads/win32 threads
|
|
|
|
|
, withNetwork ? withHeadlessDeps # Network support
|
|
|
|
|
, withPixelutils ? withHeadlessDeps # Pixel utils in libavutil
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, withStatic ? stdenv.hostPlatform.isStatic
|
|
|
|
|
, withShared ? !stdenv.hostPlatform.isStatic
|
|
|
|
|
, withPic ? true
|
|
|
|
|
, withThumb ? false # On some ARM platforms
|
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
/*
|
|
|
|
|
* Program options
|
|
|
|
|
*/
|
|
|
|
|
, buildFfmpeg ? withHeadlessDeps # Build ffmpeg executable
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, buildFfplay ? withSmallDeps # Build ffplay executable
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, buildFfprobe ? withHeadlessDeps # Build ffprobe executable
|
|
|
|
|
, buildQtFaststart ? withFullDeps # Build qt-faststart executable
|
|
|
|
|
, withBin ? buildFfmpeg || buildFfplay || buildFfprobe || buildQtFaststart
|
|
|
|
|
/*
|
|
|
|
|
* Library options
|
|
|
|
|
*/
|
|
|
|
|
, buildAvcodec ? withHeadlessDeps # Build avcodec library
|
|
|
|
|
, buildAvdevice ? withHeadlessDeps # Build avdevice library
|
|
|
|
|
, buildAvfilter ? withHeadlessDeps # Build avfilter library
|
|
|
|
|
, buildAvformat ? withHeadlessDeps # Build avformat library
|
|
|
|
|
# Deprecated but depended upon by some packages.
|
|
|
|
|
# https://github.com/NixOS/nixpkgs/pull/211834#issuecomment-1417435991)
|
|
|
|
|
, buildAvresample ? withHeadlessDeps && lib.versionOlder version "5" # Build avresample library
|
|
|
|
|
, buildAvutil ? withHeadlessDeps # Build avutil library
|
|
|
|
|
, buildPostproc ? withHeadlessDeps # Build postproc library
|
|
|
|
|
, buildSwresample ? withHeadlessDeps # Build swresample library
|
|
|
|
|
, buildSwscale ? withHeadlessDeps # Build swscale library
|
|
|
|
|
, withLib ? buildAvcodec
|
|
|
|
|
|| buildAvdevice
|
|
|
|
|
|| buildAvfilter
|
|
|
|
|
|| buildAvformat
|
|
|
|
|
|| buildAvutil
|
|
|
|
|
|| buildPostproc
|
|
|
|
|
|| buildSwresample
|
|
|
|
|
|| buildSwscale
|
|
|
|
|
/*
|
|
|
|
|
* Documentation options
|
|
|
|
|
*/
|
|
|
|
|
, withDocumentation ? withHtmlDoc || withManPages || withPodDoc || withTxtDoc
|
|
|
|
|
, withHtmlDoc ? withHeadlessDeps # HTML documentation pages
|
|
|
|
|
, withManPages ? withHeadlessDeps # Man documentation pages
|
|
|
|
|
, withPodDoc ? withHeadlessDeps # POD documentation pages
|
|
|
|
|
, withTxtDoc ? withHeadlessDeps # Text documentation pages
|
|
|
|
|
# Whether a "doc" output will be produced. Note that withManPages does not produce
|
|
|
|
|
# a "doc" output because its files go to "man".
|
|
|
|
|
, withDoc ? withDocumentation && (withHtmlDoc || withPodDoc || withTxtDoc)
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* Developer options
|
|
|
|
|
*/
|
|
|
|
|
, withDebug ? false
|
|
|
|
|
, withOptimisations ? true
|
|
|
|
|
, withExtraWarnings ? false
|
|
|
|
|
, withStripping ? false
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* External libraries options
|
|
|
|
|
*/
|
|
|
|
|
, alsa-lib
|
2024-05-15 15:35:15 +00:00
|
|
|
|
, avisynthplus
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, bzip2
|
|
|
|
|
, celt
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, chromaprint
|
2024-05-15 15:35:15 +00:00
|
|
|
|
, codec2
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, clang
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, dav1d
|
|
|
|
|
, fdk_aac
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, flite
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, fontconfig
|
|
|
|
|
, freetype
|
|
|
|
|
, frei0r
|
|
|
|
|
, fribidi
|
|
|
|
|
, game-music-emu
|
|
|
|
|
, gnutls
|
|
|
|
|
, gsm
|
2024-02-29 20:09:43 +00:00
|
|
|
|
, harfbuzz
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, intel-media-sdk
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, ladspaH
|
|
|
|
|
, lame
|
|
|
|
|
, libaom
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, libaribcaption
|
|
|
|
|
, libass
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, libbluray
|
|
|
|
|
, libbs2b
|
|
|
|
|
, libcaca
|
|
|
|
|
, libdc1394
|
|
|
|
|
, libdrm
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, libdvdnav
|
|
|
|
|
, libdvdread
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, libGL
|
|
|
|
|
, libGLU
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, libiconv
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, libjack2
|
2024-05-15 15:35:15 +00:00
|
|
|
|
, libjxl
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, libmodplug
|
|
|
|
|
, libmysofa
|
|
|
|
|
, libogg
|
|
|
|
|
, libopenmpt
|
|
|
|
|
, libopus
|
2023-04-29 16:46:19 +00:00
|
|
|
|
, libplacebo
|
2024-01-25 14:12:00 +00:00
|
|
|
|
, libplacebo_5
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, libpulseaudio
|
|
|
|
|
, libraw1394
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, librsvg
|
|
|
|
|
, libssh
|
2023-05-24 13:37:59 +00:00
|
|
|
|
, libtensorflow
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, libtheora
|
|
|
|
|
, libv4l
|
|
|
|
|
, libva
|
|
|
|
|
, libva-minimal
|
|
|
|
|
, libvdpau
|
|
|
|
|
, libvmaf
|
|
|
|
|
, libvorbis
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, libvpl
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, libvpx
|
|
|
|
|
, libwebp
|
|
|
|
|
, libX11
|
|
|
|
|
, libxcb
|
|
|
|
|
, libXext
|
|
|
|
|
, libxml2
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, libXv
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, nv-codec-headers
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, nv-codec-headers-12
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, ocl-icd # OpenCL ICD
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, openal
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, opencl-headers # OpenCL headers
|
|
|
|
|
, opencore-amr
|
|
|
|
|
, openh264
|
|
|
|
|
, openjpeg
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, qrencode
|
|
|
|
|
, quirc
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, rav1e
|
|
|
|
|
, rtmpdump
|
|
|
|
|
, samba
|
|
|
|
|
, SDL2
|
2024-01-25 14:12:00 +00:00
|
|
|
|
, shaderc
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, soxr
|
|
|
|
|
, speex
|
|
|
|
|
, srt
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, svt-av1
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, vid-stab
|
|
|
|
|
, vo-amrwbenc
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, vulkan-headers
|
|
|
|
|
, vulkan-loader
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, x264
|
|
|
|
|
, x265
|
|
|
|
|
, xavs
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, xevd
|
|
|
|
|
, xeve
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, xvidcore
|
2024-01-13 08:15:51 +00:00
|
|
|
|
, xz
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, zeromq4
|
|
|
|
|
, zimg
|
|
|
|
|
, zlib
|
|
|
|
|
/*
|
|
|
|
|
* Darwin frameworks
|
|
|
|
|
*/
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, AppKit
|
|
|
|
|
, AudioToolbox
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, AVFoundation
|
2024-04-21 15:54:59 +00:00
|
|
|
|
, CoreImage
|
2023-02-16 17:41:37 +00:00
|
|
|
|
, VideoToolbox
|
|
|
|
|
/*
|
|
|
|
|
* Testing
|
|
|
|
|
*/
|
|
|
|
|
, testers
|
2020-04-24 23:36:52 +00:00
|
|
|
|
}:
|
|
|
|
|
|
|
|
|
|
/* Maintainer notes:
|
|
|
|
|
*
|
2023-02-16 17:41:37 +00:00
|
|
|
|
* Version bumps:
|
|
|
|
|
* It should always be safe to bump patch releases (e.g. 2.1.x, x being a patch release)
|
|
|
|
|
* If adding a new branch, note any configure flags that were added, changed, or deprecated/removed
|
|
|
|
|
* and make the necessary changes.
|
2020-04-24 23:36:52 +00:00
|
|
|
|
*
|
|
|
|
|
* Known issues:
|
2023-02-16 17:41:37 +00:00
|
|
|
|
* Cross-compiling will disable features not present on host OS
|
|
|
|
|
* (e.g. dxva2 support [DirectX] will not be enabled unless natively compiled on Cygwin)
|
2020-04-24 23:36:52 +00:00
|
|
|
|
*
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
let
|
2024-04-21 15:54:59 +00:00
|
|
|
|
inherit (lib) optional optionals optionalString enableFeature versionOlder versionAtLeast;
|
2023-02-16 17:41:37 +00:00
|
|
|
|
in
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
assert lib.elem ffmpegVariant [ "headless" "small" "full" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
/*
|
|
|
|
|
* Licensing dependencies
|
|
|
|
|
*/
|
2024-02-29 20:09:43 +00:00
|
|
|
|
assert withGPLv3 -> withGPL && withVersion3;
|
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
/*
|
|
|
|
|
* Build dependencies
|
|
|
|
|
*/
|
|
|
|
|
assert withPixelutils -> buildAvutil;
|
2024-04-21 15:54:59 +00:00
|
|
|
|
assert !(withMfx && withVpl); # incompatible features
|
2023-02-16 17:41:37 +00:00
|
|
|
|
/*
|
|
|
|
|
* Program dependencies
|
|
|
|
|
*/
|
|
|
|
|
assert buildFfmpeg -> buildAvcodec
|
|
|
|
|
&& buildAvfilter
|
|
|
|
|
&& buildAvformat
|
|
|
|
|
&& (buildSwresample || buildAvresample);
|
|
|
|
|
assert buildFfplay -> buildAvcodec
|
|
|
|
|
&& buildAvformat
|
|
|
|
|
&& buildSwscale
|
|
|
|
|
&& (buildSwresample || buildAvresample);
|
|
|
|
|
assert buildFfprobe -> buildAvcodec && buildAvformat;
|
|
|
|
|
/*
|
|
|
|
|
* Library dependencies
|
|
|
|
|
*/
|
|
|
|
|
assert buildAvcodec -> buildAvutil; # configure flag since 0.6
|
|
|
|
|
assert buildAvdevice -> buildAvformat
|
|
|
|
|
&& buildAvcodec
|
|
|
|
|
&& buildAvutil; # configure flag since 0.6
|
|
|
|
|
assert buildAvformat -> buildAvcodec && buildAvutil; # configure flag since 0.6
|
|
|
|
|
assert buildPostproc -> buildAvutil;
|
|
|
|
|
assert buildSwscale -> buildAvutil;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
|
/*
|
|
|
|
|
* External Library dependencies
|
|
|
|
|
*/
|
|
|
|
|
assert (withCuda || withCuvid || withNvdec || withNvenc) -> withNvcodec;
|
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
2023-08-04 22:07:22 +00:00
|
|
|
|
pname = "ffmpeg" + (optionalString (ffmpegVariant != "small") "-${ffmpegVariant}");
|
2020-04-24 23:36:52 +00:00
|
|
|
|
inherit version;
|
2024-04-21 15:54:59 +00:00
|
|
|
|
src = source;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
postPatch = ''
|
|
|
|
|
patchShebangs .
|
|
|
|
|
'' + lib.optionalString withFrei0r ''
|
|
|
|
|
substituteInPlace libavfilter/vf_frei0r.c \
|
|
|
|
|
--replace /usr/local/lib/frei0r-1 ${frei0r}/lib/frei0r-1
|
|
|
|
|
substituteInPlace doc/filters.texi \
|
|
|
|
|
--replace /usr/local/lib/frei0r-1 ${frei0r}/lib/frei0r-1
|
|
|
|
|
'';
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
|
patches = map (patch: fetchpatch2 patch) ([ ]
|
|
|
|
|
++ optionals (versionOlder version "5") [
|
|
|
|
|
{
|
|
|
|
|
name = "libsvtav1-1.5.0-compat-compressed_ten_bit_format.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/031f1561cd286596cdb374da32f8aa816ce3b135";
|
|
|
|
|
hash = "sha256-agJgzIzrBTQBAypuCmGXXFo7vw6Iodw5Ny5O5QCKCn8=";
|
2023-03-27 19:17:25 +00:00
|
|
|
|
}
|
2024-04-21 15:54:59 +00:00
|
|
|
|
{
|
|
|
|
|
# Backport fix for binutils-2.41.
|
|
|
|
|
name = "binutils-2.41.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/effadce6c756247ea8bae32dc13bb3e6f464f0eb";
|
|
|
|
|
hash = "sha256-vLSltvZVMcQ0CnkU0A29x6fJSywE8/aU+Mp9os8DZYY=";
|
|
|
|
|
}
|
|
|
|
|
# The upstream patch isn’t for ffmpeg 4, but it will apply with a few tweaks.
|
|
|
|
|
# Fixes a crash when built with clang 16 due to UB in ff_seek_frame_binary.
|
|
|
|
|
{
|
|
|
|
|
name = "utils-fix_crash_in_ff_seek_frame_binary.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/ab792634197e364ca1bb194f9abe36836e42f12d";
|
|
|
|
|
hash = "sha256-vqqVACjbCcGL9Qvmg1QArSKqVmOqr8BEr+OxTBDt6mA=";
|
|
|
|
|
postFetch = ''
|
|
|
|
|
substituteInPlace "$out" \
|
|
|
|
|
--replace libavformat/seek.c libavformat/utils.c \
|
|
|
|
|
--replace 'const AVInputFormat *const ' 'const AVInputFormat *'
|
|
|
|
|
'';
|
|
|
|
|
}
|
|
|
|
|
]
|
2024-05-15 15:35:15 +00:00
|
|
|
|
++ (lib.optionals (lib.versionAtLeast version "5" && lib.versionOlder version "6") [
|
|
|
|
|
{
|
|
|
|
|
name = "fix_build_failure_due_to_libjxl_version_to_new";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/75b1a555a70c178a9166629e43ec2f6250219eb2";
|
|
|
|
|
hash = "sha256-+2kzfPJf5piim+DqEgDuVEEX5HLwRsxq0dWONJ4ACrU=";
|
|
|
|
|
}
|
2024-06-05 15:53:02 +00:00
|
|
|
|
{
|
|
|
|
|
name = "5.x-CVE-2024-31585.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/8711cea3841fc385cccb1e7255176479e865cd4d";
|
|
|
|
|
hash = "sha256-WT+ly/l04yM/tRVbhkESA3sDDjwvtd/Cg2y8tQo4ApI=";
|
|
|
|
|
}
|
|
|
|
|
{
|
|
|
|
|
name = "CVE-2024-31582.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/99debe5f823f45a482e1dc08de35879aa9c74bd2";
|
|
|
|
|
hash = "sha256-+CQ9FXR6Vr/AmsbXFiCUXZcxKj1s8nInEdke/Oc/kUA=";
|
|
|
|
|
}
|
|
|
|
|
{
|
|
|
|
|
name = "CVE-2024-31578.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/3bb00c0a420c3ce83c6fafee30270d69622ccad7";
|
|
|
|
|
hash = "sha256-oZMZysBA+/gwaGEM1yvI+8wCadXWE7qLRL6Emap3b8Q=";
|
|
|
|
|
}
|
2024-05-15 15:35:15 +00:00
|
|
|
|
])
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ (lib.optionals (lib.versionAtLeast version "6.1" && lib.versionOlder version "6.2") [
|
2024-01-13 08:15:51 +00:00
|
|
|
|
{ # this can be removed post 6.1
|
|
|
|
|
name = "fix_build_failure_due_to_PropertyKey_EncoderID";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/cb049d377f54f6b747667a93e4b719380c3e9475";
|
2024-04-21 15:54:59 +00:00
|
|
|
|
hash = "sha256-sxRXKKgUak5vsQTiV7ge8vp+N22CdTIvuczNgVRP72c=";
|
|
|
|
|
}
|
|
|
|
|
{
|
|
|
|
|
name = "fix_vulkan_av1";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/e06ce6d2b45edac4a2df04f304e18d4727417d24";
|
|
|
|
|
hash = "sha256-73mlX1rdJrguw7OXaSItfHtI7gflDrFj+7SepVvvUIg=";
|
2024-01-13 08:15:51 +00:00
|
|
|
|
}
|
2024-06-05 15:53:02 +00:00
|
|
|
|
{
|
|
|
|
|
name = "CVE-2024-31582.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/99debe5f823f45a482e1dc08de35879aa9c74bd2";
|
|
|
|
|
hash = "sha256-+CQ9FXR6Vr/AmsbXFiCUXZcxKj1s8nInEdke/Oc/kUA=";
|
|
|
|
|
}
|
|
|
|
|
{
|
|
|
|
|
name = "CVE-2024-31578.patch";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/3bb00c0a420c3ce83c6fafee30270d69622ccad7";
|
|
|
|
|
hash = "sha256-oZMZysBA+/gwaGEM1yvI+8wCadXWE7qLRL6Emap3b8Q=";
|
|
|
|
|
}
|
2024-04-21 15:54:59 +00:00
|
|
|
|
])
|
|
|
|
|
++ (lib.optionals (lib.versionAtLeast version "7.0") [
|
|
|
|
|
{
|
|
|
|
|
# Will likely be obsolete in >7.0
|
|
|
|
|
name = "fate_avoid_dependency_on_samples";
|
|
|
|
|
url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/7b7b7819bd21cc92ac07f6696b0e7f26fa8f9834";
|
|
|
|
|
hash = "sha256-TKI289XqtG86Sj9s7mVYvmkjAuRXeK+2cYYEDkg6u6I=";
|
|
|
|
|
}
|
|
|
|
|
]));
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
|
|
configurePlatforms = [];
|
2023-02-16 17:41:37 +00:00
|
|
|
|
setOutputFlags = false; # Only accepts some of them
|
|
|
|
|
configureFlags = [
|
|
|
|
|
#mingw64 is internally treated as mingw32, so 32 and 64 make no difference here
|
|
|
|
|
"--target_os=${if stdenv.hostPlatform.isMinGW then "mingw64" else stdenv.hostPlatform.parsed.kernel.name}"
|
|
|
|
|
"--arch=${stdenv.hostPlatform.parsed.cpu.name}"
|
|
|
|
|
"--pkg-config=${buildPackages.pkg-config.targetPrefix}pkg-config"
|
|
|
|
|
/*
|
|
|
|
|
* Licensing flags
|
|
|
|
|
*/
|
|
|
|
|
(enableFeature withGPL "gpl")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withVersion3 "version3")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withUnfree "nonfree")
|
|
|
|
|
/*
|
|
|
|
|
* Build flags
|
|
|
|
|
*/
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withStatic "static")
|
|
|
|
|
(enableFeature withShared "shared")
|
|
|
|
|
(enableFeature withPic "pic")
|
|
|
|
|
(enableFeature withThumb "thumb")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
|
|
|
|
|
(enableFeature withSmallBuild "small")
|
|
|
|
|
(enableFeature withRuntimeCPUDetection "runtime-cpudetect")
|
|
|
|
|
(enableFeature withGrayscale "gray")
|
|
|
|
|
(enableFeature withSwscaleAlpha "swscale-alpha")
|
|
|
|
|
(enableFeature withHardcodedTables "hardcoded-tables")
|
|
|
|
|
(enableFeature withSafeBitstreamReader "safe-bitstream-reader")
|
|
|
|
|
|
2024-01-02 11:29:13 +00:00
|
|
|
|
(enableFeature (withMultithread && stdenv.hostPlatform.isUnix) "pthreads")
|
|
|
|
|
(enableFeature (withMultithread && stdenv.hostPlatform.isWindows) "w32threads")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
"--disable-os2threads" # We don't support OS/2
|
|
|
|
|
|
|
|
|
|
(enableFeature withNetwork "network")
|
|
|
|
|
(enableFeature withPixelutils "pixelutils")
|
|
|
|
|
|
|
|
|
|
"--datadir=${placeholder "data"}/share/ffmpeg"
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* Program flags
|
|
|
|
|
*/
|
|
|
|
|
(enableFeature buildFfmpeg "ffmpeg")
|
|
|
|
|
(enableFeature buildFfplay "ffplay")
|
|
|
|
|
(enableFeature buildFfprobe "ffprobe")
|
|
|
|
|
] ++ optionals withBin [
|
|
|
|
|
"--bindir=${placeholder "bin"}/bin"
|
|
|
|
|
] ++ [
|
|
|
|
|
/*
|
|
|
|
|
* Library flags
|
|
|
|
|
*/
|
|
|
|
|
(enableFeature buildAvcodec "avcodec")
|
|
|
|
|
(enableFeature buildAvdevice "avdevice")
|
|
|
|
|
(enableFeature buildAvfilter "avfilter")
|
|
|
|
|
(enableFeature buildAvformat "avformat")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (lib.versionOlder version "5") [
|
2023-02-16 17:41:37 +00:00
|
|
|
|
# Ffmpeg > 4 doesn't know about the flag anymore
|
|
|
|
|
(enableFeature buildAvresample "avresample")
|
|
|
|
|
] ++ [
|
|
|
|
|
(enableFeature buildAvutil "avutil")
|
|
|
|
|
(enableFeature (buildPostproc && withGPL) "postproc")
|
|
|
|
|
(enableFeature buildSwresample "swresample")
|
|
|
|
|
(enableFeature buildSwscale "swscale")
|
|
|
|
|
] ++ optionals withLib [
|
|
|
|
|
"--libdir=${placeholder "lib"}/lib"
|
|
|
|
|
"--incdir=${placeholder "dev"}/include"
|
|
|
|
|
] ++ [
|
|
|
|
|
/*
|
|
|
|
|
* Documentation flags
|
|
|
|
|
*/
|
|
|
|
|
(enableFeature withDocumentation "doc")
|
|
|
|
|
(enableFeature withHtmlDoc "htmlpages")
|
|
|
|
|
(enableFeature withManPages "manpages")
|
|
|
|
|
] ++ optionals withManPages [
|
|
|
|
|
"--mandir=${placeholder "man"}/share/man"
|
|
|
|
|
] ++ [
|
|
|
|
|
(enableFeature withPodDoc "podpages")
|
|
|
|
|
(enableFeature withTxtDoc "txtpages")
|
|
|
|
|
] ++ optionals withDoc [
|
|
|
|
|
"--docdir=${placeholder "doc"}/share/doc/ffmpeg"
|
|
|
|
|
] ++ [
|
|
|
|
|
/*
|
|
|
|
|
* External libraries
|
|
|
|
|
*/
|
|
|
|
|
(enableFeature withAlsa "alsa")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withAom "libaom")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withAppKit "appkit")
|
|
|
|
|
] ++ optionals (versionAtLeast version "6.1") [
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withAribcaption "libaribcaption")
|
|
|
|
|
] ++ [
|
|
|
|
|
(enableFeature withAss "libass")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withAudioToolbox "audiotoolbox")
|
|
|
|
|
(enableFeature withAvFoundation "avfoundation")
|
2024-05-15 15:35:15 +00:00
|
|
|
|
(enableFeature withAvisynth "avisynth")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withBluray "libbluray")
|
|
|
|
|
(enableFeature withBs2b "libbs2b")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withBzlib "bzlib")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withCaca "libcaca")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withCelt "libcelt")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withChromaprint "chromaprint")
|
2024-05-15 15:35:15 +00:00
|
|
|
|
(enableFeature withCodec2 "libcodec2")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withCoreImage "coreimage")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withCuda "cuda")
|
|
|
|
|
(enableFeature withCudaLLVM "cuda-llvm")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withCuvid "cuvid")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withDav1d "libdav1d")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withDc1394 "libdc1394")
|
|
|
|
|
(enableFeature withDrm "libdrm")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (versionAtLeast version "7") [
|
|
|
|
|
(enableFeature withDvdnav "libdvdnav")
|
|
|
|
|
(enableFeature withDvdread "libdvdread")
|
|
|
|
|
] ++ [
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withFdkAac "libfdk-aac")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withNvcodec "ffnvcodec")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withFlite "libflite")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withFontconfig "fontconfig")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withFontconfig "libfontconfig")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withFreetype "libfreetype")
|
|
|
|
|
(enableFeature withFrei0r "frei0r")
|
|
|
|
|
(enableFeature withFribidi "libfribidi")
|
|
|
|
|
(enableFeature withGme "libgme")
|
|
|
|
|
(enableFeature withGnutls "gnutls")
|
|
|
|
|
(enableFeature withGsm "libgsm")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (versionAtLeast version "6.1") [
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withHarfbuzz "libharfbuzz")
|
|
|
|
|
] ++ [
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withIconv "iconv")
|
|
|
|
|
(enableFeature withJack "libjack")
|
2024-05-15 15:35:15 +00:00
|
|
|
|
] ++ optionals (versionAtLeast finalAttrs.version "5.0") [
|
|
|
|
|
(enableFeature withJxl "libjxl")
|
|
|
|
|
] ++ [
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withLadspa "ladspa")
|
|
|
|
|
(enableFeature withLzma "lzma")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withMfx "libmfx")
|
|
|
|
|
(enableFeature withModplug "libmodplug")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withMp3lame "libmp3lame")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withMysofa "libmysofa")
|
|
|
|
|
(enableFeature withNvdec "nvdec")
|
|
|
|
|
(enableFeature withNvenc "nvenc")
|
|
|
|
|
(enableFeature withOpenal "openal")
|
|
|
|
|
(enableFeature withOpencl "opencl")
|
|
|
|
|
(enableFeature withOpencoreAmrnb "libopencore-amrnb")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
(enableFeature withOpencoreAmrwb "libopencore-amrwb")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withOpengl "opengl")
|
|
|
|
|
(enableFeature withOpenh264 "libopenh264")
|
|
|
|
|
(enableFeature withOpenjpeg "libopenjpeg")
|
|
|
|
|
(enableFeature withOpenmpt "libopenmpt")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withOpus "libopus")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (versionAtLeast version "5.0") [
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withPlacebo "libplacebo")
|
|
|
|
|
] ++ [
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withPulse "libpulse")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (versionAtLeast version "7") [
|
|
|
|
|
(enableFeature withQrencode "libqrencode")
|
|
|
|
|
(enableFeature withQuirc "libquirc")
|
|
|
|
|
] ++ [
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withRav1e "librav1e")
|
|
|
|
|
(enableFeature withRtmp "librtmp")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withSamba "libsmbclient")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withSdl2 "sdl2")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (versionAtLeast version "5.0") [
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withShaderc "libshaderc")
|
|
|
|
|
] ++ [
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withSoxr "libsoxr")
|
|
|
|
|
(enableFeature withSpeex "libspeex")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withSrt "libsrt")
|
|
|
|
|
(enableFeature withSsh "libssh")
|
|
|
|
|
(enableFeature withSvg "librsvg")
|
|
|
|
|
(enableFeature withSvtav1 "libsvtav1")
|
|
|
|
|
(enableFeature withTensorflow "libtensorflow")
|
|
|
|
|
(enableFeature withTheora "libtheora")
|
|
|
|
|
(enableFeature withV4l2 "libv4l2")
|
|
|
|
|
(enableFeature withV4l2M2m "v4l2-m2m")
|
|
|
|
|
(enableFeature withVaapi "vaapi")
|
|
|
|
|
(enableFeature withVdpau "vdpau")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (versionAtLeast version "6.0") [
|
|
|
|
|
(enableFeature withVpl "libvpl")
|
|
|
|
|
] ++ [
|
|
|
|
|
(enableFeature withVideoToolbox "videotoolbox")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withVidStab "libvidstab") # Actual min. version 2.0
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withVmaf "libvmaf")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withVoAmrwbenc "libvo-amrwbenc")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withVorbis "libvorbis")
|
|
|
|
|
(enableFeature withVpx "libvpx")
|
|
|
|
|
(enableFeature withVulkan "vulkan")
|
|
|
|
|
(enableFeature withWebp "libwebp")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withX264 "libx264")
|
|
|
|
|
(enableFeature withX265 "libx265")
|
|
|
|
|
(enableFeature withXavs "libxavs")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withXcb "libxcb")
|
|
|
|
|
(enableFeature withXcbShape "libxcb-shape")
|
|
|
|
|
(enableFeature withXcbShm "libxcb-shm")
|
|
|
|
|
(enableFeature withXcbxfixes "libxcb-xfixes")
|
2024-04-21 15:54:59 +00:00
|
|
|
|
] ++ optionals (versionAtLeast version "7") [
|
|
|
|
|
(enableFeature withXevd "libxevd")
|
|
|
|
|
(enableFeature withXeve "libxeve")
|
|
|
|
|
] ++ [
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withXlib "xlib")
|
|
|
|
|
(enableFeature withXml2 "libxml2")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
(enableFeature withXvid "libxvid")
|
|
|
|
|
(enableFeature withZimg "libzimg")
|
|
|
|
|
(enableFeature withZlib "zlib")
|
2024-02-29 20:09:43 +00:00
|
|
|
|
(enableFeature withZmq "libzmq")
|
2023-02-16 17:41:37 +00:00
|
|
|
|
/*
|
|
|
|
|
* Developer flags
|
|
|
|
|
*/
|
|
|
|
|
(enableFeature withDebug "debug")
|
|
|
|
|
(enableFeature withOptimisations "optimizations")
|
|
|
|
|
(enableFeature withExtraWarnings "extra-warnings")
|
|
|
|
|
(enableFeature withStripping "stripping")
|
2020-04-24 23:36:52 +00:00
|
|
|
|
] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
|
2023-02-16 17:41:37 +00:00
|
|
|
|
"--cross-prefix=${stdenv.cc.targetPrefix}"
|
|
|
|
|
"--enable-cross-compile"
|
|
|
|
|
"--host-cc=${buildPackages.stdenv.cc}/bin/cc"
|
|
|
|
|
] ++ optionals stdenv.cc.isClang [
|
|
|
|
|
"--cc=clang"
|
|
|
|
|
"--cxx=clang++"
|
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
# ffmpeg embeds the configureFlags verbatim in its binaries and because we
|
|
|
|
|
# configure binary, include, library dir etc., this causes references in
|
|
|
|
|
# outputs where we don't want them. Patch the generated config.h to remove all
|
|
|
|
|
# such references except for data.
|
|
|
|
|
postConfigure = let
|
2023-07-15 17:15:38 +00:00
|
|
|
|
toStrip = map placeholder (lib.remove "data" finalAttrs.outputs) # We want to keep references to the data dir.
|
|
|
|
|
++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) buildPackages.stdenv.cc;
|
2023-02-16 17:41:37 +00:00
|
|
|
|
in
|
2023-07-15 17:15:38 +00:00
|
|
|
|
"remove-references-to ${lib.concatStringsSep " " (map (o: "-t ${o}") toStrip)} config.h";
|
2023-02-16 17:41:37 +00:00
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
|
strictDeps = true;
|
|
|
|
|
|
|
|
|
|
nativeBuildInputs = [ removeReferencesTo addOpenGLRunpath perl pkg-config texinfo yasm ]
|
|
|
|
|
++ optionals withCudaLLVM [ clang ];
|
2023-02-16 17:41:37 +00:00
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
|
buildInputs = []
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withAlsa [ alsa-lib ]
|
|
|
|
|
++ optionals withAom [ libaom ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withAppKit [ AppKit ]
|
2024-01-13 08:15:51 +00:00
|
|
|
|
++ optionals withAribcaption [ libaribcaption ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withAss [ libass ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withAudioToolbox [ AudioToolbox ]
|
|
|
|
|
++ optionals withAvFoundation [ AVFoundation ]
|
2024-05-15 15:35:15 +00:00
|
|
|
|
++ optionals withAvisynth [ avisynthplus ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withBluray [ libbluray ]
|
|
|
|
|
++ optionals withBs2b [ libbs2b ]
|
|
|
|
|
++ optionals withBzlib [ bzip2 ]
|
|
|
|
|
++ optionals withCaca [ libcaca ]
|
|
|
|
|
++ optionals withCelt [ celt ]
|
2024-02-29 20:09:43 +00:00
|
|
|
|
++ optionals withChromaprint [ chromaprint ]
|
2024-05-15 15:35:15 +00:00
|
|
|
|
++ optionals withCodec2 [ codec2 ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withCoreImage [ CoreImage ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withDav1d [ dav1d ]
|
2024-02-29 20:09:43 +00:00
|
|
|
|
++ optionals withDc1394 [ libdc1394 libraw1394 ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withDrm [ libdrm ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withDvdnav [ libdvdnav ]
|
|
|
|
|
++ optionals withDvdread [ libdvdread ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withFdkAac [ fdk_aac ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withNvcodec [ (if (lib.versionAtLeast version "6") then nv-codec-headers-12 else nv-codec-headers) ]
|
2024-02-29 20:09:43 +00:00
|
|
|
|
++ optionals withFlite [ flite ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withFontconfig [ fontconfig ]
|
|
|
|
|
++ optionals withFreetype [ freetype ]
|
|
|
|
|
++ optionals withFrei0r [ frei0r ]
|
|
|
|
|
++ optionals withFribidi [ fribidi ]
|
|
|
|
|
++ optionals withGme [ game-music-emu ]
|
|
|
|
|
++ optionals withGnutls [ gnutls ]
|
|
|
|
|
++ optionals withGsm [ gsm ]
|
2024-02-29 20:09:43 +00:00
|
|
|
|
++ optionals withHarfbuzz [ harfbuzz ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withIconv [ libiconv ] # On Linux this should be in libc, do we really need it?
|
|
|
|
|
++ optionals withJack [ libjack2 ]
|
2024-05-15 15:35:15 +00:00
|
|
|
|
++ optionals withJxl [ libjxl ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withLadspa [ ladspaH ]
|
|
|
|
|
++ optionals withLzma [ xz ]
|
|
|
|
|
++ optionals withMfx [ intel-media-sdk ]
|
|
|
|
|
++ optionals withModplug [ libmodplug ]
|
|
|
|
|
++ optionals withMp3lame [ lame ]
|
|
|
|
|
++ optionals withMysofa [ libmysofa ]
|
|
|
|
|
++ optionals withOgg [ libogg ]
|
|
|
|
|
++ optionals withOpenal [ openal ]
|
|
|
|
|
++ optionals withOpencl [ ocl-icd opencl-headers ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals (withOpencoreAmrnb || withOpencoreAmrwb) [ opencore-amr ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withOpengl [ libGL libGLU ]
|
|
|
|
|
++ optionals withOpenh264 [ openh264 ]
|
|
|
|
|
++ optionals withOpenjpeg [ openjpeg ]
|
|
|
|
|
++ optionals withOpenmpt [ libopenmpt ]
|
|
|
|
|
++ optionals withOpus [ libopus ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withPlacebo [ (if (lib.versionAtLeast version "6.1") then libplacebo else libplacebo_5) vulkan-headers ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withPulse [ libpulseaudio ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withQrencode [ qrencode ]
|
|
|
|
|
++ optionals withQuirc [ quirc ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withRav1e [ rav1e ]
|
|
|
|
|
++ optionals withRtmp [ rtmpdump ]
|
|
|
|
|
++ optionals withSamba [ samba ]
|
|
|
|
|
++ optionals withSdl2 [ SDL2 ]
|
2024-01-25 14:12:00 +00:00
|
|
|
|
++ optionals withShaderc [ shaderc ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withSoxr [ soxr ]
|
|
|
|
|
++ optionals withSpeex [ speex ]
|
|
|
|
|
++ optionals withSrt [ srt ]
|
|
|
|
|
++ optionals withSsh [ libssh ]
|
|
|
|
|
++ optionals withSvg [ librsvg ]
|
|
|
|
|
++ optionals withSvtav1 [ svt-av1 ]
|
2023-05-24 13:37:59 +00:00
|
|
|
|
++ optionals withTensorflow [ libtensorflow ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withTheora [ libtheora ]
|
2024-02-29 20:09:43 +00:00
|
|
|
|
++ optionals withV4l2 [ libv4l ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withVaapi [ (if withSmallDeps then libva else libva-minimal) ]
|
|
|
|
|
++ optionals withVdpau [ libvdpau ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withVideoToolbox [ VideoToolbox ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withVidStab [ vid-stab ]
|
|
|
|
|
++ optionals withVmaf [ libvmaf ]
|
|
|
|
|
++ optionals withVoAmrwbenc [ vo-amrwbenc ]
|
|
|
|
|
++ optionals withVorbis [ libvorbis ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withVpl [ libvpl ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withVpx [ libvpx ]
|
2023-03-04 12:14:45 +00:00
|
|
|
|
++ optionals withVulkan [ vulkan-headers vulkan-loader ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withWebp [ libwebp ]
|
|
|
|
|
++ optionals withX264 [ x264 ]
|
|
|
|
|
++ optionals withX265 [ x265 ]
|
|
|
|
|
++ optionals withXavs [ xavs ]
|
|
|
|
|
++ optionals withXcb [ libxcb ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
++ optionals withXevd [ xevd ]
|
|
|
|
|
++ optionals withXeve [ xeve ]
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optionals withXlib [ libX11 libXv libXext ]
|
|
|
|
|
++ optionals withXml2 [ libxml2 ]
|
|
|
|
|
++ optionals withXvid [ xvidcore ]
|
|
|
|
|
++ optionals withZimg [ zimg ]
|
|
|
|
|
++ optionals withZlib [ zlib ]
|
|
|
|
|
++ optionals withZmq [ zeromq4 ]
|
2024-04-21 15:54:59 +00:00
|
|
|
|
;
|
2023-02-16 17:41:37 +00:00
|
|
|
|
|
|
|
|
|
buildFlags = [ "all" ]
|
|
|
|
|
++ optional buildQtFaststart "tools/qt-faststart"; # Build qt-faststart executable
|
|
|
|
|
|
|
|
|
|
doCheck = stdenv.hostPlatform == stdenv.buildPlatform;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
# Fails with SIGABRT otherwise FIXME: Why?
|
2021-09-18 10:52:07 +00:00
|
|
|
|
checkPhase = let
|
|
|
|
|
ldLibraryPathEnv = if stdenv.isDarwin then "DYLD_LIBRARY_PATH" else "LD_LIBRARY_PATH";
|
2023-02-16 17:41:37 +00:00
|
|
|
|
libsToLink = [ ]
|
|
|
|
|
++ optional buildAvcodec "libavcodec"
|
|
|
|
|
++ optional buildAvdevice "libavdevice"
|
|
|
|
|
++ optional buildAvfilter "libavfilter"
|
|
|
|
|
++ optional buildAvformat "libavformat"
|
|
|
|
|
++ optional buildAvresample "libavresample"
|
|
|
|
|
++ optional buildAvutil "libavutil"
|
|
|
|
|
++ optional buildPostproc "libpostproc"
|
|
|
|
|
++ optional buildSwresample "libswresample"
|
|
|
|
|
++ optional buildSwscale "libswscale"
|
|
|
|
|
;
|
2021-09-18 10:52:07 +00:00
|
|
|
|
in ''
|
2023-02-16 17:41:37 +00:00
|
|
|
|
${ldLibraryPathEnv}="${lib.concatStringsSep ":" libsToLink}" make check -j$NIX_BUILD_CORES
|
2021-09-18 10:52:07 +00:00
|
|
|
|
'';
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
outputs = optionals withBin [ "bin" ] # The first output is the one that gets symlinked by default!
|
|
|
|
|
++ optionals withLib [ "lib" "dev" ]
|
|
|
|
|
++ optionals withDoc [ "doc" ]
|
|
|
|
|
++ optionals withManPages [ "man" ]
|
|
|
|
|
++ [ "data" "out" ] # We need an "out" output because we get an error otherwise. It's just an empty dir.
|
|
|
|
|
;
|
|
|
|
|
|
|
|
|
|
postInstall = optionalString buildQtFaststart ''
|
|
|
|
|
install -D tools/qt-faststart -t $bin/bin
|
|
|
|
|
'';
|
|
|
|
|
|
|
|
|
|
# Set RUNPATH so that libnvcuvid and libcuda in /run/opengl-driver(-32)/lib can be found.
|
|
|
|
|
# See the explanation in addOpenGLRunpath.
|
2023-03-15 16:39:30 +00:00
|
|
|
|
postFixup = optionalString (stdenv.isLinux && withLib) ''
|
|
|
|
|
addOpenGLRunpath ${placeholder "lib"}/lib/libavcodec.so
|
|
|
|
|
addOpenGLRunpath ${placeholder "lib"}/lib/libavutil.so
|
2024-04-21 15:54:59 +00:00
|
|
|
|
''
|
|
|
|
|
# https://trac.ffmpeg.org/ticket/10809
|
|
|
|
|
+ optionalString (versionAtLeast version "5.0" && withVulkan && !stdenv.hostPlatform.isMinGW) ''
|
|
|
|
|
patchelf $lib/lib/libavcodec.so --add-needed libvulkan.so --add-rpath ${lib.makeLibraryPath [ vulkan-loader ]}
|
2020-04-24 23:36:52 +00:00
|
|
|
|
'';
|
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
enableParallelBuilding = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
|
passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
|
description = "A complete, cross-platform solution to record, convert and stream audio and video";
|
2021-05-20 23:08:51 +00:00
|
|
|
|
homepage = "https://www.ffmpeg.org/";
|
2024-04-21 15:54:59 +00:00
|
|
|
|
changelog = "https://github.com/FFmpeg/FFmpeg/blob/n${version}/Changelog";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
longDescription = ''
|
|
|
|
|
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.
|
|
|
|
|
'';
|
2023-02-16 17:41:37 +00:00
|
|
|
|
license = with licenses; [ lgpl21Plus ]
|
|
|
|
|
++ optional withGPL gpl2Plus
|
2024-02-29 20:09:43 +00:00
|
|
|
|
++ optional withVersion3 lgpl3Plus
|
2023-02-16 17:41:37 +00:00
|
|
|
|
++ optional withGPLv3 gpl3Plus
|
2024-02-29 20:09:43 +00:00
|
|
|
|
++ optional withUnfree unfreeRedistributable
|
|
|
|
|
++ optional (withGPL && withUnfree) unfree;
|
2024-04-21 15:54:59 +00:00
|
|
|
|
pkgConfigModules = [ ]
|
|
|
|
|
++ optional buildAvcodec "libavcodec"
|
|
|
|
|
++ optional buildAvdevice "libavdevice"
|
|
|
|
|
++ optional buildAvfilter "libavfilter"
|
|
|
|
|
++ optional buildAvformat "libavformat"
|
|
|
|
|
++ optional buildAvresample "libavresample"
|
|
|
|
|
++ optional buildAvutil "libavutil"
|
|
|
|
|
++ optional buildPostproc "libpostproc"
|
|
|
|
|
++ optional buildSwresample "libswresample"
|
|
|
|
|
++ optional buildSwscale "libswscale";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
platforms = platforms.all;
|
2024-04-21 15:54:59 +00:00
|
|
|
|
# See https://github.com/NixOS/nixpkgs/pull/295344#issuecomment-1992263658
|
|
|
|
|
broken = stdenv.hostPlatform.isMinGW && stdenv.hostPlatform.is64bit;
|
2024-02-29 20:09:43 +00:00
|
|
|
|
maintainers = with maintainers; [ atemu arthsmn jopejoe1 ];
|
2023-10-09 19:29:22 +00:00
|
|
|
|
mainProgram = "ffmpeg";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
};
|
2023-02-16 17:41:37 +00:00
|
|
|
|
})
|