160 likes | 253 Views
Installing CompuCell3D from source. Why you might want to install from source? There are no binaries for your platform (e.g. gentoo linux) You want to develop new modules You want to have latest version of CompuCell3D (we do not post new binaries as often as we do with source code)
E N D
Installing CompuCell3D from source. • Why you might want to install from source? • There are no binaries for your platform (e.g. gentoo linux) • You want to develop new modules • You want to have latest version of CompuCell3D (we do not post new binaries as often as we do with source code) • You want to run CompuCell3D on a cluster where programs are installed in non-standard locations • The install script does not work properly (this is especially true if the dependencies are installed in non-standard locations. We will work in the future to improve installation script so that it will be more robust)
Unpack CompuCell3D package and inside CompuCell3D_3.1.6 directory create “binary” directory. This is where all the compilation objects will be stored. This way your source code tree will not be contaminated at all with various generated files (like object files). Go to binary directory and open up cmake interface – “ccmake ..”
We got an error. Permission denied to write to ‘/usr/local’. Let’s see what we should change in the settinggs. Hit ’e’ Error
The error is quite simple to fix. We were trying to install CompuCell3D into /usr/local directory to which we did not have permission. All we need to do is to change CompuCell3D installation directory. Installation directory Pay attention to what is being displayed at the CMake toolbar
The new installation directory will be called : “/home/mswat/CompuCell3D_Qt4_3.1.16_install” New installation directory Let’s hit ‘c’ to reconfigure CompuCell3D with the new installation directory
NO error messages this time. Everything went OK. Let’s exit message printout screen by hitting ‘e’
Once configuration is done we should generate makefiles. Notice, new option ‘g’ has appeared. When you press ‘g’ the makefiles will be generated IMPORTANT: sometimes you need to configure project (hit ‘c’) several times before generate option (’g’) will become available. This is normal and quite common with complex projects.
After pressing ‘g’ CMake generates makefiles and exits to the console.
After few minutes we are done. Binary packages install faster but you do not get as much excitement as you do when building from source. Oh, forgot to tell you, before attempting build from source, make sure you have pack of tranquilizers handy…
All we need to do now is finish the installation by typing “make install” Now, you can go to installation directory and start using CompuCell3D.
Sometimes, the installation will not go as smoothly as before because e.g. dependencies are installed in non-standard locations and CMake might have troubles locating them. Let’s see example below CMake could not find swig and xercesc. We need to set the paths manually…
This is quite easy to do. Well, provided you know the location of dependencies. The example presented here shows how to install CompuCell3D on a 1000 processor cluster BIgRed owned and administered by IU. The locations of dependencies are truly non-standard, but as you can see even in this situation we can easily instruct CMake to generate correct makefiles
After configuring the package (remember , you need to hit ‘c’ once or more) we can generate makefiles (press ‘g’)