...
The
...
SLIC
...
full
...
simulator
...
program
...
requires
...
the
...
setup
...
of
...
8
...
different
...
software
...
packages,
...
not
...
counting
...
the
...
required
...
build
...
tools.
...
This
...
guide
...
is
...
a
...
step-by-step
...
walkthrough
...
covering
...
package
...
and
...
tool
...
installation.
...
It
...
presumes
...
nothing
...
except
...
a
...
working
...
Windows
...
machine
...
(2000,
...
XP)
...
with
...
internet
...
access.
...
Therefore,
...
you
...
may
...
only
...
need
...
to
...
use
...
parts
...
of
...
this
...
installation
...
guide
...
if
...
you
...
have
...
some
...
of
...
the
...
external
...
dependencies
...
already
...
installed.
...
Preliminaries
Cygwin
- Download www.cygwin.com/setup.exe
...
- from
...
- the
...
...
- .
- Double-click
...
- on
...
- it
...
- and
...
- click
...
- Next
...
- .
...
- Select
...
- Install
...
- from
...
- Internet
...
- and
...
- click
...
- Next
...
- .
...
- Enter
...
- your
...
- preferred
...
- Root
...
- Directory
...
- and
...
- click
...
- Next
...
- .
...
- Enter
...
- your
...
- preferred
...
- Local
...
- Package
...
- Directory
...
- ,
...
- which
...
- can
...
- be
...
- the
...
- same
...
- as
...
- the
...
- Root
...
- Directory
...
- ,
...
- and
...
- then
...
- click
...
- Next
...
- .
...
- Select
...
- Direct
...
- Connection
...
- ,
...
- if
...
- it
...
- is
...
- not
...
- already,
...
- click
...
- Next
...
- .
...
- Select
...
- a
...
- site
...
- from
...
- the
...
- Available
...
- Download
...
- Sites
...
- .
...
- Servers
...
- inside
...
- your
...
- country
...
- will
...
- probably
...
- be
...
- fastest.
...
- I
...
- use
...
...
- .
...
- Click
...
- Next
...
- .
...
- In
...
- the
...
- Cygwin
...
- Setup
...
- -
...
- Select
...
- Packages
...
- window,
...
- you
...
- need
...
- to
...
- make
...
- sure
...
- that
...
- the
...
- following
...
- tools
...
- are
...
- selected
...
- by
...
- clicking
...
- in
...
- the
...
- corresponding
...
- box
...
- under
...
- the
...
- New
...
- column
...
- until
...
- you
...
- see
...
- a
...
- version
...
- number.
...
- Required
...
- packages.
...
- Devel
...
- ->
...
- cvs
...
- Devel
...
- ->
...
- gcc-core
...
- Devel
...
- ->
...
- gcc-g++
...
- Devel
...
- ->
...
- make
...
- Base
...
- ->
...
- gzip
...
- Base
...
- ->
...
- tar
...
- Tool
...
- for
...
- downloading
...
- package
...
- tarballs
...
- and
...
- zip
...
- files.
...
- Web
...
- ->
...
- wget
...
- If
...
- you
...
- want
...
- to
...
- use
...
- Geant4's
...
- OpenGL
...
- drivers,
...
- you
...
- need
...
- to
...
- install
...
- X
...
- Windows,
...
- too.
...
- I
...
- believe
...
- these
...
- two
...
- packages
...
- should
...
- give
...
- you
...
- all
...
- the
...
- required
...
- X11
...
- dependencies.
...
- X11
...
- ->
...
- xorg-x11-base
...
- X11
...
- ->
...
- xorg-x11-xwin
...
- Click
...
- Next
...
- after
...
- you
...
- have
...
- selected
...
- the
...
- packages.
...
- Cygwin
...
- will
...
- now
...
- automatically
...
- download
...
- and
...
- install
...
- all
...
- the
...
- selected
...
- packages.
...
- It
...
- might
...
- take
...
- awhile,
...
- so
...
- now
...
- is
...
- the
...
- time
...
- to
...
- go
...
- get
...
- some
...
- coffee.
...
- If
...
- desired,
...
- select
...
- Create
...
- icon
...
- on
...
- Desktop
...
- or
...
- Add
...
- icon
...
- to
...
- Start
...
- Menu
...
- ,
...
- and
...
- click
...
- Finish
...
- .
...
Testing
...
the
...
Cygwin
...
Command
...
Line
...
Tools
...
- Select Start Menu ->
...
- Cygwin
...
- ->
...
- Cygwin
...
- Bash
...
- Shell
...
- Check
...
- that
...
- the
...
- following
...
- commands
...
- do
...
- not
...
- result
...
- in
...
- a
...
- command
...
- not
...
- found
...
- message.
...
- cvs
- gcc
- g++
...
- tar
- wget
- make
- If a command was not found, rerun the Cygwin setup to select the missing package, making sure to select Keep on the Cygwin Setup - Select Packages screen so that all the packages are not reinstalled.
Warning |
---|
Throughout this guide, I assume you are using bash or at least another sh compatible shell. Please don't try to use csh or something equally hideous. |
Work Area
We will install all packages into a common work area.
- From the Cygwin shell, create a work directory for SLIC and its external dependencies.
No Format cd /cygdrive/c mkdir sim cd sim
...
- Create the file setup.sh
...
- with
...
- the
...
- following
...
- contents.
...
- (We
...
- will
...
- be
...
- adding
...
- to
...
- this
...
- file
...
- as
...
- the
...
- installation
...
- proceeds.)
...
No Format
...
#!/bin/sh export sim_work=/cygdrive/c/sim
...
- Source the script to setup the work dir.
No Format source setup.sh
Tip |
---|
Throughout the {noformat} {tip} Throughout theguide, any time a line is added to *setup.sh *, it is presumed that you also set this up in the current environment. Probably the easiest way to do this is adding to the script first and then (re)sourcing it. {tip} h2. Java Java is required for installing LCIO. # Install an appropriate JDK from [ |
Java
Java is required for installing LCIO.
- Install an appropriate JDK from http://java.sun.com/
...
- with
...
- a
...
- minimum
...
- version
...
- of
...
- 1.4.2.
...
- In
...
- your
...
- setup.sh
...
- ,
...
- set
...
- JAVA_HOME
...
- and
...
- JDK_HOME
...
- to
...
- the
...
- Java
...
- installation
...
- area.
...
No Format
...
export JAVA_HOME=/cygdrive/c/java/jdk1.4.2/ export JDK_HOME=${JAVA_HOME}
Warning |
---|
The above {noformat} {warning} The aboveJAVA_HOME location is an example only. You need to replace it with the correct path to your JDK. {warning} h2. |
Proceed!
...
You
...
are
...
now
...
ready
...
to
...
begin
...
the
...
package
...
installations.
...
Tip |
---|
Leave your Cygwin window open, as you will be using it throughout the installation. |
Package Installations
CLHEP
There are installation instructions for version 1.9 and up http://wwwasd.web.cern.ch/wwwasd/lhc
...
++/clhep/INSTALLATION/newCLHEP-install.html
...
.
...
But
...
you
...
should
...
not
...
need
...
them
...
to
...
setup
...
the
...
package.
...
- Create
...
- a
...
- working
...
- directory
...
- for
...
- CLHEP
...
- and
...
- go
...
- into
...
- it.
...
No Format
...
mkdir clhep cd clhep
...
- Download the CLHEP tarball.
No Format wget http://cern.ch/clhep/clhep-1.9.2.0.tgz
...
- Unzip to your work directory.
No Format tar zxvf clhep-1.9.2.0.tgz
...
- Change to CLHEP directory.
No Format cd 1.9.2.0/CLHEP
...
- Run configure. (Takes
...
- a
...
- long
...
- time!)
...
No Format
...
./configure --prefix=`cd ../..; pwd` --disable-shared
...
- Build the library and install it. (Also takes a long time!)
No Format make make install
...
- Add the following to $sim_work/setup.sh
...
No Format
...
export CLHEP_BASE_DIR=$sim_work/clhep
...
Now
...
that
...
the
...
CLHEP
...
dependency
...
is
...
satisfied,
...
you
...
should
...
be
...
able
...
to
...
install
...
Geant4.
...
Geant4
Geant4 is probably the most difficult application to install of SLIC's
...
dependencies,
...
because
...
there
...
are
...
a
...
lot
...
of
...
options.
...
I
...
will
...
describe
...
a
...
minimal
...
installation
...
procedure
...
with
...
OpenGL
...
support.
...
You
...
can
...
always
...
update
...
the
...
libraries
...
later
...
if
...
you
...
decide
...
to
...
change
...
these
...
settings.
...
- Return
...
- to
...
- the
...
- work
...
- dir,
...
- create
...
- a
...
- Geant4
...
- work
...
- subdir
...
- and
...
- go
...
- into
...
- it.
...
No Format
...
cd $sim_work mkdir geant4 cd geant4
...
- Download the Geant4 tarball.
No Format wget http://geant4.cern.ch/geant4/source/source/geant4.7.0.p01.tar.gz
...
- Unzip it.
...
No Format
...
tar zxvf geant4.7.0.p01.tar.gz
...
- Setting the following variables in $sim_work/setup.sh
...
- should
...
- allow
...
- you
...
- to
...
- compile
...
- without
...
- running
...
- the
...
- ./Configure
...
- script
...
- .
...
No Format
...
G4INSTALL=${sim_wrk}/geant4/geant4.7.0.p01 G4SYSTEM=WIN32-g++ OGLHOME=/usr/X11R6
...
- Go into the Geant4 install dir.
No Format cd geant4.7.0.p01
...
- Build the libraries.
...
- These
...
- will
...
- be
...
- placed
...
- at
...
- $G4INSTALL/lib/WIN32-g++
...
- .
...
- (Maybe
...
- you
...
- should
...
- let
...
- this
...
- run
...
- overnight!)
...
No Format
...
make
...
- Build the physics list libraries. These will go into $G4INSTALL/lib/plists/WIN32-g++
...
- .
...
No Format
...
cd ../physics_lists/hadronic make cd ../electromagnetic make
...
Warning |
---|
The default Geant4 library settings for WIN32 are global and static. You may choose other settings, but this could require changes in installation settings "down the line" that I may not mention. |
LCPhys
- Go back to the work dir.
No Format cd $sim_wrk
...
- Checkout the physics list from CVS.
No Format cvs -d :pserver:anonymous@cvs.freehep.org:/cvs/lcd checkout LCPhys
...
- Assuming that the environment from the Geant4 installation is still in place, you can build this like any other physics list.
No Format cd LCPhys make
...
- Set the LCPhys variable in setup.sh
...
- .
...
No Format
...
LCPHYS_BASE=$sim_wrk/LCPhys
...
LCIO
LCIO actually has a very nice manual http://lcio.desy.de/v01-04/doc/manual_html/manual.html
...
.
...
Thanks,
...
Frank!
...
It
...
has
...
a
...
whole
...
section
...
on
...
installation
...
http://lcio.desy.de/v01-04/doc/manual_html/manual.html#SECTION00030000000000000000
...
.
...
Warning |
---|
LCIO requires a working Java SDK. |
I will still walk you through the basic procedure.
- Go back to the work dir.
No Format cd $sim_wrk
...
- Checkout LCIO from CVS.
No Format cvs -d :pserver:anonymous@cvs.freehep.org:/cvs/lcio checkout lcio
...
- Add these lines to your setup.sh
...
- .
...
No Format
...
export LCIO=${sim_wrk}/lcio export PATH=$LCIO/tools:$LCIO/bin:$PATH
...
- Build the libraries using the bundled aid and ant tools.
No Format ant aid cpp
...
Xerces
- Go back to the work dir, create a subdir for Xerces-C++,
...
- and
...
- go
...
- into
...
- it.
...
No Format
...
cd $sim_wrk mkdir xercesc cd xercesc
...
- Download the Xerces tarball.
No Format wget http://www.apache.org/dist/xml/xerces-c/xerces-c-src_2_6_0.tar.gz
...
- Unzip the tarball.
No Format tar -zxvf xerces-c-src_2_6_0.tar.gz
...
- Set the temporary XERCESCROOT in the environment.
No Format export XERCESCROOT=${sim_work}/xerces-c-src_2_6_0
...
- Go into the Xerces-C++
...
- build
...
- area.
...
No Format
...
cd xerces-c-src_2_6_0/src/xercesc
...
- Configure the build.
No Format ./runConfigure -pcygwin -cgcc -xg++ \ -minmem -nsocket -tnative -rpthread \ -P `cd ../..; pwd`
...
- Build and install it.
No Format make make install
...
- In setup.sh
...
- ,
...
- set
...
- XERCESCROOT
...
- to
...
- the
...
- installation
...
- area.
...
No Format
...
export XERCESCROOT=${sim_work}/xercesc
...
GDML
GDML's
...
CVS
...
is
...
not
...
directly
...
acessible,
...
but
...
a
...
tarball
...
is
...
available
...
through
...
a
...
WWW
...
interface.
...
- Download
...
- a
...
- snapshot
...
- of
...
- the
...
- current
...
- CVS
...
- head
...
- using
...
- this
...
- link
...
- in
...
- your
...
- browser.
...
...
- Save
...
- the
...
- tarball to $sim_wrk
...
- .
...