gmpxx and Creator problem
I'm on Linux, trying to use gmpxx and Qt, I have no problems using gmpxx outside of Qt.
in pro file I add :
LIBS += -lgmpxx
Code is very simple :
#include <gmpxx.h> mpz_class a, b;
:-1: error: mainwindow.o: undefined reference to symbol '__gmp_get_memory_functions' /usr/lib64/libgmp.so.10:-1: error: error adding symbols: DSO missing from command line :-1: error: collect2: error: ld returned 1 exit status
I'm lost, can anyone help with this ?
It cant find the gmpxx lib/so file
You need to tell what folder
It can find it, in the error you can see the path to the libgmp
Anyway, even when path specified error stays the same.
I've use 3rd party libs before and had no problems, this one is for some reason special.
Just solved it, trick is to add -lgmp as well, weird but ok :)
so the so was named (lib)gmp?
It was my mistake, been awhile since I've used gmp, I actually had to include both libs when I was linking outside of QT, so it has nothing to do with QT, for some reason I thought that gmpxx is just enough and I completely forgot about adding gmp as well.