[mythtv] 0.24-fixes complilation error
jyavenard at gmail.com
Fri Oct 22 01:45:07 UTC 2010
On 21 October 2010 18:03, Torbjörn Jansson
<torbjorn.jansson at mbox200.swipnet.se> wrote:
> Hello all.
> Tried to compile 0.24-fixes rev 26934 and all I got was this error.
> Any ideas on what's wrong?
An issue with your compiled.
std::abs isn't defined with all C++ compiler. GNU C++ should have it
though, I thought all g++ >= 3 had it.
For the time being, you can add at the top of RingBuffer.cpp:
long long abs(long long x)
return x < 0 ? -x : x;
> RingBuffer.cpp: In member function 'long long int RingBuffer::Seek(long long
> int, int, bool)':
> RingBuffer.cpp:1924: error: call of overloaded 'abs(long long int)' is
> /usr/include/stdlib.h:699: note: candidates are: int abs(int)
> /usr/include/c++/4.3/cstdlib:144: note: long int
> std::abs(long int)
> /usr/include/c++/4.3/cmath:107: note: long double
> std::abs(long double)
> /usr/include/c++/4.3/cmath:103: note: float std::abs(float)
> /usr/include/c++/4.3/cmath:99: note: double std::abs(double)
> make: *** [RingBuffer.o] Error 1
> mythtv-dev mailing list
> mythtv-dev at mythtv.org
More information about the mythtv-dev