1 | # Generated automatically from Makefile.in by configure.- |
---|
2 | ################################################################# |
---|
3 | ### |
---|
4 | ### Makefile for Singular |
---|
5 | ### |
---|
6 | ################################################################# |
---|
7 | |
---|
8 | SHELL = /bin/sh |
---|
9 | |
---|
10 | ## |
---|
11 | ## version |
---|
12 | ## |
---|
13 | SINGULAR_VERSION = spielwiese |
---|
14 | ## |
---|
15 | ## various paths |
---|
16 | ## |
---|
17 | srcdir = . |
---|
18 | includedir = ../libpolys |
---|
19 | |
---|
20 | ## |
---|
21 | ## various programs |
---|
22 | ## |
---|
23 | |
---|
24 | CC = gcc |
---|
25 | LD = ld |
---|
26 | CXX = g++ |
---|
27 | PERL = perl |
---|
28 | INSTALL = /usr/bin/install -c |
---|
29 | INSTALL_PROGRAM = ${INSTALL} |
---|
30 | INSTALL_DATA = ${INSTALL} -m 644 |
---|
31 | MKINSTALLDIRS = ./mkinstalldirs |
---|
32 | LN_S = ln -s |
---|
33 | |
---|
34 | ## |
---|
35 | ## compiler and linker options |
---|
36 | ## |
---|
37 | LIBPOLYS_CFLAGS = `sh ../libpolys/libpolys-config --cflags` |
---|
38 | |
---|
39 | PIPE = -pipe |
---|
40 | CFLAGS = -O3 -w -fomit-frame-pointer ${PIPE} ${LIBPOLYS_CFLAGS} |
---|
41 | CXXFLAGS = -O3 -w -fomit-frame-pointer --no-rtti ${PIPE} ${LIBPOLYS_CFLAGS} |
---|
42 | CXXTEMPLFLAGS = -fno-implicit-templates --no-exceptions |
---|
43 | CPPFLAGS = -I${srcdir} -I.. -I${includedir} ${LIBPOLYS_CFLAGS} |
---|
44 | DEFS = -DNDEBUG -DOM_NDEBUG |
---|
45 | LDFLAGS = -L${srcdir}/lib |
---|
46 | LD_DYN_FLAGS = -ldl -rdynamic |
---|
47 | SFLAGS = -fpic -DPIC |
---|
48 | SLDFLAGS = -shared |
---|
49 | |
---|
50 | LD_LIBC = -lc |
---|
51 | STATIC_LDFLAGS = -static |
---|
52 | LIBS = -lm -lsingfac -lsingcf -lntl -lgmp -lreadline -lncurses -lm -lnsl -lomalloc_ndebug |
---|
53 | MP_LIBS = -lMPT -lMP -lnsl |
---|
54 | |
---|
55 | ## End configuration dependend stuff |
---|
56 | ################################################################# |
---|
57 | |
---|
58 | ### |
---|
59 | ### file sets |
---|
60 | ### |
---|
61 | |
---|
62 | # normal C++ source files |
---|
63 | CXXSOURCES=\ |
---|
64 | Minor.cc\ |
---|
65 | MinorInterface.cc\ |
---|
66 | MinorProcessor.cc\ |
---|
67 | attrib.cc\ |
---|
68 | bbcone.cc\ |
---|
69 | bbfan.cc\ |
---|
70 | bigintm.cc\ |
---|
71 | blackbox.cc\ |
---|
72 | calcSVD.cc\ |
---|
73 | cntrlc.cc\ |
---|
74 | denom_list.cc\ |
---|
75 | eigenval_ip.cc\ |
---|
76 | emacs.cc\ |
---|
77 | extra.cc\ |
---|
78 | feOpt.cc\ |
---|
79 | fehelp.cc\ |
---|
80 | fevoices.cc \ |
---|
81 | fglm.cc\ |
---|
82 | gentable.cc\ |
---|
83 | gentable2.cc\ |
---|
84 | gms.cc\ |
---|
85 | grammar.cc\ |
---|
86 | interpolation.cc\ |
---|
87 | iparith.cc\ |
---|
88 | ipassign.cc\ |
---|
89 | ipconv.cc\ |
---|
90 | ipid.cc\ |
---|
91 | iplib.cc\ |
---|
92 | ipprint.cc\ |
---|
93 | ipshell.cc\ |
---|
94 | janet.cc\ |
---|
95 | libparse.cc\ |
---|
96 | linearAlgebra_ip.cc\ |
---|
97 | lists.cc\ |
---|
98 | maps_ip.cc\ |
---|
99 | minpoly.cc\ |
---|
100 | misc_ip.cc\ |
---|
101 | mpsr_Error.cc\ |
---|
102 | mpsr_Get.cc\ |
---|
103 | mpsr_GetMisc.cc\ |
---|
104 | mpsr_GetPoly.cc\ |
---|
105 | mpsr_Put.cc\ |
---|
106 | mpsr_PutPoly.cc\ |
---|
107 | mpsr_Timer.cc\ |
---|
108 | mpsr_Tok.cc\ |
---|
109 | mpsr_sl.cc\ |
---|
110 | ndbm.cc\ |
---|
111 | newstruct.cc\ |
---|
112 | pcv.cc\ |
---|
113 | pipeLink.cc\ |
---|
114 | pyobject.cc\ |
---|
115 | pyobject_setup.cc\ |
---|
116 | scanner.cc\ |
---|
117 | sdb.cc\ |
---|
118 | silink.cc\ |
---|
119 | sing_dbm.cc\ |
---|
120 | sing_win.cc\ |
---|
121 | slInit_Dynamic.cc\ |
---|
122 | slInit_Static.cc\ |
---|
123 | ssiLink.cc\ |
---|
124 | subexpr.cc\ |
---|
125 | tesths.cc\ |
---|
126 | utils.cc\ |
---|
127 | walk.cc\ |
---|
128 | walk_ip.cc\ |
---|
129 | wrapper.cc |
---|
130 | |
---|
131 | CXXSOURCES2 = SingularBuilder.cpp |
---|
132 | |
---|
133 | # special C++ source files (need extra compiling and/or linking), for which |
---|
134 | # dependencies should be generated |
---|
135 | ESOURCES=claptmpl.cc |
---|
136 | |
---|
137 | SOURCES=${CSOURCES} ${CXXSOURCES} \ |
---|
138 | kInline.h |
---|
139 | |
---|
140 | HEADERS=\ |
---|
141 | Cache.h \ |
---|
142 | CacheImplementation.h \ |
---|
143 | Minor.h \ |
---|
144 | MinorInterface.h \ |
---|
145 | MinorProcessor.h \ |
---|
146 | attrib.h \ |
---|
147 | bbcone.h \ |
---|
148 | bigintm.h \ |
---|
149 | blackbox.h \ |
---|
150 | cntrlc.h \ |
---|
151 | dbm_sl.h \ |
---|
152 | distrib.h \ |
---|
153 | eigenval_ip.h \ |
---|
154 | feOpt.h \ |
---|
155 | gms.h \ |
---|
156 | grammar.h \ |
---|
157 | interpolation.h \ |
---|
158 | ipconv.h \ |
---|
159 | ipid.h \ |
---|
160 | ipprint.h \ |
---|
161 | ipshell.h \ |
---|
162 | janet.h \ |
---|
163 | libparse.h \ |
---|
164 | libsingular.h \ |
---|
165 | lists.h \ |
---|
166 | locals.h \ |
---|
167 | maps_ip.h \ |
---|
168 | minpoly.h \ |
---|
169 | misc_ip.h \ |
---|
170 | mpsr.h \ |
---|
171 | mpsr_Get.h \ |
---|
172 | mpsr_Put.h \ |
---|
173 | mpsr_Timer.h \ |
---|
174 | mpsr_Tok.h \ |
---|
175 | mpsr_sl.h \ |
---|
176 | ndbm.h \ |
---|
177 | newstruct.h \ |
---|
178 | omSingularConfig.h \ |
---|
179 | pcv.h \ |
---|
180 | pipeLink.h \ |
---|
181 | pyobject_setup.h \ |
---|
182 | run.h \ |
---|
183 | sdb.h \ |
---|
184 | silink.h \ |
---|
185 | sing_dbm.h \ |
---|
186 | sing_win.h \ |
---|
187 | slInit.h \ |
---|
188 | ssiLink.h \ |
---|
189 | static.h \ |
---|
190 | stype.h \ |
---|
191 | subexpr.h \ |
---|
192 | table.h \ |
---|
193 | tok.h \ |
---|
194 | utils.h \ |
---|
195 | walk.h |
---|
196 | |
---|
197 | |
---|
198 | OBJS := $(CXXSOURCES:.cc=.o) $(CSOURCES:.c=.o) #$(CXXSOURCES2:.cpp=.o) |
---|
199 | OBJS2 := $(ESOURCES:.cc=.o) |
---|
200 | OBJSG2 := $(ESOURCES:.cc=.og) |
---|
201 | OBJSP2 := $(ESOURCES:.cc=.op) |
---|
202 | |
---|
203 | ## |
---|
204 | ## Build Targets |
---|
205 | ## |
---|
206 | .cc.o: |
---|
207 | ${CXX} ${CXXFLAGS} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFS} -c $< |
---|
208 | .c.o: |
---|
209 | ${CC} ${CFLAGS} ${CPPFLAGS} ${DEFS} -c $< |
---|
210 | |
---|
211 | OBJG= $(CXXSOURCES:.cc=.og) $(CSOURCES:.c=.og) |
---|
212 | |
---|
213 | OBJG := $(OBJG) $(STATIC_SOURCES:.cc=.og) |
---|
214 | OBJP := $(OBJP) $(STATIC_SOURCES:.cc=.op) |
---|
215 | |
---|
216 | all: Singular |
---|
217 | |
---|
218 | Singular: ${OBJS} |
---|
219 | |
---|
220 | ## |
---|
221 | ## clean targest |
---|
222 | ## |
---|
223 | mostlyclean: |
---|
224 | -rm -f *.o *.og core *.op |
---|
225 | |
---|
226 | clean: mostlyclean |
---|
227 | -rm -f *.bak *.d *.dd depend *.a *.so* |
---|
228 | |
---|
229 | distclean: clean |
---|
230 | -rm -f *~ .\#* |
---|
231 | -rm -f mod2.h Makefile TAGS* tags config.status config.cache config.log |
---|
232 | |
---|
233 | srcclean: |
---|
234 | @echo "This command is intended for maintainers to use;" |
---|
235 | @echo "Rebuilding the deleted files requires flex" |
---|
236 | @echo "bison, perl" |
---|
237 | |
---|
238 | maintainer-clean: distclean srcclean |
---|
239 | @echo "This command is intended for maintainers to use;" |
---|
240 | @echo "Rebuilding the deleted files requires flex" |
---|
241 | @echo "bison, perl and autoconf" |
---|
242 | |
---|
243 | ## |
---|
244 | ## miscellanous targets |
---|
245 | ## |
---|
246 | |
---|
247 | TAGS: ${SOURCES} ${ESOURCES} ${HEADERS} |
---|
248 | etags ${SOURCES} ${ESOURCES} ${HEADERS} |
---|
249 | |
---|
250 | tags: |
---|
251 | ctags *.c *.h *.cc *.inc |
---|
252 | |
---|
253 | ## |
---|
254 | ## Below here is stuff for developpers |
---|
255 | ################################################################# |
---|
256 | |
---|
257 | |
---|
258 | ## |
---|
259 | ## .og files for having -O and -g object versions available at the same time |
---|
260 | ## |
---|
261 | |
---|
262 | OBJG1 := $(CXXSOURCES:.cc=.og) |
---|
263 | OBJG2 := $(CSOURCES:.c=.og) |
---|
264 | |
---|
265 | ## |
---|
266 | ## compiler and linker options for debug version |
---|
267 | ## |
---|
268 | |
---|
269 | CCG = ${CC} |
---|
270 | CXXG = ${CXX} -Wall |
---|
271 | CXXM = gcc -MM -MG -DGENERATE_DEPEND |
---|
272 | CCM = gcc -MM -MG -DGENERATE_DEPEND |
---|
273 | |
---|
274 | CFLAGSG = -g ${PIPE} ${LIBPOLYS_CFLAGS} |
---|
275 | CXXFLAGSG = -g ${PIPE} ${LIBPOLYS_CFLAGS} |
---|
276 | DEFSG = |
---|
277 | |
---|
278 | ## |
---|
279 | ## Debug Targets |
---|
280 | ## |
---|
281 | |
---|
282 | %.og: %.cc |
---|
283 | $(CXXG) ${CXXFLAGSG} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFSG} -c $< -o $@ |
---|
284 | |
---|
285 | $(OBJG2) : %.og: %.c |
---|
286 | $(CCG) ${CFLAGSG} ${CPPFLAGS} ${DEFSG} -c $< -o $@ |
---|
287 | |
---|
288 | libkernel_g.a: ${OBJG} ${OBJSG2} |
---|
289 | -rm -f libkernel_g.a |
---|
290 | ar cr $@ ${OBJG} |
---|
291 | |
---|
292 | |
---|
293 | |
---|
294 | ## |
---|
295 | ## .op files for profiling |
---|
296 | ## |
---|
297 | |
---|
298 | OBJP1 := $(CXXSOURCES:.cc=.op) |
---|
299 | OBJP2 := $(CSOURCES:.c=.op) |
---|
300 | |
---|
301 | OBJP=$(OBJP1) $(OBJP2) |
---|
302 | |
---|
303 | OBJP := $(OBJP) $(STATIC_SOURCES:.cc=.op) |
---|
304 | |
---|
305 | ## |
---|
306 | ## compiler and linker options for profiling version |
---|
307 | ## |
---|
308 | |
---|
309 | CCP = ${CC} |
---|
310 | CXXP = ${CXX} |
---|
311 | |
---|
312 | CFLAGSP = -g -pg -O ${PIPE} ${LIBPOLYS_CFLAGS} |
---|
313 | CXXFLAGSP = -g -pg -O ${PIPE} ${LIBPOLYS_CFLAGS} |
---|
314 | DEFSP = |
---|
315 | |
---|
316 | |
---|
317 | |
---|
318 | |
---|
319 | ## |
---|
320 | ## Profiling Targets |
---|
321 | ## |
---|
322 | |
---|
323 | %.op: %.cc |
---|
324 | $(CXXP) ${CXXFLAGSP} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFSP} -c $< -o $@ |
---|
325 | |
---|
326 | $(OBJP2) : %.op: %.c |
---|
327 | $(CCP) ${CFLAGSP} ${CPPFLAGS} ${DEFSP} -c $< -o $@ |
---|
328 | |
---|
329 | libkernel_p.a: ${OBJP} ${OBJSP2} |
---|
330 | -rm -f libkernel_p.a |
---|
331 | ar cr $@ ${OBJP} |
---|
332 | |
---|
333 | ## |
---|
334 | ## dependencies |
---|
335 | ## |
---|
336 | |
---|
337 | %.dd: %.cc mod2.h |
---|
338 | echo $(@:.dd=.og) $(@:.dd=.op) " " \\ > $@ |
---|
339 | $(CXXM) -DGENTABLE ${CPPFLAGS} ${DEFSG} $< >> $@ |
---|
340 | |
---|
341 | %.d: %.c mod2.h |
---|
342 | echo $(@:.d=.og) $(@:.d=.op) " " \\ > $@ |
---|
343 | $(CCM) ${CPPFLAGS} ${DEFSG} $< >> $@ |
---|
344 | |
---|
345 | depend: $(CXXSOURCES:.cc=.dd) $(ESOURCES:.cc=.dd) $(CSOURCES:.c=.d) mod2.h |
---|
346 | cat *.d *.dd >depend |
---|
347 | |
---|
348 | ifeq (depend,$(wildcard depend)) |
---|
349 | include depend |
---|
350 | endif |
---|
351 | |
---|
352 | |
---|
353 | # My headers test |
---|
354 | # test: test.o |
---|
355 | |
---|
356 | test.o: test.cc mod2.h feOpt.inc |
---|
357 | $(CXXG) ${CXXFLAGSG} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFSG} -c $< -o $@ |
---|
358 | |
---|
359 | feOpt.inc: feOpt.cc mod2.h |
---|
360 | $(CXX) $(CXXFLAGS) -DGENERATE_OPTION_INDEX ${CPPFLAGS} feOpt.cc -o feOpt |
---|
361 | ./feOpt |
---|
362 | /bin/rm -f feOpt feOpt.exe |
---|
363 | |
---|
364 | feOptES.inc: feOpt.cc mod2.h |
---|
365 | $(CXX) $(CXXFLAGS) -DGENERATE_OPTION_INDEX ${CPPFLAGS} -DESINGULAR -I../kernel feOpt.cc -o feOptES |
---|
366 | ./feOptES |
---|
367 | rm -f feOptES feOptES.exe |
---|
368 | |
---|
369 | feOptTS.inc: feOpt.cc mod2.h |
---|
370 | $(CXX) $(CXXFLAGS) -DGENERATE_OPTION_INDEX ${CPPFLAGS} -DTSINGULAR -I../kernel feOpt.cc -o feOptTS |
---|
371 | ./feOptTS |
---|
372 | rm -f feOptTS feOptTS.exe |
---|
373 | |
---|
374 | iparith.inc: gentable.cc grammar.h tok.h table.h mod2.h |
---|
375 | ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXTEMPLFLAGS} ${DEFS} gentable.cc \ |
---|
376 | -o gentable1 |
---|
377 | ./gentable1 |
---|
378 | /bin/rm -f gentable1 gentable1.exe |
---|