[gmx-users] help needed for using xdr library
harryhuangkun at gmail.com
Mon Aug 17 15:41:41 CEST 2009
Recently I am trying to use the xdr library downloaded from gromacs org to
read xtc files. However when I link my program with the library there is an
error. When I ran the make test, all the tests were passed. Thus I think
that the library should work just I don't know how to link the program. I
tried to read the makefile in the library but it is very
complicated and beyond my scope. My program is very simple:
//source file of cm.cc
char * fn="fdifal";
and I could compile it. When I use
g++ cm.o /home/kun/xdr/lib/libxdrfile.a there is a link error:
cm.o: In function `main':
cm.cc:(.text+0x2d): undefined reference to `read_xtc_natoms(char*, int*)'
collect2: ld returned 1 exit status
Could anyone help me?
Thank you very much.
Have a nice weekends
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the gromacs.org_gmx-users