
Elena Fersman wrote:
I have downloaded the latest release version of the library (0.5). I do not have problems with compiling the library. But when i try to compile the following program: #include"ppl.hh" main(void){}
with the command gcc file.c -lgmp -lgmpxx -lppl
i am getting lots of syntax errors.
Dear Elena,
it is now quite clear why you are getting lots of compilation errors. If you name a file "file.c" and use the command "gcc" to compile it, then the compiler interprets the file as a C program. The include file "ppl.hh" is the include file for the C++ interface of the library.
There are thus two possibilities:
1) You want to use the C++ interface: then include, as you are doing, "ppl.hh" but name your source "file.cc" and/or use the "g++" command instead of "gcc".
2) You want to use the C interface: then include "ppl_c.h" instead of "ppl.hh" and you are done.
Compilation of test programs with make test goes well, but there are too many compilation options. Could you please help me with the minimal example to start using the library?
Your program is the minimal program using the library, even though it does nothing. Just compile it with g++ using the same options you are giving to gcc and it should be OK. More interesting examples are given in the documentation and, as I said, the tests subdirectory is full of examples you can adapt. I am now writing from an uncomfortable environment, but I can send you something if you still have problems once I am back from the conference. All the best,
Roberto
-- Prof. Roberto Bagnara Computer Science Group Department of Mathematics, University of Parma, Italy http://www.cs.unipr.it/~bagnara/ mailto:bagnara@cs.unipr.it