source: MEMPHYS/HEAD/cmt/requirements_osc_16 @ 248

Last change on this file since 248 was 248, checked in by barrand, 17 years ago

G.Barrand : OSC_16

File size: 6.0 KB
Line 
1package MEMPHYS
2version v7r0
3
4#//////////////////////////////////////////////////
5#/// Uses needed to build this package ////////////
6#//////////////////////////////////////////////////
7
8use OpenScientist v16r0
9
10use Geant4 v2r* Interfaces
11
12#//////////////////////////////////////////////////
13#//////////////////////////////////////////////////
14#//////////////////////////////////////////////////
15
16branches run
17
18build_strategy no_prototypes
19include_path none
20
21include_dirs $(MEMPHYSROOT)
22
23# With Geant4 granular libs :
24#macro MEMPHYS_Geant4_incs "${G4readout_incs} ${G4run_incs} ${G4event_incs} ${G4tracking_incs} ${G4processes_use_incs} ${G4digits_hits_incs} ${G4geometry_incs} ${G4materials_incs} ${G4track_incs} ${G4particles_use_incs} ${G4graphics_reps_incs} ${G4intercoms_incs} ${G4global_incs}"
25#macro MEMPHYS_Geant4_linkopts "${G4readout_linkopts} ${G4run_linkopts} ${G4event_linkopts} ${G4tracking_linkopts} ${G4processes_linkopts} ${G4digits_hits_linkopts} ${G4track_linkopts} ${G4particles_linkopts} ${G4geometry_linkopts} ${G4graphics_reps_linkopts} ${G4materials_linkopts} ${G4intercoms_linkopts} ${G4global_linkopts} ${CLHEP_linkopts}"
26
27# With Geant4 global libs :
28macro MEMPHYS_Geant4_incs "-I${Geant4_include}" WIN32 "/I${Geant4_include}"
29macro MEMPHYS_Geant4_linkopts "-L${Geant4_lib} -lG4readout -lG4run -lG4event -lG4tracking -lG4processes -lG4digits_hits -lG4track -lG4particles -lG4geometry -lG4graphics_reps -lG4materials -lG4intercoms -lG4global ${CLHEP_linkopts}"
30
31# Waiting Geant4 DLL on Windows...
32# Darwin : problem too with dylibs.
33macro MEMPHYS_libopts "" WIN32 " -no_share" Darwin " -no_share"
34#macro MEMPHYS_libopts "" WIN32 ""
35
36#//////////////////////////////////////////////////
37#/// Over Geant4 kernel and AIDA interfaces only //
38#//////////////////////////////////////////////////
39
40# Over Geant4 and AIDA only :
41library MEMPHYSCore ${MEMPHYS_libopts} -s=../source *.cxx
42
43#JEC 17/11/05 add the G4readout_incs to manage G4DigiManager
44macro MEMPHYSCore_cppflags "${OSC_AIDA_incs} ${MEMPHYS_Geant4_incs} ${G4readout_incs} ${G4particles_incs} ${G4processes_incs}"
45#macro MEMPHYSCore_shlibflags "${MEMPHYS_Geant4_linkopts}"
46macro MEMPHYSCore_linkopts "-L${MEMPHYSROOT}/$(Platform_bin) -lMEMPHYSCore" WIN32 "${MEMPHYSROOT}\$(Platform_bin)\MEMPHYSCore.lib"
47
48#//////////////////////////////////////////////////
49#/// DLD callbacks ////////////////////////////////
50#//////////////////////////////////////////////////
51
52# Must not use Geant4 singletons if having not Geant4 shared libs.
53macro MEMPHYS_kind "dll"
54library MEMPHYS -s=../source/Callbacks Callbacks.cxx InventorCallbacks.cxx
55#macro MEMPHYS_cppflags "${MEMPHYS_Geant4_incs} ${OSC_OnX_incs}"
56macro MEMPHYS_cppflags "${OSC_Geant4_incs} ${OSC_AIDA_incs} ${OSC_OnX_incs} ${OSC_Inventor_incs}"
57macro MEMPHYS_shlibflags "${OSC_Inventor_linkopts} ${OSC_OnX_linkopts}"
58
59#//////////////////////////////////////////////////
60#/// Application "a la Geant4 examples" ///////////
61#//////////////////////////////////////////////////
62
63# Over Geant4 and AIDA only :
64application MEMPHYS_batch ../applications/MEMPHYS_batch.cxx use_linkopts='"${MEMPHYSCore_linkopts} ${G4physics_lists_hadronic_linkopts} ${MEMPHYS_Geant4_linkopts} ${OSC_AIDA_linkopts}"'
65macro MEMPHYS_batch_cppflags "${MEMPHYSCore_cppflags} ${G4physics_lists_hadronic_incs}"
66
67# Over AIDA only :
68application MEMPHYS_analysis ../applications/MEMPHYS_analysis.cxx use_linkopts='"$(OSC_AIDA_linkopts)"'
69
70# Over G4Lab :
71application MEMPHYS_session ../applications/MEMPHYS_session.cxx ../applications/HitsCollectionAccessor.cxx use_linkopts='"${MEMPHYSCore_linkopts} ${G4physics_lists_hadronic_linkopts}  ${OSC_Geant4_linkopts} ${MEMPHYS_Geant4_linkopts} ${OSC_Inventor_linkopts} ${OSC_OnX_linkopts}"'
72macro MEMPHYS_session_cppflags "${MEMPHYS_Geant4_incs} ${MEMPHYS_batch_cppflags}"
73
74application test -group=debug -s=../source test.cxx
75
76#//////////////////////////////////////////////////
77#/// Things using ROOT ////////////////////////////
78#//////////////////////////////////////////////////
79use ROOT v1r* Interfaces
80
81# Example of ROOT program to work on a MEMPHYS.root file :
82application MEMPHYS_analysis_ROOT -group=ROOT ../applications/MEMPHYS_analysis_ROOT.cxx use_linkopts='"${ROOT_Gpad_linkopts} ${ROOT_freetype_linkopts} ${ROOT_Graf_linkopts} ${ROOT_Tree_linkopts} ${ROOT_Hist_linkopts} ${ROOT_Matrix_linkopts} ${ROOT_Core_linkopts} ${ROOT_Cint_linkopts}"'
83
84# Compiled version of scripts/ROOT/aida.C
85application MEMPHYS_analysis_aida_ROOT -group=ROOT ../applications/MEMPHYS_analysis_aida_ROOT.cxx use_linkopts='"${OSC_AIDA_linkopts} ${ROOT_Gpad_linkopts} ${ROOT_freetype_linkopts} ${ROOT_Graf_linkopts} ${ROOT_Hist_linkopts} ${ROOT_Matrix_linkopts} ${ROOT_Core_linkopts} ${ROOT_Cint_linkopts}"'
86macro MEMPHYS_analysis_aida_ROOT_cppflags "${OSC_AIDA_incs}"
87
88# Declare AIDA to rootcint.
89# See scripts/ROOT/aida.C for a usage example.
90
91macro MEMPHYS_cint_cintflags "${OSC_AIDA_incs}"
92macro MEMPHYS_cint_LinkDef_h "../source/ROOT/LinkDef.h"
93document rootcint MEMPHYS_rootcint_AIDA -group=ROOT ${MEMPHYSROOT}/source/ROOT/MEMPHYS_cint.h
94
95library MEMPHYSAIDADict -group=ROOT -import=ROOT ${dict}/MEMPHYS_cintDict.cpp
96macro MEMPHYSAIDADict_shlibflags "$(OSC_AIDA_linkopts) ${ROOT_Core_linkopts} ${ROOT_Cint_linkopts}"
97
98#//////////////////////////////////////////////////
99#//////////////////////////////////////////////////
100#//////////////////////////////////////////////////
101
102private
103macro build_library_links "true" WIN32 ""
104macro remove_library_links "true" WIN32 ""
105
106# WIN32 : /GR to enable RTTI and dynamic cast.
107# WIN32 : /GX to enable exception handling (for STL).
108macro_append cppflags "" WIN32 " /GX /GR"
109
110# DEBUG :
111#macro_append cflags  " -g" WIN32 " /ZI /Od"
112#macro_append cppflags  " -g" WIN32 " /ZI /Od"
113#macro_append cpplinkflags  " -g" WIN32 " /DEBUG"
114
115# OPTIMIZE :
116macro_append cflags  " -O" WIN32 " /O2"
117macro_append cppflags  " -O" WIN32 " /O2"
118macro_append cpplinkflags  " -O" WIN32 ""
119public
120
121#//////////////////////////////////////////////////
122#// Run time //////////////////////////////////////
123#//////////////////////////////////////////////////
124
125apply_pattern Platform_paths
126
Note: See TracBrowser for help on using the repository browser.