Jump to: navigation, search

When I compile DOCK, I get something like the following error:

g++ -c -DBUILD_DOCK_WITH_MPI -DMPICH_IGNORE_CXX_SEEK -I/include -O2 -o amber_typer.o amber_typer.cpp In file included from /usr/include/mpi.h:1081, from dock.h:28, from amber_typer.cpp:1: /usr/include/mpi++.h:1473: error: syntax error before numeric constant

What is causing the error and how do I fix it?

This error is due to an incompatibility between the configuration of the MPICH2 installation and the configuration of DOCK 6. Because DOCK 6 does not use the MPI C++ bindings, this issue can be avoided by defining the macro MPICH_SKIP_MPICXX. This can be done on the command line via: make -e DOCKBUILDFLAGS='-DMPICH_SKIP_MPICXX' or by modifying the DOCK 6 configuration file config.h directly via an addition to the macro CFLAGS, e.g., CFLAGS= -DBUILD_DOCK_WITH_MPI -DMPICH_IGNORE_CXX_SEEK -DMPICH_SKIP_MPICXX -I$(MPICH_HOME)/include -O2. See MPI C++ Bindings for background information. Note that DOCK 6 does use some MPI C bindings and does not use any MPI Fortran bindings.