changeset 35722:9cfa30063480

configure: Simplify liba52 check through helper functions.
author diego
date Mon, 21 Jan 2013 23:05:23 +0000
parents 684e793fe7b7
children fb3523ff2ef4
files configure
diffstat 1 files changed, 2 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/configure	Mon Jan 21 23:05:20 2013 +0000
+++ b/configure	Mon Jan 21 23:05:23 2013 +0000
@@ -6490,12 +6490,8 @@
 def_liba52='#undef CONFIG_LIBA52'
 if test "$_liba52" = auto ; then
   _liba52=no
-  cat > $TMPC << EOF
-#include <inttypes.h>
-#include <a52dec/a52.h>
-int main(void) { a52_state_t *testHand; testHand=a52_init(0); return 0; }
-EOF
-  cc_check -la52 && _liba52=yes && extra_ldflags="$extra_ldflags -la52"
+  statement_check_broken inttypes.h a52dec/a52.h 'a52_state_t *testHand; testHand=a52_init(0)' -la52 &&
+    _liba52=yes && extra_ldflags="$extra_ldflags -la52"
 fi
 if test "$_liba52" = yes ; then
   def_liba52='#define CONFIG_LIBA52 1'