gnash-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnash-dev] Build problem on OS/2


From: David Rorex
Subject: Re: [Gnash-dev] Build problem on OS/2
Date: Wed, 8 Aug 2007 18:03:37 -0700

On 8/8/07, Paul Smedley <address@hidden> wrote:


strk wrote:
> On Thu, Aug 09, 2007 at 08:39:04AM +0930, Paul Smedley wrote:
>> Hi All,
>>
>> I did a fresh cvs pull today for the first time in a few weeks, and am
>> getting the following compilation error on OS/2:
>>
>> swf/tag_loaders.cpp: In function `void gnash::adpcm_expand(unsigned char*&,
>>    gnash::stream*, int, bool)':
>> swf/tag_loaders.cpp:1736: error: call of overloaded `ceil(int)' is ambiguous
>> U:/USR/include/math.h:229: error: candidates are: double ceil(double)
>> U:/USR/include/c++/3.3.5/cmath:268: error:                 long double
>>    std::ceil(long double)
>> U:/USR/include/c++/3.3.5/cmath:260: error:                 float
>>    std::ceil(float)
>> make.exe[3]: *** [tag_loaders.lo] Error 1
>>
>> Any ideas?
>
> try using std::ceil.
ok:
#ifndef __OS2__
        in->ensureBytes( sample_count * ( 3 + (int)ceil(n_bits/8) ) );
#else
        in->ensureBytes( sample_count * ( 3 + (int)ceil((long double)n_bits/8) ) );
#endif

fixed it...

Cheers,

Paul

Why is it even calling ceil on an int in the first place? I think you should be able to simply do: (regardless of platform)

        in->ensureBytes( sample_count * ( 3 + n_bits/8 );
reply via email to

[Prev in Thread] Current Thread [Next in Thread]