CONFIGURE: Don't execute a binary just to check libpng version
This fixes detection of libpng when cross-compiling. svn-id: r53404
This commit is contained in:
parent
02322c562c
commit
b3c352d1fe
1 changed files with 8 additions and 3 deletions
11
configure
vendored
11
configure
vendored
|
@ -2372,10 +2372,15 @@ if test "$_png" = auto ; then
|
|||
_png=no
|
||||
cat > $TMPC << EOF
|
||||
#include <png.h>
|
||||
int main(void) { if (PNG_LIBPNG_VER >= 10208) { return 0; } return 1; }
|
||||
int main(void) {
|
||||
#if PNG_LIBPNG_VER >= 10208
|
||||
#else
|
||||
syntax error
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
EOF
|
||||
cc_check_no_clean $PNG_CFLAGS $PNG_LIBS -lpng && $TMPO$HOSTEXEEXT && _png=yes
|
||||
cc_check_clean
|
||||
cc_check $PNG_CFLAGS $PNG_LIBS -lpng && _png=yes
|
||||
fi
|
||||
if test "$_png" = yes ; then
|
||||
LIBS="$LIBS $PNG_LIBS -lpng"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue