
Remko Troncon wrote:
As promised, i looked at PPL 0.2. I am experiencing some troubles compiling a very small test file against PPL though. Something goes wrong when g++ tries to link my file. I have attached the test program and the message log. Maybe you can tell me what i'm doing wrong ?
Dear Remko,
the first thing that comes to mind is that you may have compiled the PPL library with one compiler (e.g., g++-2.96.98) and the program test.cpp with another one (e.g., g++-3.0.3). I say this because your link command starts with `g++-3.0', whereas the configuration and compilation mechanism of the PPL has probably invoked `g++'.
In an attempt to reproduce the problem, I have tried the following:
tar zxf ppl-0.2.tar.gz cd ppl-0.2 ./configure --prefix=/usr/local/ppl make su <pwd> make install exit cd .. g++ -I/usr/local/ppl/include -c test.cpp g++ -L/usr/local/ppl/lib -L/usr/local/gmp/lib test.o -o t -lgmp -lppl t <output follows> -A + B >= 0 -B >= -10 B >= 0 A >= 0
On my system, g++ _is_ g++-3.0.3 so that the library and test.cpp have been compiled with the same compiler. I have also tried compiling the PPL with a pre-3 version of the compiler and the errors I get are similar to yours (though not identical). Can you please try the commands `g++-3.0 -v' and `g++ -v'? If the outputs are different that may be the problem (the ABI of g++-3.x is not backward compatible with previous versions).
If the above diagnosis makes sense, you can overcome the problem by adding `--with-cxx=g++-3.0' to the configure options for the PPL. If my diagnosis does not make sense, please come back to us. All the best
Roberto