diff options
author | Michael Kostylev <michael.kostylev@gmail.com> | 2007-12-27 01:53:02 +0000 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2007-12-27 01:53:02 +0000 |
commit | a33cab3a9a48cbbb495d2548143751f1dee67213 (patch) | |
tree | 49a8d94893e22f04f0eee8ba84baf7ae3e564f33 /configure | |
parent | 52d086084ede74aff217d5854e83bbd3ce863bb5 (diff) | |
download | ffmpeg-a33cab3a9a48cbbb495d2548143751f1dee67213.tar.gz |
Check for the presence of llrint(), lrint(), round() and roundf()
and provide simple replacements if they are unavailable.
patch by Michael Kostylev, mik niipt ru
Originally committed as revision 11326 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 12 |
1 files changed, 9 insertions, 3 deletions
@@ -706,6 +706,8 @@ HAVE_LIST=" getrusage imlib2 inet_aton + llrint + lrint lrintf machine_ioctl_bt848_h machine_ioctl_meteor_h @@ -714,6 +716,8 @@ HAVE_LIST=" mkstemp mlib ppc64 + round + roundf sdl sdl_video_size soundcard_h @@ -1593,12 +1597,14 @@ done check_lib math.h sin -lm -# test for lrintf in math.h -check_exec <<EOF && enable lrintf || disable lrintf +# test for C99 functions in math.h +for func in llrint lrint lrintf round roundf; do + check_exec <<EOF && enable $func || disable $func #define _ISOC9X_SOURCE 1 #include <math.h> -int main(void) { return (lrintf(3.999f) > 0)?0:1; } +int main(void) { return ($func(3.999f) > 0)?0:1; } EOF +done enabled_any libamr_nb libamr_wb && enable libamr |