Hi Luca,
> This would be ok, except that compilation now is terribly slow... :-)
Yes, linking with static libs is a pain :-] I found it to be particularly
painstaking if the file system one is working on is an NFS mount. You may
want to consider changing your Makefile so that it links on a local /tmp
directory and copies the final result to its destination...
> Now, from the above error, it seems that libbase.g.a is not included. I
> removed the @ in front of the link line, and indeed libbase.g.a is
> there. I added the option -lbase.g and the program now compiles and run
> fine. Is this something strange with my setting, or am I missing
> something?
Can you post the complete linker line? The position of libraries within the
command line is important (the linker links left to right). This can
sometimes be hidden from view for shared libs, but is always the case for
static libs. So libbase always needs to come last on the line, after all
the other libraries and your own object files.
Cheers
W.
PS: With Trilinos, I had a similar problem just this week. One of the
Trilinos BLAS wrappers reported a relocation when linked into a shared lib
which is only possible if the file is compiled with -fPIC but it wasn't.
The solution was to do
export FFLAGS=-fPIC
export CFLAGS=-fPIC
export CXXFLAGS=-fPIC
./configure ..... --enable-shared
make
After this, everything worked just fine.
-------------------------------------------------------------------------
Wolfgang Bangerth email: [EMAIL PROTECTED]
www: http://www.math.tamu.edu/~bangerth/
_______________________________________________