summaryrefslogtreecommitdiff
path: root/pkg/ffmpeg/patch
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2023-03-02 16:43:55 -0800
committerMichael Forney <mforney@mforney.org>2023-03-02 17:35:38 -0800
commit743341f40628814bdef949564e2cadbb94f9c09b (patch)
tree5c40bc11c2c21c3e69607062e8b885f4473d20cd /pkg/ffmpeg/patch
parent7575539f5cdfa3caa420e1b96a5c3d35387657be (diff)
ffmpeg: Update to 5.1.1
Diffstat (limited to 'pkg/ffmpeg/patch')
-rw-r--r--pkg/ffmpeg/patch/0001-libavformat-tls_libtls-handle-TLS_WANT_POLLIN-and-TL.patch43
-rw-r--r--pkg/ffmpeg/patch/0001-libavutil-Remove-last-use-of-long-double.patch (renamed from pkg/ffmpeg/patch/0002-libavutil-Remove-last-use-of-long-double.patch)0
-rw-r--r--pkg/ffmpeg/patch/0002-libavcodec-Prevent-stray-semicolon-at-top-level.patch (renamed from pkg/ffmpeg/patch/0003-libavcodec-Prevent-stray-semicolon-at-top-level.patch)16
-rw-r--r--pkg/ffmpeg/patch/0003-libavformat-Use-C99-__func__-instead-of-non-standard.patch26
-rw-r--r--pkg/ffmpeg/patch/0004-libavcodec-Use-if-to-prevent-some-unintended-depende.patch (renamed from pkg/ffmpeg/patch/0005-libavcodec-Use-if-to-prevent-some-unintended-depende.patch)30
-rw-r--r--pkg/ffmpeg/patch/0004-libavformat-Use-C99-__func__-instead-of-non-standard.patch58
-rw-r--r--pkg/ffmpeg/patch/0005-libavutil-Use-config-instead-of-compiler-to-determin.patch (renamed from pkg/ffmpeg/patch/0006-libavutil-Use-config-instead-of-compiler-to-determin.patch)0
-rw-r--r--pkg/ffmpeg/patch/0006-libavutil-Use-C11-_Alignas-as-fallback-for-DECLARE_A.patch (renamed from pkg/ffmpeg/patch/0007-libavutil-Use-C11-_Alignas-as-fallback-for-DECLARE_A.patch)8
-rw-r--r--pkg/ffmpeg/patch/0007-HACK-Disable-__has_builtin-for-now.patch (renamed from pkg/ffmpeg/patch/0008-HACK-Disable-__has_builtin-for-now.patch)0
9 files changed, 43 insertions, 138 deletions
diff --git a/pkg/ffmpeg/patch/0001-libavformat-tls_libtls-handle-TLS_WANT_POLLIN-and-TL.patch b/pkg/ffmpeg/patch/0001-libavformat-tls_libtls-handle-TLS_WANT_POLLIN-and-TL.patch
deleted file mode 100644
index 7b2c0195..00000000
--- a/pkg/ffmpeg/patch/0001-libavformat-tls_libtls-handle-TLS_WANT_POLLIN-and-TL.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 42236d444f98f18eb49824a391c8dacdb4d60e2c Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Mon, 9 Dec 2019 16:36:57 -0800
-Subject: [PATCH] libavformat/tls_libtls: handle TLS_WANT_POLLIN and
- TLS_WANT_POLLOUT return values
-
-These values may be returned by libtls (even in the case of blocking
-file descriptors) when we need to read/write more TLS record data in
-order to read/write application data.
-
-The URLProtocol documentation says AVERROR(EAGAIN) should be returned
-in these cases.
-
-Signed-off-by: Michael Forney <mforney@mforney.org>
----
- libavformat/tls_libtls.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/libavformat/tls_libtls.c b/libavformat/tls_libtls.c
-index dff7f2d9fb..10609fb7eb 100644
---- a/libavformat/tls_libtls.c
-+++ b/libavformat/tls_libtls.c
-@@ -158,6 +158,8 @@ static int ff_tls_read(URLContext *h, uint8_t *buf, int size)
- return ret;
- else if (ret == 0)
- return AVERROR_EOF;
-+ else if (ret == TLS_WANT_POLLIN || ret == TLS_WANT_POLLOUT)
-+ return AVERROR(EAGAIN);
- av_log(h, AV_LOG_ERROR, "%s\n", tls_error(p->ctx));
- return AVERROR(EIO);
- }
-@@ -171,6 +173,8 @@ static int ff_tls_write(URLContext *h, const uint8_t *buf, int size)
- return ret;
- else if (ret == 0)
- return AVERROR_EOF;
-+ else if (ret == TLS_WANT_POLLIN || ret == TLS_WANT_POLLOUT)
-+ return AVERROR(EAGAIN);
- av_log(h, AV_LOG_ERROR, "%s\n", tls_error(p->ctx));
- return AVERROR(EIO);
- }
---
-2.27.0
-
diff --git a/pkg/ffmpeg/patch/0002-libavutil-Remove-last-use-of-long-double.patch b/pkg/ffmpeg/patch/0001-libavutil-Remove-last-use-of-long-double.patch
index a95e27a7..a95e27a7 100644
--- a/pkg/ffmpeg/patch/0002-libavutil-Remove-last-use-of-long-double.patch
+++ b/pkg/ffmpeg/patch/0001-libavutil-Remove-last-use-of-long-double.patch
diff --git a/pkg/ffmpeg/patch/0003-libavcodec-Prevent-stray-semicolon-at-top-level.patch b/pkg/ffmpeg/patch/0002-libavcodec-Prevent-stray-semicolon-at-top-level.patch
index 7df61ecd..b46c0688 100644
--- a/pkg/ffmpeg/patch/0003-libavcodec-Prevent-stray-semicolon-at-top-level.patch
+++ b/pkg/ffmpeg/patch/0002-libavcodec-Prevent-stray-semicolon-at-top-level.patch
@@ -1,4 +1,4 @@
-From 0f75976c934056c63100b9c13abbf8ac3caa1007 Mon Sep 17 00:00:00 2001
+From d117054cbf83a3ad3a0385c37a5dbbf75a10b5f5 Mon Sep 17 00:00:00 2001
From: Michael Forney <mforney@mforney.org>
Date: Tue, 7 Sep 2021 01:41:48 -0700
Subject: [PATCH] libavcodec: Prevent stray semicolon at top-level
@@ -13,11 +13,11 @@ is no problem if it expands to an empty token sequence.
1 file changed, 36 insertions(+), 36 deletions(-)
diff --git a/libavcodec/pcm.c b/libavcodec/pcm.c
-index 19d04e9181..3ab2d4555c 100644
+index 471075ad71..c7bb50e061 100644
--- a/libavcodec/pcm.c
+++ b/libavcodec/pcm.c
-@@ -561,7 +561,7 @@ AVCodec ff_ ## name_ ## _encoder = { \
- .sample_fmts = (const enum AVSampleFormat[]){ sample_fmt_, \
+@@ -565,7 +565,7 @@ const FFCodec ff_ ## name_ ## _encoder = { \
+ .p.sample_fmts = (const enum AVSampleFormat[]){ sample_fmt_, \
AV_SAMPLE_FMT_NONE }, \
.caps_internal = FF_CODEC_CAP_INIT_THREADSAFE, \
-}
@@ -25,8 +25,8 @@ index 19d04e9181..3ab2d4555c 100644
#define PCM_ENCODER_2(cf, id, sample_fmt, name, long_name) \
PCM_ENCODER_ ## cf(id, sample_fmt, name, long_name)
-@@ -584,7 +584,7 @@ AVCodec ff_ ## name_ ## _decoder = { \
- .sample_fmts = (const enum AVSampleFormat[]){ sample_fmt_, \
+@@ -588,7 +588,7 @@ const FFCodec ff_ ## name_ ## _decoder = { \
+ .p.sample_fmts = (const enum AVSampleFormat[]){ sample_fmt_, \
AV_SAMPLE_FMT_NONE }, \
.caps_internal = FF_CODEC_CAP_INIT_THREADSAFE, \
-}
@@ -34,7 +34,7 @@ index 19d04e9181..3ab2d4555c 100644
#define PCM_DECODER_2(cf, id, sample_fmt, name, long_name) \
PCM_DECODER_ ## cf(id, sample_fmt, name, long_name)
-@@ -594,40 +594,40 @@ AVCodec ff_ ## name_ ## _decoder = { \
+@@ -598,40 +598,40 @@ const FFCodec ff_ ## name_ ## _decoder = { \
PCM_DECODER_3(CONFIG_ ## id ## _DECODER, id, sample_fmt, name, long_name)
#define PCM_CODEC(id, sample_fmt_, name, long_name_) \
@@ -110,5 +110,5 @@ index 19d04e9181..3ab2d4555c 100644
+PCM_CODEC (PCM_VIDC, AV_SAMPLE_FMT_S16, pcm_vidc, "PCM Archimedes VIDC")
+PCM_DECODER(PCM_SGA, AV_SAMPLE_FMT_U8, pcm_sga, "PCM SGA")
--
-2.32.0
+2.37.3
diff --git a/pkg/ffmpeg/patch/0003-libavformat-Use-C99-__func__-instead-of-non-standard.patch b/pkg/ffmpeg/patch/0003-libavformat-Use-C99-__func__-instead-of-non-standard.patch
new file mode 100644
index 00000000..24c05c32
--- /dev/null
+++ b/pkg/ffmpeg/patch/0003-libavformat-Use-C99-__func__-instead-of-non-standard.patch
@@ -0,0 +1,26 @@
+From d0cf1c91f842993121bc24874153f5959dbd95f3 Mon Sep 17 00:00:00 2001
+From: Michael Forney <mforney@mforney.org>
+Date: Tue, 7 Sep 2021 01:43:25 -0700
+Subject: [PATCH] libavformat: Use C99 __func__ instead of non-standard
+ __FUNCTION__
+
+---
+ libavformat/mux.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libavformat/mux.c b/libavformat/mux.c
+index 31361f9b46..8dcf4047dc 100644
+--- a/libavformat/mux.c
++++ b/libavformat/mux.c
+@@ -1108,7 +1108,7 @@ static int write_packet_common(AVFormatContext *s, AVStream *st, AVPacket *pkt,
+ int ret;
+
+ if (s->debug & FF_FDEBUG_TS)
+- av_log(s, AV_LOG_DEBUG, "%s size:%d dts:%s pts:%s\n", __FUNCTION__,
++ av_log(s, AV_LOG_DEBUG, "%s size:%d dts:%s pts:%s\n", __func__,
+ pkt->size, av_ts2str(pkt->dts), av_ts2str(pkt->pts));
+
+ guess_pkt_duration(s, st, pkt);
+--
+2.37.3
+
diff --git a/pkg/ffmpeg/patch/0005-libavcodec-Use-if-to-prevent-some-unintended-depende.patch b/pkg/ffmpeg/patch/0004-libavcodec-Use-if-to-prevent-some-unintended-depende.patch
index 6b0df062..6cad7e43 100644
--- a/pkg/ffmpeg/patch/0005-libavcodec-Use-if-to-prevent-some-unintended-depende.patch
+++ b/pkg/ffmpeg/patch/0004-libavcodec-Use-if-to-prevent-some-unintended-depende.patch
@@ -1,37 +1,17 @@
-From 71b3efc1e55297cbe079378c1e0127c78fe264f5 Mon Sep 17 00:00:00 2001
+From a7dd6d3b3467b46ff767d68b488fd17a32b54c7f Mon Sep 17 00:00:00 2001
From: Michael Forney <mforney@mforney.org>
Date: Tue, 7 Sep 2021 01:44:53 -0700
Subject: [PATCH] libavcodec: Use #if to prevent some unintended dependencies
---
- libavcodec/h263.h | 2 ++
libavcodec/mpegvideo_motion.c | 10 ++++++----
- 2 files changed, 8 insertions(+), 4 deletions(-)
+ 1 file changed, 6 insertions(+), 4 deletions(-)
-diff --git a/libavcodec/h263.h b/libavcodec/h263.h
-index 491f2e0aac..6f4088e57c 100644
---- a/libavcodec/h263.h
-+++ b/libavcodec/h263.h
-@@ -99,6 +99,7 @@ int ff_h263_resync(MpegEncContext *s);
- void ff_h263_encode_motion(PutBitContext *pb, int val, int f_code);
-
-
-+#if CONFIG_H263_ENCODER
- static inline int h263_get_motion_length(int val, int f_code){
- int l, bit_size, code;
-
-@@ -183,5 +184,6 @@ static inline int get_p_cbp(MpegEncContext * s,
- }
- return cbp;
- }
-+#endif
-
- #endif /* AVCODEC_H263_H */
diff --git a/libavcodec/mpegvideo_motion.c b/libavcodec/mpegvideo_motion.c
-index 427bc96887..081c251d11 100644
+index 9a450b7c8e..cc920c6067 100644
--- a/libavcodec/mpegvideo_motion.c
+++ b/libavcodec/mpegvideo_motion.c
-@@ -359,10 +359,11 @@ void mpeg_motion_internal(MpegEncContext *s,
+@@ -361,10 +361,11 @@ void mpeg_motion_internal(MpegEncContext *s,
pix_op[s->chroma_x_shift][uvdxy]
(dest_cr, ptr_cr, uvlinesize, h >> s->chroma_y_shift);
}
@@ -61,5 +41,5 @@ index 427bc96887..081c251d11 100644
mpeg_motion(s, dest_y, dest_cb, dest_cr, 0,
ref_picture, pix_op,
--
-2.32.0
+2.37.3
diff --git a/pkg/ffmpeg/patch/0004-libavformat-Use-C99-__func__-instead-of-non-standard.patch b/pkg/ffmpeg/patch/0004-libavformat-Use-C99-__func__-instead-of-non-standard.patch
deleted file mode 100644
index e64ffe75..00000000
--- a/pkg/ffmpeg/patch/0004-libavformat-Use-C99-__func__-instead-of-non-standard.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 178c29e21ade1ced553d153a9bcab716abed3362 Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Tue, 7 Sep 2021 01:43:25 -0700
-Subject: [PATCH] libavformat: Use C99 __func__ instead of non-standard
- __FUNCTION__
-
----
- libavformat/mux.c | 2 +-
- libavformat/utils.c | 6 +++---
- 2 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/libavformat/mux.c b/libavformat/mux.c
-index 6a557d294e..23eda49eb6 100644
---- a/libavformat/mux.c
-+++ b/libavformat/mux.c
-@@ -1135,7 +1135,7 @@ static int write_packet_common(AVFormatContext *s, AVStream *st, AVPacket *pkt,
- int ret;
-
- if (s->debug & FF_FDEBUG_TS)
-- av_log(s, AV_LOG_DEBUG, "%s size:%d dts:%s pts:%s\n", __FUNCTION__,
-+ av_log(s, AV_LOG_DEBUG, "%s size:%d dts:%s pts:%s\n", __func__,
- pkt->size, av_ts2str(pkt->dts), av_ts2str(pkt->pts));
-
- guess_pkt_duration(s, st, pkt);
-diff --git a/libavformat/utils.c b/libavformat/utils.c
-index 75e5350a27..5480a87620 100644
---- a/libavformat/utils.c
-+++ b/libavformat/utils.c
-@@ -3704,7 +3704,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
- && codec && !avctx->codec) {
- if (avcodec_open2(avctx, codec, options ? &options[i] : &thread_opt) < 0)
- av_log(ic, AV_LOG_WARNING,
-- "Failed to open codec in %s\n",__FUNCTION__);
-+ "Failed to open codec in %s\n", __func__);
- }
-
- // Try to just open decoders, in case this is enough to get parameters.
-@@ -3712,7 +3712,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
- if (codec && !avctx->codec)
- if (avcodec_open2(avctx, codec, options ? &options[i] : &thread_opt) < 0)
- av_log(ic, AV_LOG_WARNING,
-- "Failed to open codec in %s\n",__FUNCTION__);
-+ "Failed to open codec in %s\n", __func__);
- }
- if (!options)
- av_dict_free(&thread_opt);
-@@ -3969,7 +3969,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
- av_dict_set(&opts, "codec_whitelist", ic->codec_whitelist, 0);
- if (avcodec_open2(avctx, codec, (options && stream_index < orig_nb_streams) ? &options[stream_index] : &opts) < 0)
- av_log(ic, AV_LOG_WARNING,
-- "Failed to open codec in %s\n",__FUNCTION__);
-+ "Failed to open codec in %s\n", __func__);
- av_dict_free(&opts);
- }
- }
---
-2.32.0
-
diff --git a/pkg/ffmpeg/patch/0006-libavutil-Use-config-instead-of-compiler-to-determin.patch b/pkg/ffmpeg/patch/0005-libavutil-Use-config-instead-of-compiler-to-determin.patch
index 23c79c21..23c79c21 100644
--- a/pkg/ffmpeg/patch/0006-libavutil-Use-config-instead-of-compiler-to-determin.patch
+++ b/pkg/ffmpeg/patch/0005-libavutil-Use-config-instead-of-compiler-to-determin.patch
diff --git a/pkg/ffmpeg/patch/0007-libavutil-Use-C11-_Alignas-as-fallback-for-DECLARE_A.patch b/pkg/ffmpeg/patch/0006-libavutil-Use-C11-_Alignas-as-fallback-for-DECLARE_A.patch
index 77930f03..7c4efc75 100644
--- a/pkg/ffmpeg/patch/0007-libavutil-Use-C11-_Alignas-as-fallback-for-DECLARE_A.patch
+++ b/pkg/ffmpeg/patch/0006-libavutil-Use-C11-_Alignas-as-fallback-for-DECLARE_A.patch
@@ -1,4 +1,4 @@
-From 998e73fa83da20afd47263fce2e50876c799ee41 Mon Sep 17 00:00:00 2001
+From be0fa40e9d56ff85c3329ce7452bf33215fbd678 Mon Sep 17 00:00:00 2001
From: Michael Forney <mforney@mforney.org>
Date: Mon, 25 Oct 2021 17:08:29 -0700
Subject: [PATCH] libavutil: Use C11 _Alignas as fallback for DECLARE_ALIGNED
@@ -8,10 +8,10 @@ Subject: [PATCH] libavutil: Use C11 _Alignas as fallback for DECLARE_ALIGNED
1 file changed, 4 insertions(+)
diff --git a/libavutil/mem.h b/libavutil/mem.h
-index e21a1feaae..aeaacd9d55 100644
+index d91174196c..996e9b14b0 100644
--- a/libavutil/mem.h
+++ b/libavutil/mem.h
-@@ -121,6 +121,10 @@
+@@ -120,6 +120,10 @@
#define DECLARE_ALIGNED(n,t,v) __declspec(align(n)) t v
#define DECLARE_ASM_ALIGNED(n,t,v) __declspec(align(n)) t v
#define DECLARE_ASM_CONST(n,t,v) __declspec(align(n)) static const t v
@@ -23,5 +23,5 @@ index e21a1feaae..aeaacd9d55 100644
#define DECLARE_ALIGNED(n,t,v) t v
#define DECLARE_ASM_ALIGNED(n,t,v) t v
--
-2.32.0
+2.37.3
diff --git a/pkg/ffmpeg/patch/0008-HACK-Disable-__has_builtin-for-now.patch b/pkg/ffmpeg/patch/0007-HACK-Disable-__has_builtin-for-now.patch
index 4a2f042e..4a2f042e 100644
--- a/pkg/ffmpeg/patch/0008-HACK-Disable-__has_builtin-for-now.patch
+++ b/pkg/ffmpeg/patch/0007-HACK-Disable-__has_builtin-for-now.patch