From 90153465b04bf4175b8e85587d90b3b3e5399020 Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Wed, 28 Nov 2012 17:06:04 +0100 Subject: fate: Add dependencies for bmp, cdxl, dfa, mp3 --- tests/fate/bmp.mak | 6 ++++-- tests/fate/cdxl.mak | 6 ++++-- tests/fate/dfa.mak | 6 ++++-- tests/fate/mp3.mak | 7 +++++-- 4 files changed, 17 insertions(+), 8 deletions(-) diff --git a/tests/fate/bmp.mak b/tests/fate/bmp.mak index c6601902f5..9e52ac081f 100644 --- a/tests/fate/bmp.mak +++ b/tests/fate/bmp.mak @@ -37,5 +37,7 @@ fate-bmp-rle4: CMD = framecrc -i $(SAMPLES)/bmp/testcompress4.bmp -pix_fmt rgb24 FATE_BMP += fate-bmp-rle8 fate-bmp-rle8: CMD = framecrc -i $(SAMPLES)/bmp/testcompress8.bmp -pix_fmt rgb24 -FATE_SAMPLES_AVCONV += $(FATE_BMP) -fate-bmp: $(FATE_BMP) +FATE_BMP-$(call DEMDEC, IMAGE2, BMP) += $(FATE_BMP) + +FATE_SAMPLES_AVCONV += $(FATE_BMP-yes) +fate-bmp: $(FATE_BMP-yes) diff --git a/tests/fate/cdxl.mak b/tests/fate/cdxl.mak index 86eaa09d0a..2c69e39749 100644 --- a/tests/fate/cdxl.mak +++ b/tests/fate/cdxl.mak @@ -13,5 +13,7 @@ fate-cdxl-pal8-small: CMD = framecrc -i $(SAMPLES)/cdxl/fruit.cdxl -an -pix_fmt FATE_CDXL += fate-cdxl-bitline-ham6 fate-cdxl-bitline-ham6: CMD = framecrc -i $(SAMPLES)/cdxl/bitline.cdxl -frames:v 10 -FATE_SAMPLES_AVCONV += $(FATE_CDXL) -fate-cdxl: $(FATE_CDXL) +FATE_CDXL-$(call DEMDEC, CDXL, CDXL) += $(FATE_CDXL) + +FATE_SAMPLES_AVCONV += $(FATE_CDXL-yes) +fate-cdxl: $(FATE_CDXL-yes) diff --git a/tests/fate/dfa.mak b/tests/fate/dfa.mak index 56f7bfeeb9..4800d8aa90 100644 --- a/tests/fate/dfa.mak +++ b/tests/fate/dfa.mak @@ -31,5 +31,7 @@ fate-dfa10: CMD = framecrc -i $(SAMPLES)/chronomaster-dfa/0009.dfa -pix_fmt rgb2 FATE_DFA += fate-dfa11 fate-dfa11: CMD = framecrc -i $(SAMPLES)/chronomaster-dfa/0010.dfa -pix_fmt rgb24 -FATE_SAMPLES_AVCONV += $(FATE_DFA) -fate-dfa: $(FATE_DFA) +FATE_DFA-$(call DEMDEC, DFA, DFA) += $(FATE_DFA) + +FATE_SAMPLES_AVCONV += $(FATE_DFA-yes) +fate-dfa: $(FATE_DFA-yes) diff --git a/tests/fate/mp3.mak b/tests/fate/mp3.mak index bd0657d21f..663f14e13d 100644 --- a/tests/fate/mp3.mak +++ b/tests/fate/mp3.mak @@ -30,7 +30,10 @@ FATE_MP3 += fate-mp3-float-extra_overread fate-mp3-float-extra_overread: CMD = pcm -c:a mp3float -i $(SAMPLES)/mpegaudio/extra_overread.mp3 fate-mp3-float-extra_overread: REF = $(SAMPLES)/mpegaudio/extra_overread.pcm -FATE_SAMPLES_AVCONV += $(FATE_MP3) -fate-mp3: $(FATE_MP3) $(FATE_MP3): CMP = stddev $(FATE_MP3): FUZZ = 0.07 + +FATE_MP3-$(call DEMDEC, MP3, MP3FLOAT) += $(FATE_MP3) + +FATE_SAMPLES_AVCONV += $(FATE_MP3-yes) +fate-mp3: $(FATE_MP3-yes) -- cgit v1.2.3 From cb45553f577f8e0ebfe05d3287e1b6fa5859b967 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sat, 20 Oct 2012 15:22:41 +0200 Subject: Remove pointless #undefs of previously forbidden functions. --- libavcodec/golomb-test.c | 1 - libavcodec/iirfilter.c | 1 - libavcodec/libfaac.c | 2 -- libavdevice/libcdio.c | 3 --- libavdevice/libdc1394.c | 2 -- libavdevice/timefilter.c | 2 -- libavfilter/filtfmts.c | 3 --- libavfilter/vf_drawtext.c | 2 -- libavformat/network.c | 2 -- libavformat/output-example.c | 2 -- libavformat/seek-test.c | 3 --- libavformat/url-test.c | 3 --- libavformat/utils.c | 2 -- libavutil/avstring.c | 1 - libavutil/base64.c | 2 -- libavutil/blowfish.c | 2 -- libavutil/cpu.c | 1 - libavutil/crc.c | 1 - libavutil/des.c | 3 --- libavutil/eval.c | 1 - libavutil/fifo.c | 2 -- libavutil/log.c | 2 -- libavutil/md5.c | 1 - libavutil/mem.c | 5 ----- libavutil/opt.c | 2 -- libavutil/parseutils.c | 3 --- libavutil/sha.c | 1 - libavutil/xtea.c | 2 -- 28 files changed, 57 deletions(-) diff --git a/libavcodec/golomb-test.c b/libavcodec/golomb-test.c index bc90f36baf..e740a20aea 100644 --- a/libavcodec/golomb-test.c +++ b/libavcodec/golomb-test.c @@ -25,7 +25,6 @@ #include "golomb.h" #include "put_bits.h" -#undef fprintf #define COUNT 8191 #define SIZE (COUNT * 4) diff --git a/libavcodec/iirfilter.c b/libavcodec/iirfilter.c index f9b9ff60d4..acfa9048b4 100644 --- a/libavcodec/iirfilter.c +++ b/libavcodec/iirfilter.c @@ -312,7 +312,6 @@ av_cold void ff_iir_filter_free_coeffs(struct FFIIRFilterCoeffs *coeffs) } #ifdef TEST -#undef printf #include #define FILT_ORDER 4 diff --git a/libavcodec/libfaac.c b/libavcodec/libfaac.c index 24f3bf2027..745fee2674 100644 --- a/libavcodec/libfaac.c +++ b/libavcodec/libfaac.c @@ -159,9 +159,7 @@ static av_cold int Faac_encode_init(AVCodecContext *avctx) memcpy(avctx->extradata, buffer, avctx->extradata_size); faac_cfg->outputFormat = 0; } -#undef free free(buffer); -#define free please_use_av_free } if (!faacEncSetConfiguration(s->faac_handle, faac_cfg)) { diff --git a/libavdevice/libcdio.c b/libavdevice/libcdio.c index a82ad67f34..e846ee635b 100644 --- a/libavdevice/libcdio.c +++ b/libavdevice/libcdio.c @@ -33,9 +33,6 @@ #include "libavformat/avformat.h" #include "libavformat/internal.h" -/* cdio returns some malloced strings that need to be free()d */ -#undef free - typedef struct CDIOContext { AVClass *class; cdrom_drive_t *drive; diff --git a/libavdevice/libdc1394.c b/libavdevice/libdc1394.c index d953e12cbe..f030e3e31d 100644 --- a/libavdevice/libdc1394.c +++ b/libavdevice/libdc1394.c @@ -48,8 +48,6 @@ #define DC1394_FRAMERATE_240 FRAMERATE_240 #endif -#undef free - typedef struct dc1394_data { AVClass *class; #if HAVE_LIBDC1394_1 diff --git a/libavdevice/timefilter.c b/libavdevice/timefilter.c index 8f52fc5d62..8b98d338f0 100644 --- a/libavdevice/timefilter.c +++ b/libavdevice/timefilter.c @@ -78,8 +78,6 @@ double ff_timefilter_update(TimeFilter *self, double system_time, double period) #include "libavutil/lfg.h" #define LFG_MAX ((1LL << 32) - 1) -#undef printf - int main(void) { AVLFG prng; diff --git a/libavfilter/filtfmts.c b/libavfilter/filtfmts.c index 3ec8116635..480b277468 100644 --- a/libavfilter/filtfmts.c +++ b/libavfilter/filtfmts.c @@ -25,9 +25,6 @@ #include "libavfilter/avfilter.h" #include "libavfilter/formats.h" -#undef fprintf -#undef printf - int main(int argc, char **argv) { AVFilter *filter; diff --git a/libavfilter/vf_drawtext.c b/libavfilter/vf_drawtext.c index e1c2bb1920..f8800d2820 100644 --- a/libavfilter/vf_drawtext.c +++ b/libavfilter/vf_drawtext.c @@ -46,8 +46,6 @@ #include "internal.h" #include "video.h" -#undef time - #include #include #include FT_FREETYPE_H diff --git a/libavformat/network.c b/libavformat/network.c index fe17bdf2eb..1f6bc10995 100644 --- a/libavformat/network.c +++ b/libavformat/network.c @@ -57,8 +57,6 @@ static unsigned long openssl_thread_id(void) #if HAVE_THREADS && GNUTLS_VERSION_NUMBER <= 0x020b00 #include #include -#undef malloc -#undef free GCRY_THREAD_OPTION_PTHREAD_IMPL; #endif #endif diff --git a/libavformat/output-example.c b/libavformat/output-example.c index e4babb49a5..2f83990011 100644 --- a/libavformat/output-example.c +++ b/libavformat/output-example.c @@ -38,8 +38,6 @@ #include "libavformat/avformat.h" #include "libswscale/swscale.h" -#undef exit - /* 5 seconds stream duration */ #define STREAM_DURATION 5.0 #define STREAM_FRAME_RATE 25 /* 25 images/s */ diff --git a/libavformat/seek-test.c b/libavformat/seek-test.c index 57d3fa4da5..143f0b5ace 100644 --- a/libavformat/seek-test.c +++ b/libavformat/seek-test.c @@ -28,9 +28,6 @@ #include "libavutil/mathematics.h" #include "libavformat/avformat.h" -#undef printf -#undef fprintf - static char buffer[20]; static const char *ret_str(int v) diff --git a/libavformat/url-test.c b/libavformat/url-test.c index 58258e502a..6639ccf7b8 100644 --- a/libavformat/url-test.c +++ b/libavformat/url-test.c @@ -20,9 +20,6 @@ #include "internal.h" -#undef printf -#undef exit - static void test(const char *base, const char *rel) { char buf[200], buf2[200]; diff --git a/libavformat/utils.c b/libavformat/utils.c index 481760b5ad..12b054d935 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -3092,7 +3092,6 @@ static void hex_dump_internal(void *avcl, FILE *f, int level, const uint8_t *buf, int size) { int len, i, j, c; -#undef fprintf #define PRINT(...) do { if (!f) av_log(avcl, level, __VA_ARGS__); else fprintf(f, __VA_ARGS__); } while(0) for(i=0;istream_index); PRINT(" keyframe=%d\n", ((pkt->flags & AV_PKT_FLAG_KEY) != 0)); diff --git a/libavutil/avstring.c b/libavutil/avstring.c index 6b3a65c7f0..c14832e7b9 100644 --- a/libavutil/avstring.c +++ b/libavutil/avstring.c @@ -159,7 +159,6 @@ int av_strncasecmp(const char *a, const char *b, size_t n) #ifdef TEST #include "common.h" -#undef printf int main(void) { diff --git a/libavutil/base64.c b/libavutil/base64.c index c1fba897be..d16195f1b9 100644 --- a/libavutil/base64.c +++ b/libavutil/base64.c @@ -101,8 +101,6 @@ char *av_base64_encode(char *out, int out_size, const uint8_t *in, int in_size) #ifdef TEST -#undef printf - #define MAX_DATA_SIZE 1024 #define MAX_ENCODED_SIZE 2048 diff --git a/libavutil/blowfish.c b/libavutil/blowfish.c index e6f07d6ad0..63cc4043ff 100644 --- a/libavutil/blowfish.c +++ b/libavutil/blowfish.c @@ -428,7 +428,6 @@ void av_blowfish_crypt(AVBlowfish *ctx, uint8_t *dst, const uint8_t *src, #ifdef TEST #include -#undef printf #define NUM_VARIABLE_KEY_TESTS 34 @@ -531,7 +530,6 @@ static const uint8_t ciphertext2[16] = { #define IV "blowfish" -#undef exit static void test_blowfish(AVBlowfish *ctx, uint8_t *dst, const uint8_t *src, const uint8_t *ref, int len, uint8_t *iv, int dir, const char *test) diff --git a/libavutil/cpu.c b/libavutil/cpu.c index 8db69be24e..23016d68a9 100644 --- a/libavutil/cpu.c +++ b/libavutil/cpu.c @@ -111,7 +111,6 @@ int av_parse_cpu_flags(const char *s) #ifdef TEST -#undef printf #include static const struct { diff --git a/libavutil/crc.c b/libavutil/crc.c index 47520e5cf4..3d1d876037 100644 --- a/libavutil/crc.c +++ b/libavutil/crc.c @@ -113,7 +113,6 @@ uint32_t av_crc(const AVCRC *ctx, uint32_t crc, } #ifdef TEST -#undef printf int main(void) { uint8_t buf[1999]; diff --git a/libavutil/des.c b/libavutil/des.c index c7c6f1dbee..01cb10b359 100644 --- a/libavutil/des.c +++ b/libavutil/des.c @@ -337,9 +337,6 @@ void av_des_mac(AVDES *d, uint8_t *dst, const uint8_t *src, int count) { } #ifdef TEST -#undef printf -#undef rand -#undef srand #include #include #include "libavutil/time.h" diff --git a/libavutil/eval.c b/libavutil/eval.c index 7a28dbe12d..7887cf6b0e 100644 --- a/libavutil/eval.c +++ b/libavutil/eval.c @@ -545,7 +545,6 @@ int av_expr_parse_and_eval(double *d, const char *s, } #ifdef TEST -#undef printf #include static const double const_values[] = { diff --git a/libavutil/fifo.c b/libavutil/fifo.c index 5774d33d25..26848999ec 100644 --- a/libavutil/fifo.c +++ b/libavutil/fifo.c @@ -130,8 +130,6 @@ void av_fifo_drain(AVFifoBuffer *f, int size) #ifdef TEST -#undef printf - int main(void) { /* create a FIFO buffer */ diff --git a/libavutil/log.c b/libavutil/log.c index 45c649aae6..80129769f6 100644 --- a/libavutil/log.c +++ b/libavutil/log.c @@ -55,7 +55,6 @@ static const uint8_t color[] = { 0x41, 0x41, 0x11, 0x03, 9, 0x02, 0x06 }; #endif static int use_color = -1; -#undef fprintf static void colored_fputs(int level, const char *str) { if (use_color < 0) { @@ -104,7 +103,6 @@ void av_log_default_callback(void* ptr, int level, const char* fmt, va_list vl) if (level > av_log_level) return; line[0] = 0; -#undef fprintf if (print_prefix && avc) { if (avc->parent_log_context_offset) { AVClass** parent = *(AVClass ***) (((uint8_t *) ptr) + diff --git a/libavutil/md5.c b/libavutil/md5.c index 93a91d7812..efb993e605 100644 --- a/libavutil/md5.c +++ b/libavutil/md5.c @@ -182,7 +182,6 @@ void av_md5_sum(uint8_t *dst, const uint8_t *src, const int len) } #ifdef TEST -#undef printf #include static void print_md5(uint8_t *md5) diff --git a/libavutil/mem.c b/libavutil/mem.c index b6c0b29319..3a4433d154 100644 --- a/libavutil/mem.c +++ b/libavutil/mem.c @@ -38,11 +38,6 @@ #include "intreadwrite.h" #include "mem.h" -/* here we can use OS-dependent allocation functions */ -#undef free -#undef malloc -#undef realloc - #ifdef MALLOC_PREFIX #define malloc AV_JOIN(MALLOC_PREFIX, malloc) diff --git a/libavutil/opt.c b/libavutil/opt.c index 61a72d0a40..d2cb9ef95a 100644 --- a/libavutil/opt.c +++ b/libavutil/opt.c @@ -685,8 +685,6 @@ const AVClass *av_opt_child_class_next(const AVClass *parent, const AVClass *pre #ifdef TEST -#undef printf - typedef struct TestContext { const AVClass *class; diff --git a/libavutil/parseutils.c b/libavutil/parseutils.c index 28aa9c9521..917451eee7 100644 --- a/libavutil/parseutils.c +++ b/libavutil/parseutils.c @@ -498,7 +498,6 @@ int av_parse_time(int64_t *timeval, const char *timestr, int duration) char lastch; int negative = 0; -#undef time time_t now = time(0); len = strlen(timestr); @@ -643,8 +642,6 @@ int av_find_info_tag(char *arg, int arg_size, const char *tag1, const char *info #ifdef TEST -#undef printf - int main(void) { printf("Testing av_parse_video_rate()\n"); diff --git a/libavutil/sha.c b/libavutil/sha.c index d5831915c4..c7c6ce38cf 100644 --- a/libavutil/sha.c +++ b/libavutil/sha.c @@ -334,7 +334,6 @@ void av_sha_final(AVSHA* ctx, uint8_t *digest) #ifdef TEST #include -#undef printf int main(void) { diff --git a/libavutil/xtea.c b/libavutil/xtea.c index f3357ce544..1187662eb2 100644 --- a/libavutil/xtea.c +++ b/libavutil/xtea.c @@ -101,7 +101,6 @@ void av_xtea_crypt(AVXTEA *ctx, uint8_t *dst, const uint8_t *src, int count, #ifdef TEST #include -#undef printf #define XTEA_NUM_TESTS 6 @@ -138,7 +137,6 @@ static const uint8_t xtea_test_ct[XTEA_NUM_TESTS][8] = { { 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41 } }; -#undef exit static void test_xtea(AVXTEA *ctx, uint8_t *dst, const uint8_t *src, const uint8_t *ref, int len, uint8_t *iv, int dir, const char *test) -- cgit v1.2.3