Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

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

  1. Download www.cygwin.com/setup.exe

...

  1. from

...

  1. the

...

  1. www.cygwin.com

...

  1. .
  2. Double-click

...

  1. on

...

  1. it

...

  1. and

...

  1. click

...

  1. Next

...

  1. .

...

  1. Select

...

  1. Install

...

  1. from

...

  1. Internet

...

  1. and

...

  1. click

...

  1. Next

...

  1. .

...

  1. Enter

...

  1. your

...

  1. preferred

...

  1. Root

...

  1. Directory

...

  1. and

...

  1. click

...

  1. Next

...

  1. .

...

  1. Enter

...

  1. your

...

  1. preferred

...

  1. Local

...

  1. Package

...

  1. Directory

...

  1. ,

...

  1. which

...

  1. can

...

  1. be

...

  1. the

...

  1. same

...

  1. as

...

  1. the

...

  1. Root

...

  1. Directory

...

  1. ,

...

  1. and

...

  1. then

...

  1. click

...

  1. Next

...

  1. .

...

  1. Select

...

  1. Direct

...

  1. Connection

...

  1. ,

...

  1. if

...

  1. it

...

  1. is

...

  1. not

...

  1. already,

...

  1. click

...

  1. Next

...

  1. .

...

  1. Select

...

  1. a

...

  1. site

...

  1. from

...

  1. the

...

  1. Available

...

  1. Download

...

  1. Sites

...

  1. .

...

  1. Servers

...

  1. inside

...

  1. your

...

  1. country

...

  1. will

...

  1. probably

...

  1. be

...

  1. fastest.

...

  1. I

...

  1. use

...

  1. ftp://ftp.sunsite.utk.edu

...

  1. .

...

  1. Click

...

  1. Next

...

  1. .

...

  1. In

...

  1. the

...

  1. Cygwin

...

  1. Setup

...

  1. -

...

  1. Select

...

  1. Packages

...

  1. window,

...

  1. you

...

  1. need

...

  1. to

...

  1. make

...

  1. sure

...

  1. that

...

  1. the

...

  1. following

...

  1. tools

...

  1. are

...

  1. selected

...

  1. by

...

  1. clicking

...

  1. in

...

  1. the

...

  1. corresponding

...

  1. box

...

  1. under

...

  1. the

...

  1. New

...

  1. column

...

  1. until

...

  1. you

...

  1. see

...

  1. a

...

  1. version

...

  1. number.

...

    1. Required

...

    1. packages.

...

      • Devel

...

      • ->

...

      • cvs

...

      • Devel

...

      • ->

...

      • gcc-core

...

      • Devel

...

      • ->

...

      • gcc-g++

...

      • Devel

...

      • ->

...

      • make

...

      • Base

...

      • ->

...

      • gzip

...

      • Base

...

      • ->

...

      • tar

...

    1. Tool

...

    1. for

...

    1. downloading

...

    1. package

...

    1. tarballs

...

    1. and

...

    1. zip

...

    1. files.

...

      • Web

...

      • ->

...

      • wget

...

    1. If

...

    1. you

...

    1. want

...

    1. to

...

    1. use

...

    1. Geant4's

...

    1. OpenGL

...

    1. drivers,

...

    1. you

...

    1. need

...

    1. to

...

    1. install

...

    1. X

...

    1. Windows,

...

    1. too.

...

    1. I

...

    1. believe

...

    1. these

...

    1. two

...

    1. packages

...

    1. should

...

    1. give

...

    1. you

...

    1. all

...

    1. the

...

    1. required

...

    1. X11

...

    1. dependencies.

...

      • X11

...

      • ->

...

      • xorg-x11-base

...

      • X11

...

      • ->

...

      • xorg-x11-xwin

...

  1. Click

...

  1. Next

...

  1. after

...

  1. you

...

  1. have

...

  1. selected

...

  1. the

...

  1. packages.

...

  1. Cygwin

...

  1. will

...

  1. now

...

  1. automatically

...

  1. download

...

  1. and

...

  1. install

...

  1. all

...

  1. the

...

  1. selected

...

  1. packages.

...

  1. It

...

  1. might

...

  1. take

...

  1. awhile,

...

  1. so

...

  1. now

...

  1. is

...

  1. the

...

  1. time

...

  1. to

...

  1. go

...

  1. get

...

  1. some

...

  1. coffee.

...

  1. If

...

  1. desired,

...

  1. select

...

  1. Create

...

  1. icon

...

  1. on

...

  1. Desktop

...

  1. or

...

  1. Add

...

  1. icon

...

  1. to

...

  1. Start

...

  1. Menu

...

  1. ,

...

  1. and

...

  1. click

...

  1. Finish

...

  1. .

...

Testing

...

the

...

Cygwin

...

Command

...

Line

...

Tools

...

  1. Select Start Menu ->

...

  1. Cygwin

...

  1. ->

...

  1. Cygwin

...

  1. Bash

...

  1. Shell

...

  1. Check

...

  1. that

...

  1. the

...

  1. following

...

  1. commands

...

  1. do

...

  1. not

...

  1. result

...

  1. in

...

  1. a

...

  1. command

...

  1. not

...

  1. found

...

  1. message.

...

    • cvs
    • gcc
    • g++

...

    • tar
    • wget
    • make
  1. 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.

  1. From the Cygwin shell, create a work directory for SLIC and its external dependencies.
    No Format
    
    cd /cygdrive/c
    mkdir sim
    cd sim
    

...

  1. Create the file setup.sh

...

  1. with

...

  1. the

...

  1. following

...

  1. contents.

...

  1. (We

...

  1. will

...

  1. be

...

  1. adding

...

  1. to

...

  1. this

...

  1. file

...

  1. as

...

  1. the

...

  1. installation

...

  1. proceeds.)

...

  1. No Format

...

  1. 
    #!/bin/sh
    export sim_work=/cygdrive/c/sim
    

...

  1. Source the script to setup the work dir.
    No Format
    
    source setup.sh
    
Tip

Throughout the

{noformat} {tip} Throughout the

guide,

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.

  1. Install an appropriate JDK from http://java.sun.com/

...

  1. with

...

  1. a

...

  1. minimum

...

  1. version

...

  1. of

...

  1. 1.4.2.

...

  1. In

...

  1. your

...

  1. setup.sh

...

  1. ,

...

  1. set

...

  1. JAVA_HOME

...

  1. and

...

  1. JDK_HOME

...

  1. to

...

  1. the

...

  1. Java

...

  1. installation

...

  1. area.

...

  1. No Format

...

  1. 
    export JAVA_HOME=/cygdrive/c/java/jdk1.4.2/
    export JDK_HOME=${JAVA_HOME}
    
Warning

The above

{noformat} {warning} The above

JAVA_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.

...

  1. Create

...

  1. a

...

  1. working

...

  1. directory

...

  1. for

...

  1. CLHEP

...

  1. and

...

  1. go

...

  1. into

...

  1. it.

...

  1. No Format

...

  1. 
    mkdir clhep
    cd clhep
    

...

  1. Download the CLHEP tarball.
    No Format
    
    wget http://cern.ch/clhep/clhep-1.9.2.0.tgz
    

...

  1. Unzip to your work directory.
    No Format
    
    tar zxvf clhep-1.9.2.0.tgz
    

...

  1. Change to CLHEP directory.
    No Format
    
    cd 1.9.2.0/CLHEP
    

...

  1. Run configure. (Takes

...

  1. a

...

  1. long

...

  1. time!)

...

  1. No Format

...

  1. 
    ./configure --prefix=`cd ../..; pwd` --disable-shared
    

...

  1. Build the library and install it. (Also takes a long time!)
    No Format
    
    make
    make install
    

...

  1. Add the following to $sim_work/setup.sh

...

  1. No Format

...

  1. 
    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.

...

  1. Return

...

  1. to

...

  1. the

...

  1. work

...

  1. dir,

...

  1. create

...

  1. a

...

  1. Geant4

...

  1. work

...

  1. subdir

...

  1. and

...

  1. go

...

  1. into

...

  1. it.

...

  1. No Format

...

  1. 
    cd $sim_work
    mkdir geant4
    cd geant4
    

...

  1. Download the Geant4 tarball.
    No Format
    
    wget http://geant4.cern.ch/geant4/source/source/geant4.7.0.p01.tar.gz
    

...

  1. Unzip it.

...

  1. No Format

...

  1. 
    tar zxvf geant4.7.0.p01.tar.gz
    

...

  1. Setting the following variables in $sim_work/setup.sh

...

  1. should

...

  1. allow

...

  1. you

...

  1. to

...

  1. compile

...

  1. without

...

  1. running

...

  1. the

...

  1. ./Configure

...

  1. script

...

  1. .

...

  1. No Format

...

  1. 
    G4INSTALL=${sim_wrk}/geant4/geant4.7.0.p01
    G4SYSTEM=WIN32-g++
    OGLHOME=/usr/X11R6
    

...

  1. Go into the Geant4 install dir.
    No Format
    
    cd geant4.7.0.p01
    

...

  1. Build the libraries.

...

  1. These

...

  1. will

...

  1. be

...

  1. placed

...

  1. at

...

  1. $G4INSTALL/lib/WIN32-g++

...

  1. .

...

  1. (Maybe

...

  1. you

...

  1. should

...

  1. let

...

  1. this

...

  1. run

...

  1. overnight!)

...

  1. No Format

...

  1. 
    make
    

...

  1. Build the physics list libraries. These will go into $G4INSTALL/lib/plists/WIN32-g++

...

  1. .

...

  1. No Format

...

  1. 
    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

  1. Go back to the work dir.
    No Format
    
    cd $sim_wrk
    

...

  1. Checkout the physics list from CVS.
    No Format
    
    cvs -d :pserver:anonymous@cvs.freehep.org:/cvs/lcd checkout LCPhys
    

...

  1. 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
    

...

  1. Set the LCPhys variable in setup.sh

...

  1. .

...

  1. No Format

...

  1. 
    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.

  1. Go back to the work dir.
    No Format
    
    cd $sim_wrk
    

...

  1. Checkout LCIO from CVS.
    No Format
    
    cvs -d :pserver:anonymous@cvs.freehep.org:/cvs/lcio checkout lcio
    

...

  1. Add these lines to your setup.sh

...

  1. .

...

  1. No Format

...

  1. 
    export LCIO=${sim_wrk}/lcio 
    export PATH=$LCIO/tools:$LCIO/bin:$PATH
    

...

  1. Build the libraries using the bundled aid and ant tools.
    No Format
    
    ant aid cpp
    

...

Xerces

  1. Go back to the work dir, create a subdir for Xerces-C++,

...

  1. and

...

  1. go

...

  1. into

...

  1. it.

...

  1. No Format

...

  1. 
    cd $sim_wrk
    mkdir xercesc
    cd xercesc
    

...

  1. Download the Xerces tarball.
    No Format
    
    wget http://www.apache.org/dist/xml/xerces-c/xerces-c-src_2_6_0.tar.gz
    

...

  1. Unzip the tarball.
    No Format
    
    tar -zxvf xerces-c-src_2_6_0.tar.gz
    

...

  1. Set the temporary XERCESCROOT in the environment.
    No Format
    
    export XERCESCROOT=${sim_work}/xerces-c-src_2_6_0
    

...

  1. Go into the Xerces-C++

...

  1. build

...

  1. area.

...

  1. No Format

...

  1. 
    cd xerces-c-src_2_6_0/src/xercesc
    

...

  1. Configure the build.
    No Format
    
    ./runConfigure -pcygwin -cgcc -xg++ \
    -minmem -nsocket -tnative -rpthread \
    -P `cd ../..; pwd`
    

...

  1. Build and install it.
    No Format
    
    make
    make install
    

...

  1. In setup.sh

...

  1. ,

...

  1. set

...

  1. XERCESCROOT

...

  1. to

...

  1. the

...

  1. installation

...

  1. area.

...

  1. No Format

...

  1. 
    export XERCESCROOT=${sim_work}/xercesc
    

...

GDML

GDML's

...

CVS

...

is

...

not

...

directly

...

acessible,

...

but

...

a

...

tarball

...

is

...

available

...

through

...

a

...

WWW

...

interface.

...

  1. Download

...

  1. a

...

  1. snapshot

...

  1. of

...

  1. the

...

  1. current

...

  1. CVS

...

  1. head

...

  1. using

...

  1. this

...

  1. link

...

  1. in

...

  1. your

...

  1. browser.

...

  1. http://simu.cvs.cern.ch/cgi-bin/simu.cgi/simu/GDML2/GDML2.tar.gz?tarball=1

...

    • Save

...

    • the

...

    • tarball to $sim_wrk

...

    • .

...

LCDD

SLIC

Additional Resources