Dear All,
I am trying to compile a software package written in C++ in my
ALPHA 433 with OSF1 V4.0D using g++ (version 2.8.1). I have
successfully compiled the same programs in a silicon graphics box
(IRIX 6.5) and in a SUN box (solaris 2.4) using the very same
version of the gnu compiler. Now, when I compile the programs in
the OSF box I get some "undefined symbol" errors.
As far as I understand the problem (my knowledge of C++ is very
limited, so if the following description sounds a bit bizarre
please forgive me) the error came from the fact that some
class/functions are defined using templates. As compilers are very
smart they do not generate real code (something executable in a .o
file) for a given function if it is not explicitly called. The very
first thing this package does is to create a shared library. To
force the compiler to create the code there is one file that
explicitly calls all the functions generated using templates. My
guess is that the alpha linker (in its default configuration) does
not like this trick.
Can anyone suggest any solution for this problem? Any comment will be well
come
cheers
Roberto
Received on Fri Sep 10 1999 - 18:10:49 NZST