From 95e2ce4aa05d0bd24c5620937b47e21125532df1 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Tue, 5 Nov 2002 00:07:05 +0000 Subject: lrintf detection (based upon a patch by François Revol ) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Originally committed as revision 1162 to svn://svn.ffmpeg.org/ffmpeg/trunk --- configure | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'configure') diff --git a/configure b/configure index 5a36eca825..d4e6134f9d 100755 --- a/configure +++ b/configure @@ -360,6 +360,19 @@ if test "$zlib" = "yes"; then extralibs="$extralibs -lz" fi +# test for lrintf in math.h +cat > $TMPC << EOF +#define _ISOC9X_SOURCE 1 +#include +int main( void ) { return (lrintf(3.999f) > 0)?0:1; } +EOF + +have_lrintf="no" +if $cc $extralibs -o $TMPO $TMPC 2> /dev/null ; then + have_lrintf="yes" + $TMPO 2> /dev/null > /dev/null || have_lrintf="no" +fi + _restrict= for restrict_keyword in restrict __restrict__ __restrict; do echo "void foo(char * $restrict_keyword p);" > $TMPC @@ -496,6 +509,9 @@ fi if test "$imlib2" = "yes" ; then echo "HAVE_IMLIB2=yes" >> config.mak fi +if test "$have_lrintf" = "yes" ; then + echo "#define HAVE_LRINTF 1" >> $TMPH +fi if test "$vhook" = "yes" ; then echo "BUILD_VHOOK=yes" >> config.mak echo "#define HAVE_VHOOK 1" >> $TMPH -- cgit v1.2.3