1 | package bhep |
---|
2 | version v1r4p2 |
---|
3 | |
---|
4 | #////////////////////////////////////////////////// |
---|
5 | # |
---|
6 | # This file assumes the following |
---|
7 | # directory structure : |
---|
8 | # bhep/<version>/cmt |
---|
9 | # bhep/<version>/source/base/... |
---|
10 | # bhep/<version>/source/util/... |
---|
11 | # and a : |
---|
12 | # bhep/<version>/bhep |
---|
13 | # containing a copy of the .h from the source |
---|
14 | # directory along with the config.h found |
---|
15 | # in this directory. |
---|
16 | # |
---|
17 | #////////////////////////////////////////////////// |
---|
18 | |
---|
19 | #////////////////////////////////////////////////// |
---|
20 | use zlib v1r* Interfaces |
---|
21 | use HDF5 v1r* Interfaces |
---|
22 | use CLHEP v1r* Interfaces |
---|
23 | #////////////////////////////////////////////////// |
---|
24 | |
---|
25 | build_strategy no_prototypes |
---|
26 | include_path none |
---|
27 | |
---|
28 | include_dirs $(BHEPROOT) $(BHEPROOT)/bhep |
---|
29 | |
---|
30 | #////////////////////////////////////////////////// |
---|
31 | # No dependency over other libs. |
---|
32 | |
---|
33 | library bhep -s=../source \ |
---|
34 | version.cpp \ |
---|
35 | base/event.cpp \ |
---|
36 | base/hit.cpp \ |
---|
37 | base/mparticle.cpp \ |
---|
38 | base/particle.cpp \ |
---|
39 | base/sparticle.cpp \ |
---|
40 | base/track.cpp \ |
---|
41 | util/material.cpp \ |
---|
42 | util/particle_definition.cpp \ |
---|
43 | util/ray.cpp \ |
---|
44 | converters/event_cvt.cpp \ |
---|
45 | converters/hit_cvt.cpp \ |
---|
46 | converters/mparticle_cvt.cpp \ |
---|
47 | converters/particle_cvt.cpp \ |
---|
48 | converters/sparticle_cvt.cpp \ |
---|
49 | converters/track_cvt.cpp \ |
---|
50 | manager/base_reader.cpp \ |
---|
51 | manager/bhep_svc.cpp \ |
---|
52 | manager/brw.cpp \ |
---|
53 | manager/converter_svc.cpp \ |
---|
54 | manager/random_reader.cpp \ |
---|
55 | manager/random_writer.cpp \ |
---|
56 | manager/reader_gz.cpp \ |
---|
57 | manager/reader_hdf5.cpp \ |
---|
58 | manager/reader_txt.cpp \ |
---|
59 | manager/sequential_reader.cpp \ |
---|
60 | manager/sequential_writer.cpp \ |
---|
61 | manager/writer_gz.cpp \ |
---|
62 | manager/writer_hdf5.cpp \ |
---|
63 | manager/writer_txt.cpp \ |
---|
64 | examples/generate_event.cpp \ |
---|
65 | tutorials/gevent.cpp \ |
---|
66 | histos/axis.cpp \ |
---|
67 | histos/histogram.cpp \ |
---|
68 | tools/EventManager.cpp |
---|
69 | |
---|
70 | macro bhep_cppflags "" |
---|
71 | macro bhep_shlibflags "${CLHEP_linkopts} ${HDF5_linkopts} ${zlib_linkopts}" |
---|
72 | macro bhep_linkopts "-L${BHEPROOT}/$(CMTCONFIG) -lbhep" |
---|
73 | |
---|
74 | #////////////////////////////////////////////////// |
---|
75 | #/// compile, link flags ////////////////////////// |
---|
76 | #////////////////////////////////////////////////// |
---|
77 | private |
---|
78 | # WIN32 : /GR to enable RTTI and dynamic cast. |
---|
79 | # WIN32 : /GX to enable exception handling (for STL). |
---|
80 | macro_append cppflags "" WIN32 " /GX /GR" |
---|
81 | |
---|
82 | # DEBUG : |
---|
83 | #macro_append cflags " -g" WIN32 " /ZI /Od" |
---|
84 | #macro_append cppflags " -g" WIN32 " /ZI /Od" |
---|
85 | #macro_append cpplinkflags " -g" WIN32 " /DEBUG /VERBOSE:LIB" |
---|
86 | |
---|
87 | # OPTIMIZE : |
---|
88 | macro_append cflags " -O" WIN32 " /O2" |
---|
89 | macro_append cppflags " -O" WIN32 " /O2" |
---|
90 | macro_append cpplinkflags " -O" WIN32 "" |
---|
91 | |
---|
92 | macro build_library_links "true" WIN32 "" |
---|
93 | macro remove_library_links "true" WIN32 "" |
---|
94 | public |
---|
95 | |
---|
96 | #////////////////////////////////////////////////// |
---|
97 | #/// Run time ///////////////////////////////////// |
---|
98 | #////////////////////////////////////////////////// |
---|
99 | |
---|
100 | pattern setup_paths \ |
---|
101 | path_remove LD_LIBRARY_PATH "${<PACKAGE>ROOT}/$(CMTCONFIG)" WIN32 "" Darwin "" ;\ |
---|
102 | path_append LD_LIBRARY_PATH "${<PACKAGE>ROOT}/$(CMTCONFIG)" WIN32 "" Darwin "" ;\ |
---|
103 | path_remove DYLD_LIBRARY_PATH "" Darwin "${<PACKAGE>ROOT}/$(CMTCONFIG)" ;\ |
---|
104 | path_append DYLD_LIBRARY_PATH "" Darwin "${<PACKAGE>ROOT}/$(CMTCONFIG)" ;\ |
---|
105 | path_remove PATH "${<PACKAGE>ROOT}/$(CMTCONFIG)" WIN32 "${<PACKAGE>ROOT}\$(CMTCONFIG)" ;\ |
---|
106 | path_append PATH "${<PACKAGE>ROOT}/$(CMTCONFIG)" WIN32 "${<PACKAGE>ROOT}\$(CMTCONFIG)" |
---|
107 | |
---|
108 | apply_pattern setup_paths |
---|
109 | |
---|
110 | |
---|
111 | |
---|
112 | |
---|