CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   SU2 Installation (http://www.cfd-online.com/Forums/su2-installation/)
-   -   Compile Error on Fedora, g++, no CGNS, no Metis (http://www.cfd-online.com/Forums/su2-installation/122775-compile-error-fedora-g-no-cgns-no-metis.html)

jstults August 27, 2013 21:10

Compile Error on Fedora, g++, no CGNS, no Metis
 
Here's what I did:
Code:

git clone https://github.com/su2code/SU2
Then
Code:

./configure
make

No errors reported on the configure, but I get this error on the compile:

Code:

g++ -DPACKAGE_NAME=\"SU\^2\" -DPACKAGE_TARNAME=\"SU\^2\" -DPACKAGE_VERSION=\"2.0.6\" -DPACKAGE_STRING=\"SU\^2\ 2.0.6\" -DPACKAGE_BUGREPORT=\"susquared-dev@lists.stanford.edu\" -DPACKAGE_URL=\"http://su2.stanford.edu\" -DPACKAGE=\"SU\^2\" -DVERSION=\"2.0.6\" -I.    -DNO_CGNS -DNO_METIS -DNO_TECIO -DNO_MPI -MT ../src/libSU2_a-linear_solvers_structure.o -MD -MP -MF ../src/.deps/libSU2_a-linear_solvers_structure.Tpo -c -o ../src/libSU2_a-linear_solvers_structure.o `test -f '../src/linear_solvers_structure.cpp' || echo './'`../src/linear_solvers_structure.cpp
../src/linear_solvers_structure.cpp: In member function ‘long unsigned int CSysSolve::ConjugateGradient(const CSysVector&, CSysVector&, CMatrixVectorProduct&, CPreconditioner&, double, long unsigned int, bool)’:
../src/linear_solvers_structure.cpp:155:11: error: ‘exit’ was not declared in this scope
../src/linear_solvers_structure.cpp: In member function ‘long unsigned int CSysSolve::FGMRES(const CSysVector&, CSysVector&, CMatrixVectorProduct&, CPreconditioner&, double, long unsigned int, bool)’:
../src/linear_solvers_structure.cpp:260:11: error: ‘exit’ was not declared in this scope
../src/linear_solvers_structure.cpp:271:11: error: ‘exit’ was not declared in this scope
../src/linear_solvers_structure.cpp: In member function ‘long unsigned int CSysSolve::BCGSTAB(const CSysVector&, CSysVector&, CMatrixVectorProduct&, CPreconditioner&, double, long unsigned int, bool)’:
../src/linear_solvers_structure.cpp:392:11: error: ‘exit’ was not declared in this scope
make[1]: *** [../src/libSU2_a-linear_solvers_structure.o] Error 1

I successfully compiled / ran version 2.0.2 from the tarball on this system before you guys went to git (thanks for doing that btw).

fpalacios August 28, 2013 00:02

Thanks for letting us know, and your nice words.

As you know, exit() is a very typical function in C++. But, as far I see, in gcc 4.3 the #include <cstdlib> should be in the code (before we were using #include <iostream>).

I have just updated the git repository. Could you please try again with the new code.

Cheers,
Francisco

Quote:

Originally Posted by jstults (Post 448410)
Here's what I did:
Code:

git clone https://github.com/su2code/SU2
Then
Code:

./configure
make

No errors reported on the configure, but I get this error on the compile:

Code:

g++ -DPACKAGE_NAME=\"SU\^2\" -DPACKAGE_TARNAME=\"SU\^2\" -DPACKAGE_VERSION=\"2.0.6\" -DPACKAGE_STRING=\"SU\^2\ 2.0.6\" -DPACKAGE_BUGREPORT=\"susquared-dev@lists.stanford.edu\" -DPACKAGE_URL=\"http://su2.stanford.edu\" -DPACKAGE=\"SU\^2\" -DVERSION=\"2.0.6\" -I.    -DNO_CGNS -DNO_METIS -DNO_TECIO -DNO_MPI -MT ../src/libSU2_a-linear_solvers_structure.o -MD -MP -MF ../src/.deps/libSU2_a-linear_solvers_structure.Tpo -c -o ../src/libSU2_a-linear_solvers_structure.o `test -f '../src/linear_solvers_structure.cpp' || echo './'`../src/linear_solvers_structure.cpp
../src/linear_solvers_structure.cpp: In member function ‘long unsigned int CSysSolve::ConjugateGradient(const CSysVector&, CSysVector&, CMatrixVectorProduct&, CPreconditioner&, double, long unsigned int, bool)’:
../src/linear_solvers_structure.cpp:155:11: error: ‘exit’ was not declared in this scope
../src/linear_solvers_structure.cpp: In member function ‘long unsigned int CSysSolve::FGMRES(const CSysVector&, CSysVector&, CMatrixVectorProduct&, CPreconditioner&, double, long unsigned int, bool)’:
../src/linear_solvers_structure.cpp:260:11: error: ‘exit’ was not declared in this scope
../src/linear_solvers_structure.cpp:271:11: error: ‘exit’ was not declared in this scope
../src/linear_solvers_structure.cpp: In member function ‘long unsigned int CSysSolve::BCGSTAB(const CSysVector&, CSysVector&, CMatrixVectorProduct&, CPreconditioner&, double, long unsigned int, bool)’:
../src/linear_solvers_structure.cpp:392:11: error: ‘exit’ was not declared in this scope
make[1]: *** [../src/libSU2_a-linear_solvers_structure.o] Error 1

I successfully compiled / ran version 2.0.2 from the tarball on this system before you guys went to git (thanks for doing that btw).


jstults August 28, 2013 20:31

Works a treat; thanks!


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