[GRASS5] Re: [GRASSLIST:2373] Re:Re: grass57 compilation error

> > compiling grass57_exp_2004_01_17 in debian3.0.x woody i get the
> > following error:

...

> > direction.h:46: ostream: No such file or directory

...

> The recent updates to r.terraflow introduced a new problem with
> gcc <= 3.x. What gcc verison do you use?

...

my gcc version is:
gcc version 2.95.4 20011002 (Debian prerelease)

Fixed in CVS, should work for any gcc from 2.95 to 3.3 now.

gcc 2.95 has forward compatible headers for all the other include's[*],
but not ostream.h. So we still get ~four "depreciated" warnings when
compiled with gcc 3.3, but that's better than it not working at all with
gcc 2.95.

[*] i.e. gcc's fault, not any particular linux distro's, AFAICT.

We may have to think of something else if gcc 3.4 drops backwards
compatibility.

by the way, does it *really* only compile with gcc/g++? What's the
problem exactly?

Hamish

On Thu, 29 Jan 2004, Hamish wrote:

by the way, does it *really* only compile with gcc/g++? What's the
problem exactly?

See http://grass.itc.it/pipermail/grass5/2003-February/007312.html for
ther errors when I tried the original version in GRASS with IRIX 6.2 CC
(C++ compiler).

Now it is much simpler:
(compiling with gmake53 because r.terraflow doesn't work with the new
build system)

  SRC = /indigo-disk2/grass/grass/src
  CMD = /indigo-disk2/grass/grass/src/CMD
  UNUSED = /indigo-disk2/grass/grass/unused
  HEADER = head.mips-sgi-irix6.2
  ARCH = mips-sgi-irix6.2
  GISBASE = /indigo-disk2/grass/grass/dist.mips-sgi-irix6.2
  VERSION = 5.3-cvs 2003
#################################################################
/indigo-disk2/grass/grass/src.contrib/DUKE/r.terraflow
  make -f OBJ.mips-sgi-irix6.2/make.rules

mkdir OBJ.mips-sgi-irix6.2/FLOAT ; true
mkdir: cannot create directory `OBJ.mips-sgi-irix6.2/FLOAT': File exists
mkdir OBJ.mips-sgi-irix6.2/SHORT ; true
mkdir: cannot create directory `OBJ.mips-sgi-irix6.2/SHORT': File exists
CC -c -I/indigo-disk2/grass/grass/src/include -I/usr/local/include -g -I/usr/local/include -I./IOStream/include -DUSER=\"paulk\" -DNODATA_FIX -D_FILE_OFFSET_BITS=64 -DELEV_FLOAT main.cc -o OBJ.mips-sgi-irix6.2/FLOAT/main.o
"common.h", line 46: error(4003): could not open source file "iostream"
  #include <iostream>
                     ^

1 catastrophic error detected in the compilation of "main.cc".
Compilation terminated.
make: *** [OBJ.mips-sgi-irix6.2/FLOAT/main.o] Error 1