-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
Description
If you get errors on linking such as
/home/..../Library/Gromacs/versions/serial-4.5.5/lib/libgmx.a(vmddlopen.o): In function `vmddlclose': vmddlopen.c:(.text+0x1): undefined reference to `dlclose'
...
/home/..../Library/Gromacs/versions/serial-4.5.5/lib/libgmx.a(pthreads.o): In function `tMPI_Thread_key_delete': pthreads.c:(.text+0x5e6): undefined reference to `pthread_key_delete'
then that means that you have to add additional options to the CPPFLAG and especially LDFLAG variables in the Makefile:
- add -pthread
- add the dl library
The lines in the Makefile are:
CPPFLAGS += -I$(INCLUDEDIR) -I$(GMX_INCLUDE_DIR) -pthread
LDFLAGS += -pthread -lm -ldl -L$(GMX_LIB_DIR) -lmd -lgmx