summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libavcodec/dct-test.c3
-rw-r--r--libavcodec/dsputil.h5
-rw-r--r--libavcodec/fft-test.c3
3 files changed, 11 insertions, 0 deletions
diff --git a/libavcodec/dct-test.c b/libavcodec/dct-test.c
index 5699d89813..e96c895c21 100644
--- a/libavcodec/dct-test.c
+++ b/libavcodec/dct-test.c
@@ -531,7 +531,10 @@ int main(int argc, char **argv)
init_fdct();
idct_mmx_init();
+
+#ifndef mm_flags
mm_flags = mm_support();
+#endif
for(i=0;i<256;i++) cropTbl[i + MAX_NEG_CROP] = i;
for(i=0;i<MAX_NEG_CROP;i++) {
diff --git a/libavcodec/dsputil.h b/libavcodec/dsputil.h
index 0316a451b3..3b7b8791b8 100644
--- a/libavcodec/dsputil.h
+++ b/libavcodec/dsputil.h
@@ -578,6 +578,11 @@ extern int mm_flags;
#define DECLARE_ALIGNED_8(t, v) DECLARE_ALIGNED(16, t, v)
#define STRIDE_ALIGN 16
+#else
+
+#define mm_flags 0
+#define mm_support() 0
+
#endif
#ifndef DECLARE_ALIGNED_8
diff --git a/libavcodec/fft-test.c b/libavcodec/fft-test.c
index 88aab487ae..55225fb1f2 100644
--- a/libavcodec/fft-test.c
+++ b/libavcodec/fft-test.c
@@ -186,7 +186,10 @@ int main(int argc, char **argv)
MDCTContext m1, *m = &m1;
int fft_nbits, fft_size;
+#ifndef mm_flags
mm_flags = 0;
+#endif
+
fft_nbits = 9;
for(;;) {
c = getopt(argc, argv, "hsimn:");