CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (http://www.cfd-online.com/Forums/openfoam-installation/)
-   -   OpenFOAM 13IA64 compilation error for topoSetC (http://www.cfd-online.com/Forums/openfoam-installation/57580-openfoam-13ia64-compilation-error-toposetc.html)

begou January 22, 2007 10:36

I'm trying to compile OpenFoam
 
I'm trying to compile OpenFoam on a SGI Altix (IA64) runing Suse (SLES9) and gcc-g++-3.3.3-43.41 (latest supported version available).
I got an error on ./src/meshTools/lnInclude/topoSet.C when it instantiates a boundBox Object, but I've some difficulties to understand it. I saw that the boundBox constructor requires 2 arguments...but...
Can someone help me ?

Thanks for you help

Patrick

Error detail:
SOURCE=sets/topoSets/topoSet.C ; g++ -DlinuxIA64 -DDP -O3 -DNoRepository -ftemplate-depth-30 -I/scratch/begou/OpenFOAM-1.3/src/triSurface/lnInclude -I/scratch/begou/OpenFOAM-1.3/src/lagrangian/basic/lnInclude -I/scratch/begou/OpenFOAM-1.3/src/OpenFOAM/lnInclude -IlnInclude -I. -fPIC -c $SOURCE -o Make/linuxIA64I64DPOpt/topoSet.o
sets/topoSets/topoSet.C: In member function `void
Foam::topoSet::writeDebug(Foam:: Ostream&, const Foam::pointField&, int)
const':
sets/topoSets/topoSet.C:262: error: variable declaration is not allowed here
sets/topoSets/topoSet.C:265: error: request for member `min' in `Foam::bb',
which is of non-aggregate type `Foam::boundBox ()()'
sets/topoSets/topoSet.C:265: error: request for member `max' in `Foam::bb',
which is of non-aggregate type `Foam::boundBox ()()'
make: *** [Make/linuxIA64I64DPOpt/topoSet.o] Error 1


Location of the error:
251 void topoSet::writeDebug
252 (
253 Ostream& os,
254 const pointField& coords,
255 const label maxLen
256 ) const
257 {
258 // Bounding box of contents.
259 boundBox bb
260 (
261 pointField(IndirectList<point>(coords, toc())())
262 );

gschaider January 22, 2007 13:34

These are the unmodified OF-so
 
These are the unmodified OF-sources? My guess (guess! I don't know) is that its a problem with the compiler. 3.3 is fairly ancient. What I would try is download the latest stable gcc-sources, compile it, install it in parallel to the vendor provided gcc (/home/begou/OpenFOAM/gcc-4 for instance) and use that to compile Foam.

A quote from http://www.cfd-online.com/OpenFOAM_D...ges/1/116.html:

"I just wanted to write and say it seems all of the compilation warnings/problems were fixed when I installed a local version of gcc-4.1.1. Highly recommend doing this instead of using local compilers."


All times are GMT -4. The time now is 07:02.