Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
CLHEP
CLHEP
Commits
effb0535
Commit
effb0535
authored
Aug 29, 2003
by
Lynn Garren
Browse files
make examples work in new configuration
parent
a7741b69
Changes
26
Hide whitespace changes
Inline
Side-by-side
Geometry/configure.in
View file @
effb0535
...
...
@@ -57,6 +57,36 @@ AC_SUBST(Geometry_LDFLAGS)
AH_TOP([#ifndef GEOMETRY_DEFS_H
#define GEOMETRY_DEFS_H])
## the undefs are converted by configure
AH_VERBATIM([PACKAGE],[/* Name of package */
#ifndef PACKAGE
#undef PACKAGE
#endif])
AH_VERBATIM([PACKAGE_BUGREPORT],[/* Define to the address where bug reports for this package should be sent. */
#ifndef PACKAGE_BUGREPORT
#undef PACKAGE_BUGREPORT
#endif])
AH_VERBATIM([PACKAGE_NAME],[/* Define to the full name of this package. */
#ifndef PACKAGE_NAME
#undef PACKAGE_NAME
#endif])
AH_VERBATIM([PACKAGE_STRING],[/* Define to the full name and version of this package. */
#ifndef PACKAGE_STRING
#undef PACKAGE_STRING
#endif])
AH_VERBATIM([PACKAGE_TARNAME],[/* Define to the one symbol short name of this package. */
#ifndef PACKAGE_TARNAME
#undef PACKAGE_TARNAME
#endif])
AH_VERBATIM([PACKAGE_VERSION],[/* Define to the version of this package. */
#ifndef PACKAGE_VERSION
#undef PACKAGE_VERSION
#endif])
AH_VERBATIM([VERSION],[/* Version number of package */
#ifndef VERSION
#undef VERSION
#endif])
AH_BOTTOM([#endif // GEOMETRY_DEFS_H])
...
...
HepMC/configure.in
View file @
effb0535
...
...
@@ -59,11 +59,46 @@ AC_SUBST(HepMC_LDFLAGS)
AH_TOP([#ifndef HEPMC_DEFS_H
#define HEPMC_DEFS_H])
AH_BOTTOM([/* use correct std::ios_base or std::ios (old) */
## the undefs are converted by configure
AH_VERBATIM([PACKAGE],[/* Name of package */
#ifndef PACKAGE
#undef PACKAGE
#endif])
AH_VERBATIM([PACKAGE_BUGREPORT],[/* Define to the address where bug reports for this package should be sent. */
#ifndef PACKAGE_BUGREPORT
#undef PACKAGE_BUGREPORT
#endif])
AH_VERBATIM([PACKAGE_NAME],[/* Define to the full name of this package. */
#ifndef PACKAGE_NAME
#undef PACKAGE_NAME
#endif])
AH_VERBATIM([PACKAGE_STRING],[/* Define to the full name and version of this package. */
#ifndef PACKAGE_STRING
#undef PACKAGE_STRING
#endif])
AH_VERBATIM([PACKAGE_TARNAME],[/* Define to the one symbol short name of this package. */
#ifndef PACKAGE_TARNAME
#undef PACKAGE_TARNAME
#endif])
AH_VERBATIM([PACKAGE_VERSION],[/* Define to the version of this package. */
#ifndef PACKAGE_VERSION
#undef PACKAGE_VERSION
#endif])
AH_VERBATIM([VERSION],[/* Version number of package */
#ifndef VERSION
#undef VERSION
#endif])
AH_BOTTOM([
/* use correct std::ios_base or std::ios (old) */
#ifdef HAVE_IOS_BASE
#define HepIOS std::ios_base
#define HepIOSOpenMode std::ios_base::openmode
#define HepIOSBadBit std::ios_base::badbit
#else
#define HepIOS std::ios
#define HepIOSOpenMode std::ios::open_mode
#define HepIOSBadBit std::ios::badbit
#endif
#endif // HEPMC_DEFS_H])
...
...
HepMC/examples/GNUmakefile
View file @
effb0535
...
...
@@ -24,10 +24,10 @@ endif
################################################################################
CXX
=
g++
INCDIR
=
-I
../../..
INCDIR
=
-I
$(CLHEP_DIR)
/include
HepMCinc
=
$(INCDIR)
/CLHEP/HepMC
PythiaLIB
=
$(LULIB)
/pydata.o
$(LULIB)
/liblund.a
$(LULIB)
/libpydum.a
LIBNAME
=
../..
/libCLHEP-
g++.
1.
8
.0.0.a
LIBNAME
=
$(CLHEP_DIR)
/lib
/libCLHEP-1.
9
.0.0.a
################################################################################
...
...
HepMC/examples/IO_Ascii.cc
View file @
effb0535
...
...
@@ -8,6 +8,8 @@
#include "IO_Ascii.h"
#include "CLHEP/HepMC/GenEvent.h"
using
namespace
CLHEP
;
namespace
HepMC
{
IO_Ascii
::
IO_Ascii
(
const
char
*
filename
,
HepIOSOpenMode
mode
)
...
...
HepMC/examples/IO_Ascii.h
View file @
effb0535
...
...
@@ -43,7 +43,7 @@
#include <map>
#include <vector>
#include "CLHEP/
config/CLHEP
.h"
#include "CLHEP/
HepMC/defs
.h"
#include "CLHEP/HepMC/GenEvent.h"
namespace
HepMC
{
...
...
HepMC/examples/examplePythiaWriteHepMC.cc
View file @
effb0535
...
...
@@ -5,9 +5,9 @@
// using PythiaWrapper.h and WriteHepMC.h
//////////////////////////////////////////////////////////////////////////
#include "CLHEP/
config/CLHEP
.h"
#include
"CLHEP/config/
iostream
.h"
#include
"CLHEP/config/
fstream
.h"
#include "CLHEP/
HepMC/defs
.h"
#include
<
iostream
>
#include
<
fstream
>
#include "CLHEP/HepMC/include/PythiaWrapper.h"
#include "CLHEP/HepMC/WriteHepMC.h"
...
...
HepMC/examples/exampleReadHepMC.cc
View file @
effb0535
...
...
@@ -7,9 +7,9 @@
// gmake examples/example_EventSelection.exe
//
#include "CLHEP/
config/CLHEP
.h"
#include
"CLHEP/config/
iostream
.h"
#include
"CLHEP/config/
fstream
.h"
#include "CLHEP/
HepMC/defs
.h"
#include
<
iostream
>
#include
<
fstream
>
#include "CLHEP/HepMC/ReadHepMC.h"
#include "CLHEP/HepMC/WriteHepMC.h"
...
...
HepMC/examples/example_EventSelection.cc
View file @
effb0535
...
...
@@ -9,7 +9,7 @@
// gmake examples/example_EventSelection.exe
//
#include "CLHEP/
config/CLHEP
.h"
#include "CLHEP/
HepMC/defs
.h"
#include "IO_Ascii.h"
#include "CLHEP/HepMC/GenEvent.h"
...
...
HepMC/examples/example_MyPythia.cc
View file @
effb0535
...
...
@@ -9,8 +9,8 @@
// ascii format using the IO_Ascii strategy.
//////////////////////////////////////////////////////////////////////////
#include "CLHEP/
config/CLHEP
.h"
#include
"CLHEP/config/
iostream
.h"
#include "CLHEP/
HepMC/defs
.h"
#include
<
iostream
>
#include "CLHEP/HepMC/include/PythiaWrapper.h"
#include "CLHEP/HepMC/ConvertHEPEVT.h"
#include "IO_Ascii.h"
...
...
HepMC/examples/example_MyPythiaOnlyToHepMC.cc
View file @
effb0535
...
...
@@ -14,8 +14,8 @@
// See comments in examples/example_MyPythia.cxx regarding the HEPEVT wrapper.
//
#include "CLHEP/
config/CLHEP
.h"
#include
"CLHEP/config/
iostream
.h"
#include "CLHEP/
HepMC/defs
.h"
#include
<
iostream
>
#include "CLHEP/HepMC/include/PythiaWrapper.h"
#include "CLHEP/HepMC/ConvertHEPEVT.h"
#include "CLHEP/HepMC/GenEvent.h"
...
...
HepMC/examples/example_MyPythiaWithEventSelection.cc
View file @
effb0535
...
...
@@ -13,8 +13,8 @@
// See comments in examples/example_MyPythia.cxx regarding the HEPEVT wrapper.
//
#include "CLHEP/
config/CLHEP
.h"
#include
"CLHEP/config/
iostream
.h"
#include "CLHEP/
HepMC/defs
.h"
#include
<
iostream
>
#include "CLHEP/HepMC/include/PythiaWrapper.h"
#include "CLHEP/HepMC/ConvertHEPEVT.h"
#include "CLHEP/HepMC/GenEvent.h"
...
...
HepMC/examples/example_UsingIterators.cc
View file @
effb0535
...
...
@@ -6,7 +6,7 @@
// gmake examples/example_UsingIterators.exe
//
#include "CLHEP/
config/CLHEP
.h"
#include "CLHEP/
HepMC/defs
.h"
#include "IO_Ascii.h"
#include "CLHEP/HepMC/GenEvent.h"
#include <math.h>
...
...
HepMC/examples/testMethods.cc
View file @
effb0535
...
...
@@ -6,8 +6,8 @@
//
//////////////////////////////////////////////////////////////////////////
#include "CLHEP/
config/CLHEP
.h"
#include
"CLHEP/config/
iostream
.h"
#include "CLHEP/
HepMC/defs
.h"
#include
<
iostream
>
#include "CLHEP/HepMC/include/PythiaWrapper.h"
#include "CLHEP/HepMC/ConvertHEPEVT.h"
#include "CLHEP/HepMC/GenEvent.h"
...
...
HepMC/examples/test_MakeUsingIteratorsInput.cc
View file @
effb0535
...
...
@@ -11,8 +11,8 @@
// To Compile: go to the HepMC directory and type:
//
#include "CLHEP/
config/CLHEP
.h"
#include
"CLHEP/config/
iostream
.h"
#include "CLHEP/
HepMC/defs
.h"
#include
<
iostream
>
#include "CLHEP/HepMC/include/PythiaWrapper.h"
#include "CLHEP/HepMC/ConvertHEPEVT.h"
#include "IO_Ascii.h"
...
...
HepPDT/configure.in
View file @
effb0535
...
...
@@ -60,6 +60,36 @@ AC_SUBST(HepPDT_LDFLAGS)
AH_TOP([#ifndef VECTOR_DEFS_H
#define VECTOR_DEFS_H])
## the undefs are converted by configure
AH_VERBATIM([PACKAGE],[/* Name of package */
#ifndef PACKAGE
#undef PACKAGE
#endif])
AH_VERBATIM([PACKAGE_BUGREPORT],[/* Define to the address where bug reports for this package should be sent. */
#ifndef PACKAGE_BUGREPORT
#undef PACKAGE_BUGREPORT
#endif])
AH_VERBATIM([PACKAGE_NAME],[/* Define to the full name of this package. */
#ifndef PACKAGE_NAME
#undef PACKAGE_NAME
#endif])
AH_VERBATIM([PACKAGE_STRING],[/* Define to the full name and version of this package. */
#ifndef PACKAGE_STRING
#undef PACKAGE_STRING
#endif])
AH_VERBATIM([PACKAGE_TARNAME],[/* Define to the one symbol short name of this package. */
#ifndef PACKAGE_TARNAME
#undef PACKAGE_TARNAME
#endif])
AH_VERBATIM([PACKAGE_VERSION],[/* Define to the version of this package. */
#ifndef PACKAGE_VERSION
#undef PACKAGE_VERSION
#endif])
AH_VERBATIM([VERSION],[/* Version number of package */
#ifndef VERSION
#undef VERSION
#endif])
AH_BOTTOM([#endif // VECTOR_DEFS_H])
...
...
StdHep/StdHep/StdHepfromStdEvent.icc
View file @
effb0535
// $Id: StdHepfromStdEvent.icc,v 1.
1.1.1
2003/0
7/15 20:15:05
garren Exp $
// $Id: StdHepfromStdEvent.icc,v 1.
2
2003/0
8/29 02:06:13
garren Exp $
// ----------------------------------------------------------------------
// HEPEVTfromStdEvent.icc
// ----------------------------------------------------------------------
...
...
@@ -77,14 +77,14 @@ bool CBstdhep::CollisionToStdTmp( const HepMC::GenEvent * col )
for ( int i = 1; i <= particle_counter; ++i ) {
tptr->isthept[i-1] = index_to_particle[i]->status();
tptr->idhept[i-1] = index_to_particle[i]->pdg_id();
HepLorentzVector m = index_to_particle[i]->momentum();
CLHEP::
HepLorentzVector m = index_to_particle[i]->momentum();
tptr->phept[i-1][0] = m.px();
tptr->phept[i-1][1] = m.py();
tptr->phept[i-1][2] = m.pz();
tptr->phept[i-1][3] = m.e();
tptr->phept[i-1][4] = index_to_particle[i]->generatedMass();
if ( index_to_particle[i]->production_vertex() ) {
HepLorentzVector p = index_to_particle[i]->
CLHEP::
HepLorentzVector p = index_to_particle[i]->
production_vertex()->position();
tptr->vhept[i-1][0] = p.x();
tptr->vhept[i-1][1] = p.y();
...
...
StdHep/StdHep/StdHeptoGenEvent.icc
View file @
effb0535
// $Id: StdHeptoGenEvent.icc,v 1.
1.1.1
2003/0
7/15 20:15:05
garren Exp $
// $Id: StdHeptoGenEvent.icc,v 1.
2
2003/0
8/29 02:06:13
garren Exp $
// ----------------------------------------------------------------------
//
// StdHeptoHepMC::GenEvent.icc
...
...
@@ -85,7 +85,7 @@ HepMC::GenParticle* CBstdhep::createParticle( int index ) {
// Builds a particle object corresponding to index in HEPEVT
//
HepMC::GenParticle* p
= new HepMC::GenParticle( HepLorentzVector( hptr->phep[index-1][0],
= new HepMC::GenParticle(
CLHEP::
HepLorentzVector( hptr->phep[index-1][0],
hptr->phep[index-1][1],
hptr->phep[index-1][2],
hptr->phep[index-1][3] ),
...
...
@@ -121,18 +121,18 @@ void CBstdhep::buildProductionVertex( int i,
// b. if no suitable production vertex exists - and the particle
// has atleast one mother or position information to store -
// make one
HepLorentzVector prod_pos( hptr->vhep[i-1][0], hptr->vhep[i-1][1],
CLHEP::
HepLorentzVector prod_pos( hptr->vhep[i-1][0], hptr->vhep[i-1][1],
hptr->vhep[i-1][2], hptr->vhep[i-1][3]
);
if ( !prod_vtx && (number_parents(i-1)>0
|| prod_pos!=HepLorentzVector(0,0,0,0)) )
|| prod_pos!=
CLHEP::
HepLorentzVector(0,0,0,0)) )
{
prod_vtx = new HepMC::GenVertex();
prod_vtx->add_particle_out( p );
evt->add_vertex( prod_vtx );
}
// c. if prod_vtx doesn't already have position specified, fill it
if ( prod_vtx && prod_vtx->position()==HepLorentzVector(0,0,0,0) ) {
if ( prod_vtx && prod_vtx->position()==
CLHEP::
HepLorentzVector(0,0,0,0) ) {
prod_vtx->set_position( prod_pos );
}
// d. loop over mothers to make sure their end_vertices are
...
...
@@ -198,13 +198,13 @@ void CBstdhep::buildEndVertex( int iend,
end_vtx->add_particle_out( hepevt_particle[daughter] );
//
// 2001-03-29 M.Dobbs, fill vertex the position.
if ( end_vtx->position()==HepLorentzVector(0,0,0,0) ) {
HepLorentzVector prod_pos( hptr->vhep[daughter-1][0],
if ( end_vtx->position()==
CLHEP::
HepLorentzVector(0,0,0,0) ) {
CLHEP::
HepLorentzVector prod_pos( hptr->vhep[daughter-1][0],
hptr->vhep[daughter-1][1],
hptr->vhep[daughter-1][2],
hptr->vhep[daughter-1][3]
);
if ( prod_pos != HepLorentzVector(0,0,0,0) ) {
if ( prod_pos !=
CLHEP::
HepLorentzVector(0,0,0,0) ) {
end_vtx->set_position( prod_pos );
}
}
...
...
StdHep/configure.in
View file @
effb0535
...
...
@@ -53,11 +53,45 @@ AC_SUBST(StdHep_LDFLAGS)
AH_TOP([#ifndef STDHEP_DEFS_H
#define STDHEP_DEFS_H])
## the undefs are converted by configure
AH_VERBATIM([PACKAGE],[/* Name of package */
#ifndef PACKAGE
#undef PACKAGE
#endif])
AH_VERBATIM([PACKAGE_BUGREPORT],[/* Define to the address where bug reports for this package should be sent. */
#ifndef PACKAGE_BUGREPORT
#undef PACKAGE_BUGREPORT
#endif])
AH_VERBATIM([PACKAGE_NAME],[/* Define to the full name of this package. */
#ifndef PACKAGE_NAME
#undef PACKAGE_NAME
#endif])
AH_VERBATIM([PACKAGE_STRING],[/* Define to the full name and version of this package. */
#ifndef PACKAGE_STRING
#undef PACKAGE_STRING
#endif])
AH_VERBATIM([PACKAGE_TARNAME],[/* Define to the one symbol short name of this package. */
#ifndef PACKAGE_TARNAME
#undef PACKAGE_TARNAME
#endif])
AH_VERBATIM([PACKAGE_VERSION],[/* Define to the version of this package. */
#ifndef PACKAGE_VERSION
#undef PACKAGE_VERSION
#endif])
AH_VERBATIM([VERSION],[/* Version number of package */
#ifndef VERSION
#undef VERSION
#endif])
AH_BOTTOM([/* use correct std::ios_base or std::ios (old) */
#ifdef HAVE_IOS_BASE
#define HepIOS std::ios_base
#define HepIOSOpenMode std::ios_base::openmode
#define HepIOSBadBit std::ios_base::badbit
#else
#define HepIOS std::ios
#define HepIOSOpenMode std::ios::open_mode
#define HepIOSBadBit std::ios::badbit
#endif
#endif // STDHEP_DEFS_H])
...
...
StdHep/examples/GNUmakefile
View file @
effb0535
...
...
@@ -10,16 +10,12 @@ ifndef CXX
CXX
=
g++
endif
ifndef
CLHEPdir
CLHEPdir
=
../../..
endif
ifndef
LIBNAME
LIBNAME
=
libCLHEP-
g++.
1.
8
.0.0.a
LIBNAME
=
libCLHEP-1.
9
.0.0.a
endif
ifndef
PythiaLIB
PythiaLIB
=
$(LULIB)
/pdfdum.o
$(LULIB)
/pydata.o
$(LULIB)
/
pyr.o
$(LULIB)
/lib
lund
.a
PythiaLIB
=
$(LULIB)
/pydata.o
$(LULIB)
/
liblund.a
$(LULIB)
/lib
pydum
.a
endif
...
...
@@ -111,11 +107,11 @@ ifeq "$(UNAME)" "SunOS"
LOCAL
=
-L
/opt/SUNWspro/lib
-lm
-lnsl
-lsocket
-lF77
-lM77
-ldbxFintr
-lsunmath
-R
/opt/SUNWspro/lib
endif
INCDIR
=
-I
$(CLHEP
dir)
-I
$(LUND_DIR)
/src/inc
-I
$(HERWIG_DIR)
/src
INCDIR
=
-I
$(CLHEP
_DIR)
/include
-I
$(LUND_DIR)
/src/inc
-I
$(HERWIG_DIR)
/src
CPPFLGS
=
$(KPPFLAGS)
$(INCDIR)
CXXFLAGS
=
$(DFLG)
$(INCDIR)
STDHEPLIB
=
$(CLHEP
dir
)
/lib/
$(LIBNAME)
STDHEPLIB
=
$(CLHEP
_DIR
)
/lib/
$(LIBNAME)
PYTOBJS
=
examPythiaToStdHep
$(SFX)
.o stdpytcxx
$(SFX)
.o dummy
$(SFX)
.o
\
...
...
StdHep/examples/analyzeEvent.cc
View file @
effb0535
...
...
@@ -5,6 +5,8 @@
#include "analyzeEvent.hh"
#include "CLHEP/StdHep/StdEvent.hh"
using
namespace
CLHEP
;
void
analyzeEvent
(
const
StdHep
::
StdEvent
*
event
)
{
// look at an event
...
...
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment