From: <an...@tn...> - 2003-11-13 02:40:32
|
Hi After some more hours of trying to find obscure linker problems, I finally got libmesh working together with Petsc 2.1.6. on linux/gcc 3.3 (single processor, using MPIUNI). To make this happen I had to do the following hacks: o in libmesh.C: comment out the lines containing calls to MPI_Finalize. MPI_Finalize gave me some strange linker errors (running the examples), as it is defined in libmpiuni.a > nm -C lib/i686-pc-linux-gnu_opt/libmesh.so |grep MPI_Finalize > U Petsc_MPI_Finalize() note the parentheses which do not appear using nm on libmpiuni.a I had a similar error with calls to MPIUNI_Memcpy, which went away as I updated the cvs some hour ago. o I have to comment out all calls to CHKERRQ(ierr) in the files petsc-matrix.C, .... and in the header files. The reason for this is that CHKERRQ wants to leave the *calling function* with an error code. Since calls to CHKERRQ are made in functions declared as void, this causes a compiler error: > error: return-statement with a value, in function declared with a > void return type Alternatively, I could redeclare all functions with calls to CHKERRQ with an int return type. I have no clue which method is better. o The file sfcurves.h is not found in the correct place, I have to copy it to include. Wow, I am glad this finally works. Hopefully somebody can come up with a less hacky solution. Best, Martin |