NOTE : When using installation on lxplus. first set env for CMSSW (cmsenv) and then set env for G4 otherwise it will ruin the environment settings and you will see error related to graphics.

Download & Install

Download latest stable version(4.9.6 patch2)

See detailed installation instructions from

For a quick installation of 4.9.6 patch just copy paste following lines on terminal :

###   On lxplus 445
mkdir GEANT
tar -xzvf geant4.9.6.p02.tar.gz
mkdir geant4.9.6-build
cd geant4.9.6-build/


#or @ cmssusy use 
#/opt/exp_soft/misc/cmake/bin/cmake -DCMAKE_INSTALL_PREFIX=/cmshome/khurana/GEANT/geant4.9.6.p02-install -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DGEANT4_USE_RAYTRACER_X11=ON /cmshome/khurana/GEANT/geant4.9.6.p02

make -j2   ## this will take almost 30 mins (depends on your system also)
make install

included the following in CmakeLists.txt:



target_link_libraries(fcalor ${Geant4_LIBRARIES} ${ROOT_LIBRARIES})

cmake again

 You can use directly Root classes from your
 Geant4 application.
 To use Root histogram in eg. Geant4 novice example N02,
 you just have to add in the makefile
 the following lines:

CPPFLAGS += -I$(ROOTSYS)/include
EXTRALIBS = $(shell root-config --glibs)


include $(G4INSTALL)/config/binmake.gmk

Once Installed go through following link to run the examples.

Follow the link to write own geometry from scratch :

Edit | Attach | Watch | Print version | History: r6 < r5 < r4 < r3 < r2 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r6 - 2013-09-14 - RamanKhurana
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    Main All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2020 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback