Linking Static Library to PETSc code

Satish Balay balay at
Fri Nov 16 12:10:49 CST 2007

On Fri, 16 Nov 2007, Mads Hoel wrote:

> On Fri, 16 Nov 2007 16:12:15 +0100, Tim Stitt <timothy.stitt at> wrote:
> > could not read symbols: Bad value
> I haven't seen that error message before, but i looked it up in a search
> engine and got 4 cases that might be the solution to your problem, suggesting
> to recompile the static library with -fPIC:

Can you post the complete log [compiler, compiler options etc..] of:

- how this static library was built
- how you are attempting to link it with PETSc
-complete error message

Also is this linux or linux64?

This additional info could give us clues as to whats going wrong.


More information about the petsc-users mailing list