[asterisk-bugs] [Asterisk 0018193]: roundf causing asterisk to fail to compile
Asterisk Bug Tracker
noreply at bugs.digium.com
Fri Oct 22 15:56:03 CDT 2010
The following issue has been SUBMITTED.
======================================================================
https://issues.asterisk.org/view.php?id=18193
======================================================================
Reported By: ovi
Assigned To:
======================================================================
Project: Asterisk
Issue ID: 18193
Category: Core/Portability
Reproducibility: always
Severity: minor
Priority: normal
Status: new
Asterisk Version: 1.8.0
JIRA:
Regression: No
Reviewboard Link:
SVN Branch (only for SVN checkouts, not tarball releases): N/A
SVN Revision (number only!):
Request Review:
======================================================================
Date Submitted: 2010-10-22 15:56 CDT
Last Modified: 2010-10-22 15:56 CDT
======================================================================
Summary: roundf causing asterisk to fail to compile
Description:
roundf is not available on some embedded systems and this is causing the
compilation to fail.
By applying the following patch, the issue was circumvented:
--- main/file.c.orig 2009-06-26 21:26:50.000000000 +0000
+++ main/file.c 2009-11-01 01:00:56.643765305 +0000
@@ -744,7 +744,7 @@
float samp_rate = (float)
ast_format_rate(s->fmt->format);
unsigned int rate;
- rate = (unsigned int) roundf(samp_rate / ((float)
whennext));
+ rate = (unsigned int) (samp_rate / ((float)
whennext) + 0.5);
ast_settimeout(s->owner, rate, ast_fsread_audio,
s);
} else {
Can we add a detection for roundf during configure and ifdef the roundf
call?
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
2010-10-22 15:56 ovi New Issue
2010-10-22 15:56 ovi Asterisk Version => 1.8.0
2010-10-22 15:56 ovi Regression => No
2010-10-22 15:56 ovi SVN Branch (only for SVN checkouts, not tarball
releases) => N/A
======================================================================
More information about the asterisk-bugs
mailing list