diff mbox series

[FFmpeg-devel,07/32] tests/Makefile: Make DEMDEC etc. auxiliary functions more flexible

Message ID AS8PR01MB79441457C5C6329C563E7D098FF99@AS8PR01MB7944.eurprd01.prod.exchangelabs.com
State Accepted
Commit 1171eab1371a13b34ab1e2ed5d65617fbc76df10
Headers show
Series [FFmpeg-devel,01/32] fate/matroska: Use REMUX and TRANSCODE where appropriate | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Andreas Rheinhardt April 24, 2022, 3:33 a.m. UTC
Add a parameter that allows to add additional requirements.
Also add FILE_PROTOCOL to all the auxiliary functions
that use a demuxer.

Also fix the requirements for the fate-mpegts-probe-(latm|program)
tests. They have misused DEMDEC.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 tests/Makefile        | 20 +++++++++++---------
 tests/fate/mpegts.mak |  4 ++--
 2 files changed, 13 insertions(+), 11 deletions(-)
diff mbox series

Patch

diff --git a/tests/Makefile b/tests/Makefile
index 5e4da2c42f..e175631258 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -68,11 +68,13 @@  XYES    = $(if $(strip $(1)),                                           \
                yes)
 
 ENCDEC  = $(call ALLYES, $(firstword $(1))_ENCODER $(lastword $(1))_DECODER  \
-                         $(firstword $(2))_MUXER   $(lastword $(2))_DEMUXER)
+                         $(firstword $(2))_MUXER   $(lastword $(2))_DEMUXER  \
+                         $(3) FILE_PROTOCOL)
 
 ENCDEC2 = $(call ALLYES, $(firstword $(1))_ENCODER $(lastword $(1))_DECODER  \
                          $(firstword $(2))_ENCODER $(lastword $(2))_DECODER  \
-                         $(firstword $(3))_MUXER   $(lastword $(3))_DEMUXER)
+                         $(firstword $(3))_MUXER   $(lastword $(3))_DEMUXER  \
+                         $(4) FILE_PROTOCOL)
 
 # RAWVIDEO_ENCODER and PCM_S16LE_ENCODER corresponds to the default codecs
 # for framecrc. These requirements are not always necessary.
@@ -84,16 +86,16 @@  TRANSCODE = $(call ALLYES, $(firstword $(1))_ENCODER $(lastword $(1))_DECODER \
 REMUX = $(call ALLYES, $(firstword $(1))_MUXER $(lastword $(1))_DEMUXER \
                        $(2) FILE_PROTOCOL PIPE_PROTOCOL FRAMECRC_MUXER)
 
-DEMDEC  = $(call ALLYES, $(1)_DEMUXER $(2:%=%_DECODER))
-ENCMUX  = $(call ALLYES, $(1:%=%_ENCODER) $(2)_MUXER)
+DEMDEC  = $(call ALLYES, $(1)_DEMUXER $(2:%=%_DECODER) $(3) FILE_PROTOCOL)
+ENCMUX  = $(call ALLYES, $(1:%=%_ENCODER) $(2)_MUXER   $(3))
 
-DEMMUX  = $(call ALLYES, $(1)_DEMUXER $(2)_MUXER)
+DEMMUX  = $(call ALLYES, $(1)_DEMUXER $(2)_MUXER $(3) FILE_PROTOCOL)
 
-FILTERDEMDEC       = $(call ALLYES, $(1:%=%_FILTER) $(2)_DEMUXER $(3)_DECODER)
-FILTERDEMDECMUX    = $(call ALLYES, $(1:%=%_FILTER) $(2)_DEMUXER $(3)_DECODER $(4)_MUXER)
-FILTERDEMDECENCMUX = $(call ALLYES, $(1:%=%_FILTER) $(2)_DEMUXER $(3)_DECODER $(4)_ENCODER $(5)_MUXER)
+FILTERDEMDEC       = $(call ALLYES, $(1:%=%_FILTER) $(2)_DEMUXER $(3)_DECODER $(4) FILE_PROTOCOL)
+FILTERDEMDECMUX    = $(call ALLYES, $(1:%=%_FILTER) $(2)_DEMUXER $(3)_DECODER $(4)_MUXER   $(5) FILE_PROTOCOL)
+FILTERDEMDECENCMUX = $(call ALLYES, $(1:%=%_FILTER) $(2)_DEMUXER $(3)_DECODER $(4)_ENCODER $(5)_MUXER $(6) FILE_PROTOCOL)
 
-PARSERDEMDEC       = $(call ALLYES, $(1)_PARSER $(2)_DEMUXER $(3)_DECODER)
+PARSERDEMDEC       = $(call ALLYES, $(1)_PARSER $(2)_DEMUXER $(3)_DECODER $(4) FILE_PROTOCOL)
 
 # Allow overriding CONFIG_LARGE_TESTS via LARGE_TESTS, if set on the
 # make command line.
diff --git a/tests/fate/mpegts.mak b/tests/fate/mpegts.mak
index bbcbfc47b2..eaca8ec289 100644
--- a/tests/fate/mpegts.mak
+++ b/tests/fate/mpegts.mak
@@ -5,12 +5,12 @@  PROBE_CODEC_NAME_COMMAND = \
     ffprobe$(PROGSSUF)$(EXESUF) -show_entries stream=codec_name \
     -print_format default -bitexact -v 0
 
-FATE_MPEGTS_PROBE-$(call DEMDEC, MPEGTS, HEVC, AAC_LATM) += fate-mpegts-probe-latm
+FATE_MPEGTS_PROBE-$(call DEMDEC, MPEGTS, HEVC, LOAS_DEMUXER) += fate-mpegts-probe-latm
 fate-mpegts-probe-latm: SRC = $(TARGET_SAMPLES)/mpegts/loewe.ts
 fate-mpegts-probe-latm: CMD = run $(PROBE_CODEC_NAME_COMMAND) -i "$(SRC)"
 
 
-FATE_MPEGTS_PROBE-$(call DEMDEC, MPEGTS, HEVC, AAC_LATM) += fate-mpegts-probe-program
+FATE_MPEGTS_PROBE-$(call DEMDEC, MPEGTS, HEVC, LOAS_DEMUXER) += fate-mpegts-probe-program
 fate-mpegts-probe-program: SRC = $(TARGET_SAMPLES)/mpegts/loewe.ts
 fate-mpegts-probe-program: CMD = run $(PROBE_CODEC_NAME_COMMAND) -select_streams p:769:v:0 -i "$(SRC)"