source: tags/Mars-V0.3/Makefile@ 13217

Last change on this file since 13217 was 714, checked in by tbretz, 24 years ago
*** empty log message ***
File size: 2.8 KB
Line 
1##################################################################
2#
3# makefile
4#
5# for the MARS software
6#
7##################################################################
8# @maintitle
9
10# @code
11
12#
13# please change all system depend values in the
14# config.mk.${OSTYPE} file
15#
16#
17include Makefile.conf.$(OSTYPE)
18include Makefile.conf.general
19
20#
21
22PROGRAMS = merpp readraw mars
23SOLIB = mars.so
24CINT = M
25
26#
27# connect the include files defined in the config.mk file
28#
29# WARNING: the result (whether the linkage works or not) depends on the
30# order of the libraries. It seems, that the most base library
31# must be the last one
32#
33
34#
35# ----->>> mars libraries
36#
37SUBDIRS = mgui \
38 mmain \
39 manalysis \
40 meventdisp \
41 mdatacheck \
42 mmontecarlo \
43 mhist \
44 mbase \
45 mraw \
46 mmc
47
48LIBRARIES = $(SUBDIRS:=.a)
49
50#------------------------------------------------------------------------------
51
52.SUFFIXES: .c .cc .h .o
53
54SRCFILES =
55
56SRCS = $(SRCFILES)
57HEADERS = $(SRCFILES:.cc=.h)
58OBJS = $(SRCFILES:.cc=.o)
59
60############################################################
61
62all: rmlib $(PROGRAMS) $(SOLIB)
63
64# Use $(CXX) -v ... for a more verbose output
65#
66# We could link mars.so instead of all libraries. This would need
67# some MBs less space on the HD. But this means, that the Shared
68# Library Path in your system must be set properly to be able to start
69# 'mars'
70#
71$(PROGRAMS): $(LIBRARIES) $(OBJS) $(HEADERS) MCint.o $(PROGRAMS:=.o)
72 @echo " Linking $@ ..."
73 $(CXX) $(CXXFLAGS) $@.o $(OBJS) $(MARS_LIB) MCint.o $(ROOTGLIBS) -o $@
74
75$(SOLIB): $(LIBRARIES) $(OBJS) $(HEADERS) MCint.o
76 @echo " Linking $(SOLIB) ..."
77 $(CXX) -shared $(CXXFLAGS) $(SUBDIRS:=/*.o) $(ROOTGLIBS) -o $@
78 mv mars.so lib
79
80$(LIBRARIES):
81 @echo " "
82 @echo " Creating lib$@:"
83 (cd $*; make; cd ..; mv $*/$@ lib/lib$@)
84
85dox:
86 @echo " Creating html documentation:"
87 root -b -q dohtml.C
88
89include Makefile.rules
90
91clean: rmlib rmcint rmobjs rmcore rmbin
92
93mrproper: clean rmbak
94 @rm -f macros/*~
95 @rm -rf htmldoc
96 @echo "cd mbase"
97 @cd mbase; make mrproper; cd ..
98 @echo "cd .."
99 @echo "cd mraw"
100 @cd mraw; make mrproper; cd ..
101 @echo "cd .."
102 @echo "cd mhist"
103 @cd mhist; make mrproper; cd ..
104 @echo "cd .."
105 @echo "cd mgui"
106 @cd mgui; make mrproper; cd ..
107 @echo "cd .."
108 @echo "cd mdatacheck"
109 @cd mdatacheck; make mrproper; cd ..
110 @echo "cd .."
111 @echo "cd mmc"
112 @cd mmc; make mrproper; cd ..
113 @echo "cd .."
114 @echo "cd meventdisp"
115 @cd meventdisp; make mrproper; cd ..
116 @echo "cd .."
117 @echo "cd manalysis"
118 @cd manalysis; make mrproper; cd ..
119 @echo "cd .."
120 @echo "cd mmontecarlo"
121 @cd mmontecarlo; make mrproper; cd ..
122 @echo "cd .."
123 @echo "cd mmain"
124 @cd mmain; make mrproper; cd ..
125 @echo "cd .."
126
127tar: mrproper
128 @echo "Making tar-file"
129 @tar -cvf ../mars.tar *
130 @gzip -9 ../mars.tar
131
132# @endcode
Note: See TracBrowser for help on using the repository browser.