fate: dependencies for demux tests
[ffmpeg.git] / tests / Makefile
1 VREF = tests/vsynth1/00.pgm
2 AREF = tests/data/asynth1.sw
3
4 OBJDIRS += tests/data tests/vsynth1
5
6 tests/vsynth1/00.pgm: tests/videogen$(HOSTEXESUF) | tests/vsynth1
7         $(M)./$< 'tests/vsynth1/'
8
9 tests/data/asynth1.sw: tests/audiogen$(HOSTEXESUF) | tests/data
10         $(M)./$< $@
11
12 tests/data/asynth-%.wav: tests/audiogen$(HOSTEXESUF) | tests/data
13         $(M)./$< $@ $(subst -, ,$*)
14
15 tests/data/vsynth1.yuv: tests/videogen$(HOSTEXESUF) | tests/data
16         $(M)$< $@
17
18 tests/data/vsynth2.yuv: tests/rotozoom$(HOSTEXESUF) | tests/data
19         $(M)$< $(SRC_PATH)/tests/lena.pnm $@
20
21 tests/data/asynth% tests/data/vsynth%.yuv tests/vsynth%/00.pgm: TAG = GEN
22
23 ALLYES  = $(strip $(call XYES, $(1)))
24 XYES    = $(if $(strip $(1)),                                           \
25                $(if $(CONFIG_$(firstword $(1))),                        \
26                     $(call XYES, $(wordlist 2, $(words $(1)), $(1)))),  \
27                yes)
28
29 ENCDEC  = $(call ALLYES, $(firstword $(1))_ENCODER $(lastword $(1))_DECODER  \
30                          $(firstword $(2))_MUXER   $(lastword $(2))_DEMUXER)
31
32 ENCDEC2 = $(call ALLYES, $(firstword $(1))_ENCODER $(lastword $(1))_DECODER  \
33                          $(firstword $(2))_ENCODER $(lastword $(2))_DECODER  \
34                          $(firstword $(3))_MUXER   $(lastword $(3))_DEMUXER)
35
36 DEMDEC  = $(call ALLYES, $(1)_DEMUXER $(2:%=%_DECODER))
37
38 include $(SRC_PATH)/tests/fate/acodec.mak
39 include $(SRC_PATH)/tests/fate/vcodec.mak
40 include $(SRC_PATH)/tests/fate/avformat.mak
41 include $(SRC_PATH)/tests/fate/avfilter.mak
42 include $(SRC_PATH)/tests/fate/seek.mak
43
44 include $(SRC_PATH)/tests/fate/aac.mak
45 include $(SRC_PATH)/tests/fate/ac3.mak
46 include $(SRC_PATH)/tests/fate/adpcm.mak
47 include $(SRC_PATH)/tests/fate/alac.mak
48 include $(SRC_PATH)/tests/fate/als.mak
49 include $(SRC_PATH)/tests/fate/amrnb.mak
50 include $(SRC_PATH)/tests/fate/amrwb.mak
51 include $(SRC_PATH)/tests/fate/atrac.mak
52 include $(SRC_PATH)/tests/fate/audio.mak
53 include $(SRC_PATH)/tests/fate/bmp.mak
54 include $(SRC_PATH)/tests/fate/cdxl.mak
55 include $(SRC_PATH)/tests/fate/cover-art.mak
56 include $(SRC_PATH)/tests/fate/dct.mak
57 include $(SRC_PATH)/tests/fate/demux.mak
58 include $(SRC_PATH)/tests/fate/dfa.mak
59 include $(SRC_PATH)/tests/fate/dpcm.mak
60 include $(SRC_PATH)/tests/fate/ea.mak
61 include $(SRC_PATH)/tests/fate/filter.mak
62 include $(SRC_PATH)/tests/fate/flac.mak
63 include $(SRC_PATH)/tests/fate/fft.mak
64 include $(SRC_PATH)/tests/fate/h264.mak
65 include $(SRC_PATH)/tests/fate/image.mak
66 include $(SRC_PATH)/tests/fate/indeo.mak
67 include $(SRC_PATH)/tests/fate/libavcodec.mak
68 include $(SRC_PATH)/tests/fate/libavformat.mak
69 include $(SRC_PATH)/tests/fate/libavutil.mak
70 include $(SRC_PATH)/tests/fate/lossless-audio.mak
71 include $(SRC_PATH)/tests/fate/lossless-video.mak
72 include $(SRC_PATH)/tests/fate/microsoft.mak
73 include $(SRC_PATH)/tests/fate/mp3.mak
74 include $(SRC_PATH)/tests/fate/mpc.mak
75 include $(SRC_PATH)/tests/fate/pcm.mak
76 include $(SRC_PATH)/tests/fate/probe.mak
77 include $(SRC_PATH)/tests/fate/prores.mak
78 include $(SRC_PATH)/tests/fate/qt.mak
79 include $(SRC_PATH)/tests/fate/qtrle.mak
80 include $(SRC_PATH)/tests/fate/real.mak
81 include $(SRC_PATH)/tests/fate/screen.mak
82 include $(SRC_PATH)/tests/fate/utvideo.mak
83 include $(SRC_PATH)/tests/fate/video.mak
84 include $(SRC_PATH)/tests/fate/voice.mak
85 include $(SRC_PATH)/tests/fate/vorbis.mak
86 include $(SRC_PATH)/tests/fate/vpx.mak
87 include $(SRC_PATH)/tests/fate/vqf.mak
88 include $(SRC_PATH)/tests/fate/wavpack.mak
89 include $(SRC_PATH)/tests/fate/wma.mak
90
91 FATE_AVCONV += $(FATE_AVCONV-yes)
92 FATE-$(CONFIG_AVCONV) += $(FATE_AVCONV)
93
94 FATE-$(CONFIG_AVCODEC)  += $(FATE_LIBAVCODEC)
95 FATE-$(CONFIG_AVFORMAT) += $(FATE_LIBAVFORMAT)
96
97 FATE_SAMPLES_AVCONV           += $(FATE_SAMPLES_AVCONV-yes)
98 FATE_SAMPLES-$(CONFIG_AVCONV) += $(FATE_SAMPLES_AVCONV)
99 FATE_SAMPLES += $(FATE_SAMPLES-yes)
100
101 FATE += $(FATE-yes)
102 FATE += $(FATE_LIBAVUTIL)
103
104 $(FATE_AVCONV) $(FATE_SAMPLES_AVCONV): avconv$(EXESUF)
105
106 ifdef SAMPLES
107 FATE += $(FATE_SAMPLES)
108 fate-rsync:
109         rsync -vaLW rsync://fate-suite.libav.org/fate-suite/ $(SAMPLES)
110 else
111 fate-rsync:
112         @echo "use 'make fate-rsync SAMPLES=/path/to/samples' to sync the fate suite"
113 $(FATE_SAMPLES):
114         @echo "$@ requires external samples and SAMPLES not specified"; false
115 endif
116
117 FATE_UTILS = base64 tiny_psnr
118
119 fate: $(FATE)
120
121 $(FATE): $(FATE_UTILS:%=tests/%$(HOSTEXESUF))
122         @echo "TEST    $(@:fate-%=%)"
123         $(Q)$(SRC_PATH)/tests/fate-run.sh $@ "$(SAMPLES)" "$(TARGET_EXEC)" "$(TARGET_PATH)" '$(CMD)' '$(CMP)' '$(REF)' '$(FUZZ)' '$(THREADS)' '$(THREAD_TYPE)' '$(CPUFLAGS)' '$(CMP_SHIFT)' '$(CMP_TARGET)' '$(SIZE_TOLERANCE)' '$(CMP_UNIT)'
124
125 fate-list:
126         @printf '%s\n' $(sort $(FATE))
127
128 clean:: testclean
129
130 testclean:
131         $(RM) -r tests/vsynth1 tests/data
132         $(RM) $(CLEANSUFFIXES:%=tests/%)
133         $(RM) $(TESTTOOLS:%=tests/%$(HOSTEXESUF))
134
135 -include $(wildcard tests/*.d)
136
137 .PHONY: fate*