G4beamline on Linux (Intel) Before installing G4beamline, you should first install: Root - http://root.cern.ch Select "Download Binaries, and download their production version. Any recent version of Root should work; 5.12 and 5.14 have been tested. Be sure the ROOTSYS variable is set in the environment (best done in your .profile or .bash_profile). Really only necessary to run historoot, G4beamline itself does not need Root installed. mesa-libGL -- should be available in your Linux distribution. This is also known as OpenGL. tcl - should be available in your Linux distribution. Required by most of the tests, but g4beamline itself will run without it. java - http://java.sun.com Required only for g4blgui. Select "Java SE", and all you need is the Java Runtime Environment (JRE); get the latest. If you have installed the development kit (JDK) that includes the JRE. To install G4beamline, download the tarball and un-tar it in your HOME directory: tar -xzf g4beamline-1.14-Linux-g++.tgz this will create a directory $HOME/g4beamline-1.14-Linux-g++. You need to put the G4beamline programs into your PATH. The simplest way to do this is: cd g4beamline-1.14-Linux-g++ ./setup The setup script will guide you through the process. You can also do it manually. Once g4beamline has been put into your PATH, to run G4beamline simply do: g4bl input.file [name=value [...]] The default format for NTuples is now Root. To create histograms from NTuples you can use Root in the usual way. That is rather complicated and un-obvious, so a new root-based program is included to assist you: historoot. With g4beamline in your PATH, just type: historoot [file.root] [...] this will permit you to open Root files, select an NTuple, and create plots using expressions involving the NTuple variables and C functions and operators. Four sliders are available to impose cuts on arbitrary expressions. Plots can be saved in many formats, including PS, PDF, GIF, and JPEG. On Linux, G4beamline can still write HistoScope files, and the distribution still includes the histo program. Recent updates to Fedora Core 5 and other Linux distributions make the histo program become unstable (may lock up the entire X-Windows server). We strongly recommend switching to Root. For visualization, the OpenInventor viewer works fine, use viewer=best or viewer=OIX. Other viewers are available. TROUBLESHOOTING --------------- Here is the output of ldd on Linux, Fedora Core 6. This shows what shared libraries are used, and where they come from. $ pwd /home/tjrob/g4beamline-1.13-Linux-g++/bin/Linux-g++ $ LD_LIBRARY_PATH=../../lib/Linux-g++ ldd g4beamline linux-gate.so.1 => (0x00110000) libTree.so => ../../lib/Linux-g++/libTree.so (0x00112000) libCint.so => ../../lib/Linux-g++/libCint.so (0x00382000) libCore.so => ../../lib/Linux-g++/libCore.so (0x00a8c000) libXi.so.6 => /usr/lib/libXi.so.6 (0x0090d000) libGLU.so.1 => /usr/lib/libGLU.so.1 (0x007e6000) libGL.so.1 => /usr/lib/libGL.so.1 (0x061f2000) libXm.so.3 => ../../lib/Linux-g++/libXm.so.3 (0x063ed000) libXpm.so.4 => /usr/lib/libXpm.so.4 (0x00867000) libXmu.so.6 => /usr/lib/libXmu.so.6 (0x00878000) libXt.so.6 => /usr/lib/libXt.so.6 (0x060c2000) libXext.so.6 => /usr/lib/libXext.so.6 (0x00890000) libX11.so.6 => /usr/lib/libX11.so.6 (0x00915000) libSM.so.6 => /usr/lib/libSM.so.6 (0x008a0000) libICE.so.6 => /usr/lib/libICE.so.6 (0x008a9000) libm.so.6 => /lib/libm.so.6 (0x008c3000) libpthread.so.0 => /lib/libpthread.so.0 (0x008ea000) libc.so.6 => /lib/libc.so.6 (0x02c3a000) libdl.so.2 => /lib/libdl.so.2 (0x00902000) libcrypt.so.1 => /lib/libcrypt.so.1 (0x06abe000) libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x013ea000) libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00a17000) libXxf86vm.so.1 => /usr/lib/libXxf86vm.so.1 (0x061eb000) libdrm.so.2 => /usr/lib/libdrm.so.2 (0x00a23000) libXp.so.6 => ../../lib/Linux-g++/libXp.so.6 (0x00a2e000) libXau.so.6 => /usr/lib/libXau.so.6 (0x00907000) libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x00a35000) /lib/ld-linux.so.2 (0x00a71000) Note that the Root shared libraries and some lesstif/X11 shared libraries are included in the G4beamline distribution. This reduces the need for users to install precisely the same version of these libraries as was used to build g4beamline. Here are the RPMs that provide these libraries in Fedora Core 6: /usr/lib/libXi.so.6 libXi-1.0.1-3.1 /usr/lib/libGLU.so.1 mesa-libGLU-6.5.1-9.fc6 /usr/lib/libGL.so.1 mesa-libGL-6.5.1-9.fc6 /usr/lib/libXpm.so.4 libXpm-3.5.5-3 /usr/lib/libXmu.so.6 libXmu-1.0.2-5 /usr/lib/libXt.so.6 libXt-1.0.2-3.1.fc6 /usr/lib/libXext.so.6 libXext-1.0.1-2.1 /usr/lib/libX11.so.6 libX11-1.0.3-7.fc6 /usr/lib/libSM.so.6 libSM-1.0.1-3.1 /usr/lib/libICE.so.6 libICE-1.0.1-2.1 /lib/libm.so.6 glibc-2.5-18.fc6 /lib/libpthread.so.0 glibc-2.5-18.fc6 /lib/libc.so.6 glibc-2.5-18.fc6 /lib/libdl.so.2 glibc-2.5-18.fc6 /lib/libcrypt.so.1 glibc-2.5-18.fc6 /usr/lib/libstdc++.so.6 libstdc++-4.1.2-13.fc6 /lib/libgcc_s.so.1 libgcc-4.1.2-13.fc6 /usr/lib/libXxf86vm.so.1 libXxf86vm-1.0.1-3.1 /usr/lib/libdrm.so.2 libdrm-2.3.0-1.fc6 /usr/lib/libXau.so.6 libXau-1.0.1-3.1 /usr/lib/libXdmcp.so.6 libXdmcp-1.0.1-2.1 /lib/ld-linux.so.2 glibc-2.5-18.fc6