Project

General

Profile

Install » History » Revision 155

Revision 154 (Rogers, Chris, 05 June 2013 07:56) → Revision 155/204 (Rajaram, Durga, 19 June 2013 17:41)

{{toc}} 

 h1. Introduction 

 This page will take you through getting the prerequisites of installing MAUS and ensuring that it's working.   

 If you have issue, please file a new support ticket by clicking "new issue" above.    Below are some common known problems: 

 * Do not have whitespace in your path. Various third_party packages will break.    This is beyond the scope of MAUS.    See issue #306. 
 * If you are at RAL you will need to setup the RAL proxy. Please run +export http_proxy=wwwcache.rl.ac.uk:8080+ (or equivalent) 

 h1. Supported Distributions 

 We support recent versions of 
 * Scientific Linux 
 * CENT OS 

 Other Linux distributions are supported on a "best effort" basis. 

 h1. Prerequisites 

 _Most installation problems are a result of people not reading this section_ 

 You will need a few GBs of free space on your harddrive for Geant4 and ROOT (which will be installed along with MAUS). 

 You will also need a number of prerequisite tools for the software to build and run correctly, such as X11.    To be sure that your system has the correct setup, follow the instructions that relate to your system in the following sections. 

 h2. Scientific Linux/Redhat/Fedora/Centos 

 To install the tools required to build software on Scientific Linux, you must run the following commands: 

 <pre> 
 sudo yum groupinstall "Development Tools" 
 sudo yum groupinstall "Development Libraries" 
 sudo yum install wget libX11-devel libXft-devel libXext-devel libXpm-devel libX11-devel libpng-devel tcl-dev tk-dev sqlite3_dev 
 </pre> 

 where the *sudo* command means that this is run as the root superuser. If you do not have this access, you must ask your system manager. 

 > *Scientific Linux 4.8 only*. Please also run: 
 >  
 > <pre>sudo yum install xorg-x11-devel</pre> 

 > *Optional - for Geant4.9.5.p01*. Please also run: 
 >  
 > <pre>sudo yum install cmake</pre> 

 h2. Debian or Ubuntu 

 To install the tools required to build software on Debian-based systems, you must run the following commands: 

 <pre> 
 sudo apt-get install build-essential xorg-dev automake autoconf libtool scons zlibc libssl-dev libblas-dev liblapack-dev libpng-dev 
 </pre> 

 where the *sudo* command means that this is run as the root superuser.    If you do not have this access, you must ask your system manager. 

 > *Optional - for Geant4.9.5.p01*. Please also run: 
 >  
 > <pre>sudo yum install cmake</pre> 

 > _*RAL ONLY*. For RAL people, you need to create a file called /etc/apt/apt.conf and fill it with:_ 
 >  
 > <pre> 
 ACQUIRE 
 { 
 http::proxy "http://wwwcache.rl.ac.uk:8080/"; 
 } 
 </pre> 

 h2. OpenSUSE 

 To install the required tools, you must run the following command: 

 <pre> 
 sudo zypper install -t pattern devel_C_C++ 
 </pre> 

 where the *sudo* command means that this is run as the root superuser.    If you do not have this access, you must ask your system manager. 

 h2. Fedora 

 Remove Canopy if you have it installed. It causes conflicts with the default freetype (Ref. #1291). 

 h2. Other distribution 

 Please try using "google":http://www.google.com to find out how to do it for your specific architecture.    If you succeed, then please post those instruction here and continue with these instructions.    If you fail, please email the user mailing list (maus-user@jiscmail.ac.uk). 

 h1. Getting the code 

 There are three options for obtaining code. 

 h2. Using a packaged tarball 

 Just get the "latest release":http://micewww.pp.rl.ac.uk/maus/MAUS_latest_version/maus.tar.gz or choose a version from the    "release page":http://micewww.pp.rl.ac.uk/maus/ and click on the Source Code tarball link. You may wish to check that the download was okay, for instance by doing 
 <pre> 
 md5sum -c maus.tar.gz.md5 
 </pre> 

 where @maus.tar.gz.md5@ can be found either by following the _md5_ link or, for the latest release, clicking "here":http://micewww.pp.rl.ac.uk/maus/MAUS_latest_version/maus.tar.gz.md5. Then extract the code by doing 
 <pre> 
 tar xvfz maus.tar.gz 
 </pre> 
 You should now have a directory called 'maus'. 

 h2. Bazaar repository (recommended for developers) 

 The following command checks out the current source tree for MAUS that is under development.    This code branch contains the biweekly stable release. 

 Bazaar (bzr) is the program we use to maintain the repository. There is a MAUS-specific tutorial of using bzr [[Bzr_usage|here]]. Please "branch":http://en.wikipedia.org/wiki/Branching_%28software%29 MAUS.    The code is hosted on "launchpad":http://launchpad.net under the "MAUS project":https://code.launchpad.net/maus.    To get the code, you must then run: 

 <pre> 
 bzr branch lp:maus 
 </pre> 

 and you should now have a directory called 'maus'.    If you get a 'command not found', you must [[InstallingBzr|install bazaar]].    If you run into connectivity issues, you can check the bazaar server status "here":http://identi.ca/launchpadstatus. 

 *If you want to publish results based on MAUS, please use a release version of the code*. 

 h1. Dependencies and building MAUS 

 MAUS will try to help you by installing all of its dependencies for you.   

 * Be careful about using symbolic links to move to this directory prior to installation, as this may confuse the build system. Always try to follow an absolute path instead. 
 * If running remotely, you may need to forward X11 connections (use ssh -X or ssh -Y) 

 You can now run the following command to build all your dependencies, build MAUS, and run the tests for you (*this takes about 1 hour for most machines, and 3 hours for VMs!*): 

 <pre> 
 cd maus 
 ./install_build_test.bash 
 </pre> 

 The build output is automatically stored in a log file like @./install_log_std@. Some of the tests check that errors are handled correctly, so we expect some error messages. The tests should end with a line like: 

 <pre> 
 Ran 79 tests in 251.375s 

 OK (SKIP=20) 
 </pre> 

 Sometimes the test script may skip some tests because a certain library was not available. A test failure looks like 

 <pre> 
 Ran 79 tests in 251.375s 

 FAILED (errors=1, failures=1) 
 </pre> 

 If you run into issues, please send the output of: 

 <pre> 
 bash run_tests.bash 
 </pre> 

 to us through an issue by clicking 'New Issue' above. 

 If you are installing multiple copies of maus on the same machine, it is possible to set them to all use the same set of third party libraries, cutting down the installation time to approximately 10 minutes for each extra installation.    After setting up the first installation as above, use same command as before but add an argument specifying the root directory of the first maus installation: 

 <pre> 
 ./install_build_test.bash /path/to/original/maus 
 </pre> 

 NB: Make sure that you only do this for installations that use the _same version_ of the third party libraries. 

 You are now ready to run MAUS! 

 h3. Troubleshooting 

 If you aren't sure, a sample @install.log@ can be found "here":http://micewww.pp.rl.ac.uk/maus/MAUS_latest_version/install.log 

 * *I get errors in the test output*: this is normal - if the tests finish with a line like *OK*, then the tests passed. If the tests finish with a line like *FAILED (errors=1, failures=1)* (or worse a segmentation fault), then the tests failed. Some of the tests are actually checking that errors are produced on bad input. Sample output for the installer are available. 
 * *MAUS does not import* - are you using a symbolic link?    See #770 
 * *I get a message like FATAL: Failed to install python module matplotlib* and then some more error messages - you may need to forward X11 connections to install matplotlib. See #1246 
 * *I get an error about Python versions when I run ./configure*: this is normal - you need to install third party libraries (including python 2.7) by doing <pre>bash ${MAUS_ROOT_DIR}/third_party/build_all.bash</pre> Better to just follow the install instructions above. 

 h1. Other useful libraries/applications 

 MAUS doesn't require these libraries to build or run, but they may provide useful functionality for documentation, installation, etc 

 h2. Rebuilding with Geant4.9.5 

 MAUS comes prepacked with a script to build against geant4.9.5.p01. In order to build against geant4.9.5, please use the following script: 

 <pre> 
 bash third_party/install_build_test_geant4.9.5.p01.bash 
 source env.sh 
 source env_geant4.9.5.p01.sh 
 </pre> 

 Note this is an experimental feature - however it is regularly tested against a scientific linux build "here":http://test.mice.rl.ac.uk/view/Trunk/job/MAUS_geant4.9.5.p01/ 

 h2. Documentation 

 To build the documentation, you will need 

 * *doxygen* automatic code documentation tool "website":www.doxygen.org/ 
 * *latex* typesetting tool "website":www.latex-project.org/ 
 * *latex2html* for making html documents "website":http://www.latex2html.org/ 
 * *graphviz* (dot) for making class layouts, etc "website":http://www.graphviz.org/ "documentation":http://www.graphviz.org/Documentation/dotguide.pdf  

 h2. Visualisation 

 We use @vrml@ as our default visualisation format. There are a number of viewers that may or may not work for viewing VRML files. 

 * Scientific Linux: If you have a VRML viewer that works in SL, please email the developers. 
 * Ubuntu: Try "paraview":http://www.paraview.org/ 
 <pre> 
 sudo apt-get install paraview 
 /usr/bin/paraview g4_00.wrl 
 click on eye icon in left menu bar 
 </pre> 
 * Windows: Try "Instant Player":http://www.instantreality.org/downloads/ or "FreeWRL":http://freewrl.sourceforge.net/ 
 * Other: There are a few options listed in #1250 

 h2. Other Stuff 

 * *lcov* C++ code coverage tool (activated by maus_lcov environment variable) 
 * *bzr* for accessing the repository. As easy as  
 <pre>source env.sh 
 easy_install bzr</pre> 
 In ubuntu you may also need to do  
 <pre> 
 sudo apt-get install libbz2-dev 
 </pre> 
 which apparently doesn't come by default.