FAQ:mmolex

From DISI
Jump to: navigation, search

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

g++ -O2 -o dock6 amber_typer.o base_mpi.o base_score.o conf_gen.o dock.o dockmol.o library_file.o master_score.o orient.o score.o simplex.o utils.o score_solvent.o score_amber.o sasa.o score_chemgrid.o nab/nab.a -lm -lpthread ld: Undefined symbols: _mmolex make: *** [dock6] Error 1

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

DOCK 6 requires a lexical analyzer generator; example Unix command names are lex and flex. All classical Unices have lex. Linuces usually have flex. But this undefined symbol is caused by a missing lexical analyzer generator. (It may be that some users are not installing enough of their Linux.) In particular, dock6/src/dock/nab/lex.mm_options.c either will not exist or will have a size of zero if a lexical analyzer generator is missing.

Here are some suggestions:

  • Verify that dock6/src/dock/nab/lex.mm_options.c is broken or missing.
  • Look for a lexical analyzer generator on your machine.
  • Verify the definition of the macro LEX in the configuration file, dock6/install/config.h; LEX should be assigned the name of your lexical analyzer generator.
  • Install a lexical analyzer generator if one is not found. flex: The Fast Lexical Analyzer is free software.
  • Try our dock6/src/dock/nab/lex.mm_options.c:
  • Change directory to dock6/src/dock/nab and execute make clean. Download lex.mm_options.c. (This file was generated by flex version 2.5.4 on Red Hat Enterprise Linux AS release 3 (Taroon Update 6).) Copy it to dock6/src/dock/nab/lex.mm_options.c. Edit dock6/install/config.h and make the LEX definition equal to flex, i.e LEX= flex. Restart the installation: cd install; make install