pdf.cpp.text+0xb7): undefined reference to `HPDF_New'
pdf.cpp.text+0xf9): undefined reference to `HPDF_Free'
pdf.cpp.text+0x10f): undefined reference to `HPDF_AddPage'
.....
------------------------------------------------------------------------------------------
ok, eventually i compiled it with "gcc pdf.cpp -lhpdf -lpng -lz -lm"
but now it says:
./a.out: error while loading shared libraries: libhpdf-2.2.1.so: cannot open shared object file: No such file or directory
even after i copied this file into current dir((
Last edited by Igor Yalovecky; December 2nd, 2011 at 04:20 AM.
"cannot open shared object file: No such file or directory" means you have to copy libhpdf-2.2.1.so in a directory that is listed in the PATH environment variable.
Last edited by olivthill2; December 2nd, 2011 at 04:26 AM.
"cannot open shared object file: No such file or directory" means you have to copy libhpdf-2.2.1.so in a directory that is listed in the PATH environment variable.
Great thanks! I found next command to ran it:
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib ; export LD_LIBRARY_PATH
but what is -lhpdf. is it some system name for library or some kind of shorcut?
Re: libharu, how to compile (undefined reference to)
what is -lhpdf?
-l means, you use a library
hpdf is the name of the library where its extension (characters after the ".") and its first three characters "lib" have been removed, in order to gain some valuable space on the command which used to be quite short in prehistorical times.
Bookmarks