Debian Codegraph @

doris_core/Makefile.debug-full

raw
1 #########################################################################
2 # Makefile for the Doris software. #
3 # Created by: configure #
4 # 04-Dec-1998 Delft University of Technology, Geodesy #
5 # Bert Kampes ([email protected]) #
6 # http://enterprise.geo.tudelft.nl/doris/ #
7 # See also the user manual, annex installation. #
8 # #
9 ### Usage ### #
10 # The command: "make" creates and optimized version of doris. #
11 # The command: "make install" installs it andcleans up. #
12 # If this does not work, try a more controlled approach by: #
13 # #
14 # 0. inspect set up of this Makefile #
15 # 1. set CC DEFS LIBS etc., first set these to debug values #
16 # (read NOTE there if problems) #
17 # 2. compile software sources to *.o: "make swobjs" #
18 # 3. link object together to executable: "make doris" #
19 # 4. install executable: "make install" #
20 # 5. remove object files: "make clean" #
21 # #
22 # BTW. "make" does "swobjs doris" by default. #
23 # #
24 ### #
25 # Successfully tested for compilers/platforms: #
26 # GNU g++ version 2.7.2.2 on HP-UX B.10.20 A 9000/785 #
27 # GNU g++ version 2.95.2 on HP-UX B.10.20 A 9000/785 #
28 # HP aCC version A.01.07 on HP-UX B.10.20 A 9000/785 #
29 # GNU g++ version ? on Linux X86 #
30 # SGI ? #
31 #########################################################################
32 ###################################################################
33 ###################################################################
34 # Please change if required: DEF[1-6], CC, CFLAGS, LIBDIR, ###
35 ###################################################################
36 ### The shell used by this makefile ###
37 SHELL = /bin/sh
38
39 ### Specify compiler/installation directory ###
40 INSTALLDIR = /usr/local/bin
41 CC = g++
42 SCRIPTSDIR = ../bin
43
44 ### Define statements controlling compilation ###
45 # Comment out DEF[1-8] statements when appropriate.
46 DEF1 = -D__DEBUGMAT1 # -1- range checking in matrix class
47 DEF2 = -D__DEBUGMAT2 # -2- info matrix class (debug only)
48 DEF3 = -D__DEBUG # -3- debug for other files
49 DEF4 = -Wno-deprecated -trigraphs # -4- do not display warnings
50 DEF5 = -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE # support for large files
51 #DEF9 = -D__NO_IOS_BINARY__ # -9- comment out if you ios::binary (most will)
52 #
53 ### Do not change following 2, simply comment DEF1-8 above
54 DEFSDEBUG = $(DEF1) $(DEF2) $(DEF3)
55 DEFS = $(DEF4) $(DEF5) -D__USE_FFTW_LIBRARY__ -D__X86PROCESSOR__ -I/usr/include
56
57 ### NOTE ###
58 # If you get warnings like the following (I got them with g++, not with aCC)
59 # then use define __GNUC__ to define these functions
60 #%// BK 15-Aug-2000
61 #In file included from matrixbk.h:38,
62 # from processor.cc:23:
63 #constants.h: In method `real8 cn::dist(cn) const':
64 #constants.h:106: implicit declaration of function `int sqr(...)'
65 ### END NOTE ###
66
67
68
69 ### CFLAGS ###
70 # Compiler options flag ###
71 # Specify compiler flags (I selected these for g++)
72 CFLAGSDEBUG = -g -O $(DEFS) $(DEFSDEBUG)
73 CFLAGSOPT = -O $(DEFS)
74 #CFLAGSOPT = -O2 $(DEFS) # this crashed doris! (?)
75 #CFLAGSOPT = -O3 $(DEFS) # this crashed doris! (?)
76
77 ### CCNOTE ###
78 ### Change here ###
79 ### set CFLAGS depending on if you compile debug version or working version ###
80 CFLAGS = $(CFLAGSDEBUG)
81 #CFLAGS = $(CFLAGSOPT)
82 ### END CCNOTE ###
83
84 ### Library locations flag ###
85 ### -lcl : used for veclib
86 ### -lm : used for fftw
87 LFLAGS = -L/usr/lib -lfftw3f -lm
88
89
90 #####################################################
91 ### No need to change anything below here... ####
92 #####################################################
93 EXECUTABLE = doris394.debug
94
95 SWSRCS = processor.cc \
96 utilities.cc \
97 ioroutines.cc \
98 readinput.cc \
99 readdata.cc \
100 coregistration.cc \
101 filtering.cc \
102 referencephase.cc \
103 products.cc \
104 geocode.cc \
105 unwrap.cc \
106 matrixspecs.cc \
107 exceptions.cc
108 SWOBJS = $(SWSRCS:.cc=.o)
109
110 ### scripts of doris.tar in SCRIPTSDIR, used at make install
111 SCRIPTS = helpdoris \
112 baseline.doris \
113 coregpm.doris \
114 heightamb \
115 phasefilt.doris \
116 plotcpm \
117 plotoffsets \
118 run \
119 viewanddel \
120 cpx2ps \
121 lonlathei2ascii \
122 ascii2ascii_UTM \
123 ascii2ps
124
125
126
127 #####################################################
128 ### And no need to change anything below here... ####
129 #####################################################
130 ### what to do if make w/o arguments ###
131 # first make all object files, then link them together
132 default: $(EXECUTABLE)
133
134
135 ### how to compile object code .o from C++ source files .cc (general rule) ###
136 # space between -o and filename for SUN make (BK 7 july 2000)
137 .cc.o:
138 $(CC) $(CFLAGS) -c -o $(@) $<
139
140 #####################################################
141 ### Make object code from source ###
142 swobjs: $(SWOBJS)
143
144
145 ### Load objects to executable ###
146 ### The added .cc files contain class definitions
147 ### matrixclass is explicitly included
148 ### in the source code since we had some problems finding out how to do that
149 ### here, since compilers treat the template class differently than normal classes.
150 ### BK 07-Feb-2002
151 $(EXECUTABLE): $(SWOBJS) tmp_strptime.cc slcimage.cc productinfo.cc orbitbk.cc
152 $(CC) $(CFLAGS) -c -o triangle.o -DTRILIBRARY -DANSI_DECLARATORS triangle.c
153 $(CC) $(CFLAGS)\
154 tmp_strptime.cc $(SWOBJS) triangle.o\
155 slcimage.cc productinfo.cc orbitbk.cc\
156 $(LFLAGS) -o $@
157 @echo " "
158 @echo "*******************************"
159 @echo "* ...Compilation finished... *"
160 @echo "*******************************"
161 @echo " "
162
163
164 ### Install executable in installdir ###
165 install: $(EXECUTABLE)
166 @echo "* Installing $(EXECUTABLE) in: $(INSTALLDIR)"
167 @cp -f $(EXECUTABLE) $(INSTALLDIR)/.
168 ( cd $(SCRIPTSDIR); cp -f $(SCRIPTS) $(INSTALLDIR)/. )
169 $(MAKE) cleaner
170 @echo " "
171 @echo "*******************************"
172 @echo "* ...Installation finished... *"
173 @echo "*******************************"
174 @echo " "
175
176
177
178 #####################################################
179 ### Testers ###
180 test: testdoris
181 testdoris: $(EXECUTABLE)
182 @echo " "
183 @echo "* Executing command: $(EXECUTABLE) -v"
184 $(EXECUTABLE) -v
185 @echo " "
186 testorbit: ioroutines.o matrixspecs.o readinput.o utilities.o
187 $(CC) $(CFLAGS) orbitbk.cc -D__TESTMAIN__ \
188 ioroutines.o matrixspecs.o readinput.o utilities.o \
189 -o $@
190 ### Matrix test program for debugging ###
191 ### fast_sin defined in utilities.cc, which requires ioroutines, which, etc.
192 matrixbk_test: matrixbk_test.o matrixspecs.o utilities.o
193 $(CC) $(CFLAGS) matrixbk_test.o matrixspecs.o \
194 utilities.o ioroutines.o exceptions.cc orbitbk.cc \
195 $(LFLAGS) \
196 -o $@
197
198
199 #####################################################
200 ### Cleaners ###
201 clean: cleanswobjs
202
203 cleaner: clean cleanprog
204 cleanest: clean cleanprog uninstall
205 cleanprog:
206 @rm -f $(EXECUTABLE) $(EXECUTABLE.debug) \
207 matrixbk_test testorbit
208 @echo "* Removed executables in current dir."
209 cleanswobjs:
210 @rm -f $(SWOBJS) matrixbk_test.o orbitbk.o slcimage.o triangle.o
211 @echo "* Removed object files."
212 uninstall:
213 @rm -f $(INSTALLDIR)/$(EXECUTABLE)
214 @echo "* Removed executables in install dir: $(INSTALLDIR)."
215
216 ### BK 12-Dec-2000 ###
217