[FFmpeg-cvslog] lavu: test for broken binutils on ARM

Michael Niedermayer git at videolan.org
Sat Jan 5 17:08:18 CET 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Dec 15 20:46:33 2012 +0100| [9a697cfe716e2ed5f5ba183910c104c5ad783256] | committer: Michael Niedermayer

lavu: test for broken binutils on ARM

Some old gnu assemblers fail to assemble qdadd correctly
Ideally we should check this at build time, but better to
check at run time than mysteriously failing.

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9a697cfe716e2ed5f5ba183910c104c5ad783256
---

 libavutil/utils.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/libavutil/utils.c b/libavutil/utils.c
index 01c940c..fbfbc49 100644
--- a/libavutil/utils.c
+++ b/libavutil/utils.c
@@ -35,6 +35,11 @@ unsigned avutil_version(void)
     av_assert0(LIBAVUTIL_VERSION_MICRO >= 100);
     av_assert0(HAVE_MMX2 == HAVE_MMXEXT);
 
+    if (av_sat_dadd32(1, 2) != 5) {
+        av_log(NULL, AV_LOG_FATAL, "Libavutil has been build with a broken binutils, please upgrade binutils and rebuild\n");
+        abort();
+    }
+
     return LIBAVUTIL_VERSION_INT;
 }
 



More information about the ffmpeg-cvslog mailing list