'''''EMAN''''' depend on some third party libraries: Some dependency libraries are mandatory, like [[http://www.fftw.org/|fftw2]], [[http://www.gnu.org/software/gsl/|gsl]], and [[http://www.cmake.org/HTML/Index.html|cmake]] for eman compilation. Some others are optional, like [[http://www.boost.org/|boost.python]], [[http://www.python.org/|Python]] if you need run Pyhton program in EMAN or want to program in Python with EMAN, you can turn this option off by switching ENABLE_PYTHON to off. And [[http://www.libpng.org/pub/png/libpng.html|png]], [[http://www.libtiff.org/|tiff]], and [[http://www.jpeg.org/|jpeg]] for extra image format support. They can be controlled by flag ENABLE_TIF and ENABLE_PNG in ccmake. [[http://www.trolltech.com/developer/downloads/qt/index|Qt]] library is necessary for EMAN’s GUI programs, if you don’t need GUI program, you can turn off the flag ENABLE_GUI. For hdf5 image support, you need [[http://www.hdfgroup.org/HDF5/|HDF5]] library, this can also be switched off by flag ENABLE_HDF. Also [[http://www.perl.org/|perl ]]is needed for EMAN's help documentation generation. I will talk more about those compilation flag later. For all these libraries, you can either install them through your Linux system’s package management, or compile them from source. For your convenience, we provide source code package download link for all these dependencies on our [[http://blake.bcm.tmc.edu/eman/eman1/|EMAN download site]]. The packages are the newest package tested compatible for EMAN compilation. If you don’t know which dependency library are missing on your system. You can start with installation of cmake. The typical directory structure to compile EMAN is like this, all source code of EMAN stay in ~/EMAN/src/eman directory. You make a new directory build as ~/EMAN/src/build. In this build directory, type ccmake ../eman. Type ‘c’, then you will see the configuration screen for EMAN. If you type ‘t’ you can toggle to advanced mode. Except the previous introduced flags to control optional dependency package support, we have some more flags: * ENABLE_ATHLON: optimize EMAN compilation for 32 bit athlon cpu; * ENABLE_OPTERON: optimized EMAN compilation for 64 bit athlon_64 or opteron cpu; * ENABLE_CHIULAB: used to compile some code specific to Dr. Wah Chiu’s lab; * ENABLE_CLUSTER: compile EMAN for cluster use. * ENABLE_DEBUG: turn the debug compilation flag on, and compile some more code used for debugging; * ENABLE_FILELOCK: this will enforce file locking before writing; * ENABLE_SZLIB: this is necessary for HDF5 support on EMAN windows compilation. * ENABLE_STATIC: this is for build some application with static library built in. * ENABLE_STATIC_QT: this is for build semi-static EMAN, i.e. link qt library statically into libqEM.so. In the CCMAKE screen, you can type ‘c’ for configure, cmake will search through some system default directory for all dependency libraries. If it return with a page said some header or libraries missing, perhaps your system is missing some libraries. As I said, you can either installed these missing libraries through your system’s package management or compile them from source. After you resolve all the dependencies, you can type ‘c’ to configure then type ‘g’ to generate a makefile, this will also quit from cmake, now in your build directory, you need type ‘make’ then ‘make install’ to finish EMAN building. After 'make install', in the /EMAN directory, except the src directory, you have six more directories: * /bin: all the EMAN executable programs; * /chimeraext: EMAN extension for Chimera; * /doc: all EMAN document files; * /include: EMAN C++ header files; * /lib: EMAN libraries, EMAN executable programs are dependent on these shared libraries; * /python: some EMAN Python programs. Now you need setup three environmental variables to make your EMAN functional, you could add these lines into your .bashrc or .bash_profile (I use my home directory and BASH shell as an example, you can do accordingly in C Shell): * export EMANDIR=/home/gtang/EMAN * export PATH=${EMANDIR}/bin:${PATH} * export LD_LIBRARY_PATH=${EMANDIR}/lib:${LD_LIBRARY_PATH} * export PYTHONPATH==${EMANDIR}/lib:${PYTHONPATH} You can do several simple tests to make sure your EMAN compilation is basically successful: 1. run ‘speedtest’, it should return you a score to tell you haw fast your CPU is; 1. If you set ENABLE_GUI to on, run ‘eman’, an GUI program will pop up; 1. If you set ENABLE_GUI to on, run ‘proc2d help’, a window will pop up with help to refine command, you can get help by this way for all other command; 1. If you set ENABLE_PYHTON to on, open a Python window, type ‘import EMAN’, this should return with no error. Congratulations, you have successfully compiled EMAN!