Menu

#25 compilation error with gcc version 4.4.1 [gcc-4_4-branch rev

closed-out-of-date
nobody
None
5
2011-07-26
2010-08-20
zmi007
No

Hi,

cant't compile blitz with default gcc compiler
term@box:~/blitz-0.9>./configure CXX=g++ FC=gfortran F77=gfortran
...
term@box:~/blitz-0.9> make lib
make[1]: Entering directory `/home/term/blitz-0.9/lib'
if /bin/sh ../libtool --mode=compile --tag=CXX g++ -DHAVE_CONFIG_H -I.. -I.. -MT globals.lo -MD -MP -MF ".deps/globals.Tpo" -c -o globals.lo `test -f '../src/globals.cpp' || echo './'`../src/globals.cpp; \ then mv -f ".deps/globals.Tpo" ".deps/globals.Plo"; else rm -f ".deps/globals.Tpo"; exit 1; fi
g++ -DHAVE_CONFIG_H -I.. -I.. -MT globals.lo -MD -MP -MF .deps/globals.Tpo -c ../src/globals.cpp -o globals.o
In file included from ../blitz/applics.h:400,
from ../blitz/vecexpr.h:32,
from ../blitz/vecpick.cc:16,
from ../blitz/vecpick.h:293,
from ../blitz/vector.h:449,
from ../blitz/tinyvec.h:430,
from ../blitz/indexexpr.h:30,
from ../src/globals.cpp:11:
../blitz/mathfunc.h: In static member function 'static long int blitz::_bz_abs<long int>::apply(long int)':
../blitz/mathfunc.h:45: error: 'labs' is not a member of 'std'
In file included from ../blitz/array/funcs.h:29,
from ../blitz/array/newet.h:29,
from ../blitz/array/et.h:27,
from ../blitz/array-impl.h:2515,
from ../blitz/array.h:32,
from ../src/globals.cpp:13:
../blitz/funcs.h: In static member function 'static int blitz::Fn_abs<int>::apply(int)':
../blitz/funcs.h:509: error: call of overloaded 'abs(int&)' is ambiguous
/usr/include/c++/4.4/cmath:94: note: candidates are: double std::abs(double)
/usr/include/c++/4.4/cmath:98: note: float std::abs(float)
/usr/include/c++/4.4/cmath:102: note: long double std::abs(long double)
../blitz/funcs.h: In static member function 'static long int blitz::Fn_abs<long int>::apply(long int)':
../blitz/funcs.h:530: error: 'labs' is not a member of 'std'
make[1]: *** [globals.lo] Error 1

Discussion

  • Erik Zeek

    Erik Zeek - 2010-09-22

    I believe that is fixed in CVS. The last released version (0.9) is way out of date.

     
  • Patrik Jonsson

    Patrik Jonsson - 2011-07-26

    0.9 is out of date.

     
  • Patrik Jonsson

    Patrik Jonsson - 2011-07-26
    • status: open --> closed-out-of-date
     

Log in to post a comment.