Basically I'm compiling step-18.cc using codeblocks which is an IDE. I've had no problems with steps 1-5 but I skipped to 18 and this happened. I tried installing
the petsc library and linking with the lib file.
My current files for linking are,
../../../../../../usr/lib/petsc/lib/libg/libpetsc.a
../../../../../../usr/lib/petsc/lib/libO_c++/libpetsc.so
libdeal_II.so
libtbb.so
libtbb_debug.so
libz.a
and my linker option is,
-lz
I have petsc installed with the include files in the include directory, the same as stl and deal.ii and I get the errors above. Please help. thanks.
Documents/deal2/deal2.18/step-18/step-18.cc|692|error: ‘PETScWrappers’ does not name a type|
Documents/deal2/deal2.18/step-18/step-18.cc|694|error: ‘PETScWrappers’ does not name a type|
Documents/deal2/deal2.18/step-18/step-18.cc|696|error: ‘PETScWrappers’ does not name a type|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::setup_system()’:|
Documents/deal2/deal2.18/step-18/step-18.cc|1413|error: ‘system_matrix’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1436|error: ‘system_rhs’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1437|error: ‘incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::assemble_system()’:|
Documents/deal2/deal2.18/step-18/step-18.cc|1471|error: ‘system_rhs’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1472|error: ‘system_matrix’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1700|error: ‘PETScWrappers’ has not been declared|
Documents/deal2/deal2.18/step-18/step-18.cc|1700|error: expected ‘;’ before ‘tmp’|
Documents/deal2/deal2.18/step-18/step-18.cc|1703|error: ‘tmp’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1705|error: ‘incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::solve_timestep()’:|
Documents/deal2/deal2.18/step-18/step-18.cc|1722|error: ‘system_rhs’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘unsigned int Step18::TopLevel<dim>::solve_linear_problem()’:|
Documents/deal2/deal2.18/step-18/step-18.cc|1768|error: ‘PETScWrappers’ has not been declared|
Documents/deal2/deal2.18/step-18/step-18.cc|1769|error: expected ‘;’ before ‘distributed_incremental_displacement’|
Documents/deal2/deal2.18/step-18/step-18.cc|1772|error: ‘distributed_incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1772|error: ‘incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1774|error: ‘SolverControl’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1774|error: expected ‘;’ before ‘solver_control’|
Documents/deal2/deal2.18/step-18/step-18.cc|1776|error: ‘PETScWrappers’ has not been declared|
Documents/deal2/deal2.18/step-18/step-18.cc|1776|error: expected ‘;’ before ‘cg’|
Documents/deal2/deal2.18/step-18/step-18.cc|1779|error: ‘PETScWrappers’ has not been declared|
Documents/deal2/deal2.18/step-18/step-18.cc|1779|error: expected ‘;’ before ‘preconditioner’|
Documents/deal2/deal2.18/step-18/step-18.cc|1781|error: ‘cg’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1781|error: ‘system_matrix’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1781|error: ‘system_rhs’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1782|error: ‘preconditioner’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|1788|error: ‘solver_control’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::output_results() const’:|
Documents/deal2/deal2.18/step-18/step-18.cc|1948|error: ‘incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::refine_initial_grid()’:|
Documents/deal2/deal2.18/step-18/step-18.cc|2251|error: ‘incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|2264|error: ‘PETScWrappers’ has not been declared|
Documents/deal2/deal2.18/step-18/step-18.cc|2265|error: expected ‘;’ before ‘distributed_error_per_cell’|
Documents/deal2/deal2.18/step-18/step-18.cc|2271|error: there are no arguments to ‘distributed_error_per_cell’ that depend on a template parameter, so a declaration of ‘distributed_error_per_cell’ must be available [-fpermissive]|
Documents/deal2/deal2.18/step-18/step-18.cc|2271|note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)|
Documents/deal2/deal2.18/step-18/step-18.cc|2272|error: ‘distributed_error_per_cell’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::update_quadrature_point_history()’:|
Documents/deal2/deal2.18/step-18/step-18.cc|2713|error: ‘incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In function ‘int main(int, char**)’:|
Documents/deal2/deal2.18/step-18/step-18.cc|2825|error: ‘PetscInitialize’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc|2834|error: ‘PetscFinalize’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::refine_initial_grid() [with int dim = 3]’:|
Documents/deal2/deal2.18/step-18/step-18.cc:2171|4|instantiated from ‘void Step18::TopLevel<dim>::do_initial_timestep() [with int dim = 3]’|
Documents/deal2/deal2.18/step-18/step-18.cc:1068|5|instantiated from ‘void Step18::TopLevel<dim>::run() [with int dim = 3]’|
Documents/deal2/deal2.18/step-18/step-18.cc:2831|30|instantiated from here|
Documents/deal2/deal2.18/step-18/step-18.cc|2271|error: ‘distributed_error_per_cell’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc:2171|4|instantiated from ‘void Step18::TopLevel<dim>::do_initial_timestep() [with int dim = 3]’|
Documents/deal2/deal2.18/step-18/step-18.cc:1068|5|instantiated from ‘void Step18::TopLevel<dim>::run() [with int dim = 3]’|
Documents/deal2/deal2.18/step-18/step-18.cc:2831|30|instantiated from here|
Documents/deal2/deal2.18/step-18/step-18.cc|2261|warning: unused variable ‘n_local_cells’ [-Wunused-variable]|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘void Step18::TopLevel<dim>::move_mesh() [with int dim = 3]’:|
Documents/deal2/deal2.18/step-18/step-18.cc:2196|5|instantiated from ‘void Step18::TopLevel<dim>::do_initial_timestep() [with int dim = 3]’|
Documents/deal2/deal2.18/step-18/step-18.cc:1068|5|instantiated from ‘void Step18::TopLevel<dim>::run() [with int dim = 3]’|
Documents/deal2/deal2.18/step-18/step-18.cc:2831|30|instantiated from here|
Documents/deal2/deal2.18/step-18/step-18.cc|2443|error: ‘incremental_displacement’ was not declared in this scope|
Documents/deal2/deal2.18/step-18/step-18.cc||In member function ‘unsigned int Step18::TopLevel<dim>::solve_linear_problem() [with int dim = 3]’:|
Documents/deal2/deal2.18/step-18/step-18.cc|1789|warning: control reaches end of non-void function [-Wreturn-type]|
||=== Build finished: 40 errors, 2 warnings ===|
checking for PETSc library directory... not found
checking for SLEPc include directory... not found
checking for Trilinos directory... not found
checking for Trilinos header directory... not found
checking for Trilinos library directory... not found
I'm trying to configure the deal.ii folder in the desktop directory, could that be why or is there no difference
where its configured?
Even my synaptic package manager says petsc is installed. I'm also trying to install slepc and trilinos and I'm typing.
--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en
--with-shared-libraries=1 instead of --with-shared=1.) Finally build the libraries with"----- Original Message -----From: Andrew SomorjaiSent: Thursday, November 08, 2012 5:26 AMSubject: Re: [deal.II] error: 'PETScWrappers' does not name a type|
----- Original Message -----From: Andrew SomorjaiSent: Thursday, November 08, 2012 10:41 PMSubject: Re: [deal.II] error: 'PETScWrappers' does not name a type|