Initial cparser support.
---

Beside a single bug triggered by our wonderful matroskaenc and an
unimplemented atomic primitive we use cparser can build Libav in i686 mode.

 configure | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/configure b/configure
index a0d2d54..c7f3baa 100755
--- a/configure
+++ b/configure
@@ -2432,6 +2432,18 @@ pgi_flags(){
     done
 }

+cparser_flags(){
+    for flag; do
+        case $flag in
+            -Wno-switch)             echo -Wno-switch-enum ;;
+            -Wno-format-zero-length) ;;
+            -Wdisabled-optimization) ;;
+            -Wno-pointer-sign)       echo -Wno-other ;;
+            *)                       echo $flag ;;
+        esac
+    done
+}
+
 suncc_flags(){
     for flag; do
         case $flag in
@@ -2660,6 +2672,14 @@ probe_cc(){
         if [ $pfx = hostcc ]; then
             append _cflags -Dsnprintf=_snprintf
         fi
+    elif $_cc --version 2>/dev/null | grep -q ^cparser; then
+        _type=cparser
+        _ident=$($_cc --version | head -n1)
+        _depflags='-MMD'
+        _cflags_speed='-O4'
+        _cflags_size='-O2'
+        _flags='-Wno-missing-variable-declarations -Wno-empty-statement'
+        _flags_filter=cparser_flags
     fi

     eval ${pfx}_type=\$_type
--
1.8.3.2

_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to