source: git/Singular/Makefile.in @ 9d06971

spielwiese
Last change on this file since 9d06971 was 9d06971, checked in by Olaf Bachmann <obachman@…>, 24 years ago
* bug fixes w.r.t. syzcomp stuff git-svn-id: file:///usr/local/Singular/svn/trunk@3810 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 16.0 KB
Line 
1#################################################################
2###
3### Makefile for Singular
4###
5#################################################################
6
7SHELL           = /bin/sh
8
9##
10## version
11##
12SINGULAR_VERSION        = @SINGULAR_VERSION@
13SINGULAR                = @SINGULAR@
14SINGUNAME               = @SINGUNAME@
15
16##
17## various paths
18##
19srcdir          = @srcdir@
20prefix          = @prefix@
21exec_prefix     = @exec_prefix@
22libdir          = @libdir@
23# program executable goes here
24bindir          = @bindir@
25# includes are taken from here
26includedir      = @includedir@
27slibdir         = ${prefix}/LIB
28
29
30##
31## various programs
32##
33@SET_MAKE@
34CC              = @CC@
35CXX             = @CXX@
36LEX             = @LEX@
37PERL5           = @PERL5@
38BISON           = bison
39INSTALL         = ./install-sh -c
40INSTALL_PROGRAM = ${INSTALL}
41INSTALL_DATA    = ${INSTALL} -m 644
42MKINSTALLDIRS   = ./mkinstalldirs
43LN_S            = @LN_S@
44
45##
46## compiler and linker options
47##
48PIPE            = @PIPE@
49CFLAGS          = @CFLAGS@ ${PIPE}
50CXXFLAGS        = @CXXFLAGS@ ${PIPE}
51CXXTEMPLFLAGS   = @CXXTEMPLFLAGS@
52CPPFLAGS        = -I${srcdir} @CPPFLAGS@
53DEFS            = -DNDEBUG -D@SING_UNAME@ @DEFS@
54LDFLAGS         = @LDFLAGS@
55LD_DYN_FLAGS    = @LD_DYN_FLAGS@
56LD_LIBC         = @LD_LIBC@
57STATIC_LDFLAGS  = @STATIC_LDFLAGS@
58LIBS            = -lm @NEED_LIBS@
59
60##
61## End configuration dependend stuff
62#################################################################
63
64###
65### file sets
66###
67
68# normal C++ source files
69CXXSOURCES=grammar.cc scanner.cc algmap.cc attrib.cc binom.cc clapconv.cc \
70    clapmem.cc clapsing.cc cntrlc.cc\
71    extra.cc febase.cc feread.cc fehelp.cc feResource.cc feOpt.cc\
72    ffields.cc hdegree.cc hilb.cc hutil.cc \
73    ideals.cc intvec.cc \
74    ipassign.cc ipconv.cc ipid.cc iplib.cc \
75    ipprint.cc ipshell.cc khstd.cc kstdfac.cc \
76    kstd1.cc kstd2.cc kutil.cc lists.cc \
77    longalg.cc longrat.cc longrat0.cc \
78    maps.cc matpol.cc misc.cc sdb.cc gnumpfl.cc gnumpc.cc \
79    mminit.cc modulop.cc mpr_complex.cc sparsmat.cc \
80    fglm.cc fglmzero.cc fglmvec.cc fglmgauss.cc fglmhom.cc fglmcomb.cc \
81    numbers.cc polys.cc polys0.cc polys1.cc polys-impl.cc \
82    ring.cc shortfl.cc silink.cc sing_mp.cc\
83    sing_dld.cc sing_dbm.cc kspoly.cc \
84    subexpr.cc syz.cc syz0.cc syz1.cc syz2.cc\
85    timer.cc weight.cc \
86    mpsr_Put.cc mpsr_PutPoly.cc mpsr_GetPoly.cc \
87    mpsr_Get.cc mpsr_GetMisc.cc mpsr_Error.cc \
88    GMPrat.cc multicnt.cc npolygon.cc semic.cc spectrum.cc splist.cc \
89    ndbm.cc  libparse.cc mod_raw.cc\
90    pcv.cc kbuckets.cc pProcs.cc \
91    mpr_inout.cc mpr_base.cc mpr_numeric.cc
92
93
94# normal C source files
95CSOURCES=mmalloc.c mmheap.c mmpage.c mmcheck.c  mmisc.c mmtables.c \
96    mmbt.c weight0.c find_exec.c fegetopt.c fereadl.c page.c
97
98# special source files (need extra compiling and/or linking)
99ESOURCES=iparith.cc gmalloc.c tesths.cc mpsr_Tok.cc claptmpl.cc
100
101SOURCES=${CSOURCES} ${CXXSOURCES} ${ESOURCES} \
102        grammar.y scanner.l libparse.l syz2.cc
103
104# ASO_SOURCES
105ASO_SOURCES = structs.aso.cc ipid.aso.cc mmprivate.aso.cc silink.aso.cc \
106              matpol.aso.cc longrat.aso.cc kbuckets.aso.cc mpsr_Get.aso.cc \
107              mpr_base.aso.cc attrib.aso.cc lists.aso.cc kutil.aso.cc \
108              syz.aso.cc subexpr.aso.cc
109
110HEADERS=algmap.h hutil.h lists.h stairc.h attrib.h ideals.h \
111        longalg.h mpsr_Tok.h structs.h binom.h intvec.h longrat.h \
112        numbers.h stype.h clapconv.h ipconv.h maps.h page.h \
113        subexpr.h clapsing.h ipid.h matpol.h polys.h syz.h \
114        cntrlc.h ipprint.h ring.h timer.h sdb.h \
115        febase.h ipshell.h shortfl.h tok.h mpr_complex.h mpr_global.h \
116        mmemory.h mmprivate.h mmpage.h page.h \
117        ffields.h khstd.h silink.h sparsmat.h gnumpfl.h gnumpc.h \
118        fglm.h kstd1.h modulop.h sing_dbm.h weight.h \
119        fglmgauss.h fglmvec.h mpsr.h sing_mp.h \
120        kstdfac.h mpsr_Get.h mmbt.h \
121        kutil.h mpsr_Put.h sing_dld.h\
122        ndbm.h polys-impl.h polys-comp.h libparse.h \
123        GMPrat.h multicnt.h npolygon.h semic.h spectrum.h splist.h multicnt.h \
124        pcv.h mod_raw.h kbuckets.h pProcs.h \
125        mpr_global.h mpr_inout.h mpr_base.h mpr_numeric.h \
126        feOpt.h fegetopt.h distrib.h walk.h
127
128INCS=febase.inc polys.inc iparith.inc mpsr_Tok.inc feOpt.inc
129
130DISTFILES=${SOURCES} ${HEADERS} Makefile.in configure.in configure \
131        mod2.h.in grammar.h testgh install-sh mkinstalldirs \
132        ${INCS} $(ASO_SOURCES) check_aso.pl aso.h
133
134OBJS := $(CXXSOURCES:.cc=.o) $(CSOURCES:.c=.o)
135
136ASO_OBJS := $(ASO_SOURCES:.aso.cc=.aso)
137
138# Singular libraries which go into distribution
139SLIBS = algebra.lib        all.lib            classify.lib       deform.lib  \
140        elim.lib           factor.lib         finvar.lib         general.lib \
141        graphics.lib       hnoether.lib       homolog.lib        inout.lib   \
142        invar.lib          jordan.lib         latex.lib          linalg.lib  \
143        matrix.lib         mondromy.lib       normal.lib                     \
144        poly.lib           presolve.lib       primdec.lib                    \
145        primitiv.lib       random.lib         ring.lib           sing.lib    \
146        solve.lib          solver.lib         spcurve.lib        standard.lib\
147        surf.lib           template.lib
148
149##
150## Build Targets
151##
152.l.cc:
153        @if test "x${LEX}" = x; then \
154                echo Error: no lex given, could not rebuilt scanner.cc;\
155                exit 1; \
156        fi
157        ${LEX} -s -I -t $< > scanner.cc
158.y.cc:
159        @if test "x${BISON}" = x; then \
160                echo Error: no bison given, could not rebuilt grammar.cc;\
161                exit 1; \
162        fi
163        ${BISON} -d -t -o grammar.cc $<
164        chmod +x testgh
165        ./testgh
166
167.cc.o: 
168        ${CXX} ${CXXFLAGS} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFS} -c $<
169.c.o:
170        ${CC} ${CFLAGS} ${CPPFLAGS} ${DEFS} -c $<
171
172%.aso.o: %.aso.cc mmtables.inc
173        ${CXX} ${CXXFLAGS} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFS} $< -o $@
174.PRECIOUS: %.aso.o
175
176%.aso: %.aso.o
177        ./$< > $@
178
179all:    Singular
180
181Singular: mod2.h Makefile version.h scanner.cc gmalloc.o \
182          ${ASO_OBJS} ${OBJS} \
183          iparith.o tesths.cc libparse.cc claptmpl.o mpsr_Tok.o
184        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXTEMPLFLAGS} ${DEFS} \
185          -o Singular \
186          tesths.cc iparith.o mpsr_Tok.o claptmpl.o\
187          ${OBJS} ${LDFLAGS} ${LIBS} ${LD_DYN_FLAGS} \
188          gmalloc.o ${LD_LIBC}
189
190Singular-static: mod2.h Makefile version.h scanner.cc  gmalloc.o \
191                ${ASO_OBJS}  ${OBJS} \
192                iparith.o mpsr_Tok.o tesths.cc claptmpl.o
193        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXTEMPLFLAGS} ${DEFS} \
194          -o Singular-static \
195          tesths.cc iparith.o mpsr_Tok.o claptmpl.o\
196          ${OBJS} ${STATIC_LDFLAGS} ${LDFLAGS} ${LIBS} ${LD_DYN_FLAGS} \
197          gmalloc.o ${LD_LIBC}
198
199iparith.o mpsr_Tok.o : iparith.inc mpsr_Tok.inc
200
201claptmpl.o: claptmpl.cc mod2.h
202        ${CXX} ${CXXFLAGS}  ${CPPFLAGS} ${DEFS} -c $<   
203
204iparith.inc mpsr_Tok.inc: gmalloc.o claptmpl.o iparith.cc \
205                          ipconv.cc tok.h mpsr_Tok.cc grammar.h mod2.h
206        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXTEMPLFLAGS} ${DEFS} -DGENTABLE \
207             -o gentable claptmpl.o iparith.cc tesths.cc mpsr_Tok.cc \
208             ${OBJS} ${LDFLAGS} ${LIBS} gmalloc.o ${LD_LIBC}
209        ./gentable
210        /bin/rm -f gentable gentable.exe
211
212
213mmtables.inc: mmtables.c mmprivate.h mmemory.h mod2.h
214        ${CXX} ${CXXFLAGS}  ${CPPFLAGS}\
215               -DGENERATE_INDEX_TABLE  -DHAVE_ASO=0 -DHAVE_INDEX_TABLE mmtables.c -o mmtables
216        ./mmtables > mmtables.inc
217        rm -f mmtables mmtables.exe
218
219mmtables.o mmtables.d: mmtables.inc
220
221version.h: ${SOURCES} ${HEADERS} Makefile.in mod2.h.in \
222           configure.in
223        echo unsigned long feVersionId =  `date '+%Y%m%d%H'`\; >version.h
224
225libparse: libparse_main.o utils.o fegetopt.o
226        ${CXX}  -DHAVE_ASO=0  -o libparse libparse_main.o utils.o fegetopt.o
227
228libparse_main.o: libparse.cc
229        ${CXX} -c -o libparse_main.o libparse.cc  -DHAVE_ASO=0 -DSTANDALONE_PARSER
230
231libparse.cc: libparse.l
232        @if test "x${LEX}" = x; then \
233                echo Error: no lex given, could not rebuilt libparse.cc;\
234                exit 1; \
235        fi
236        ${LEX} -I -Pyylp -olibparse.cc libparse.l
237
238ESingular: fegetopt.o feResource.cc mod2.h feOpt.cc version.h emacs.cc \
239           feOptES.inc
240        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${DEFS} -o ESingular emacs.cc fegetopt.o ${LDFLAGS} ${LIBS}
241
242feOpt.h: feOpt.inc feOptES.inc
243
244feOpt.inc: feOpt.cc
245        $(CXX) -DGENERATE_OPTION_INDEX -DHAVE_ASO=0 feOpt.cc
246        ./a.out
247        rm a.out
248
249feOptES.inc: feOpt.cc
250        $(CXX) -DGENERATE_OPTION_INDEX  -DHAVE_ASO=0 -DESINGULAR feOpt.cc
251        ./a.out
252        rm a.out
253
254src: scanner.cc grammar.h grammar.cc libparse.cc
255
256mod2.h: stamp-h
257
258stamp-h : config.status mod2.h.in
259        CONFIG_FILES= CONFIG_HEADERS="mod2.h" ./config.status
260
261Makefile: Makefile.in config.status
262        CONFIG_FILES="Makefile" CONFIG_HEADERS= ./config.status
263
264config.status: configure
265        ./config.status --recheck
266
267configure: configure.in
268        @echo "WARNING: You need to rerun autoconf. I am proceeding, for now."
269        @touch configure
270#       autoconf
271
272##
273## install targets
274##
275install: all installbin installslib
276
277installbin: Singular libparse ESingular
278        ${MKINSTALLDIRS} ${bindir}
279        ${INSTALL_PROGRAM} Singular ${bindir}/Singular-${SINGULAR_VERSION}
280        ${INSTALL_PROGRAM} libparse ${bindir}/libparse
281        ${INSTALL_PROGRAM} ESingular ${bindir}/ESingular
282        chmod a+x ${bindir}/Singular-${SINGULAR_VERSION}
283        rm -f ${bindir}/Singular
284        cd ${bindir}; ${LN_S} Singular-${SINGULAR_VERSION} Singular;\
285        if test ! -x ${SINGULAR}; then \
286                ${LN_S} Singular-${SINGULAR_VERSION} ${SINGULAR};\
287        fi
288
289installslib: LIB
290        test -r ${slibdir} || ${LN_S} `pwd`/LIB ${slibdir}
291
292
293uninstall: uninstallbin
294
295uninstallbin:
296        rm -f ${bindir}/Singular rm -f ${bindir}/Singular-${SINGULAR_VERSION}
297        -rmdir ${bindir}
298
299##
300## clean targest
301##
302mostlyclean:
303        -rm -f Singular Singularg Singularp Singularb libparse feOpt*.inc
304        -rm -f *.o *.og core *.op *.ob *.ot Singulart
305
306clean: mostlyclean
307         -rm -f *.aso *.bak *.d *.dd depend
308
309distclean: clean
310        -rm -f iparith.inc mpsr_Tok.inc stamp.h
311        -rm -f Singular* *.gprof *.bprof *~ .\#* version.h
312        -rm -f mod2.h Makefile TAGS* tags config.status config.cache config.log
313
314srcclean:
315        @echo "This command is intended for maintainers to use;"
316        @echo "Rebuilding the deleted files requires flex"
317        @echo "bison, perl"
318        -rm -f scanner.cc grammar.h grammar.cc libparse.cc
319
320maintainer-clean: distclean srcclean
321        @echo "This command is intended for maintainers to use;"
322        @echo "Rebuilding the deleted files requires flex"
323        @echo "bison, perl and autoconf"
324        -rm configure
325
326##
327## miscellanous targets
328##
329
330Singular-bindist: ${OBJS} Makefile
331        echo "#define MAKE_DISTRIBUTION " > distrib.h
332        ${MAKE} Singular ESingular
333        strip Singular ESingular
334        ${INSTALL} -s Singular Singular-bindist
335        ${INSTALL} -s ESingular ESingular-bindist
336        echo "#undef MAKE_DISTRIBUTION " > distrib.h
337
338Singular-static-bindist: ${OBJS} Makefile
339        echo "#define MAKE_DISTRIBUTION " > distrib.h
340        ${MAKE} Singular-static ESingular
341        strip Singular-static ESingular
342        mv Singular-static Singular-static-bindist
343        ${INSTALL} -s ESingular ESingular-bindist
344        echo "#undef MAKE_DISTRIBUTION " > distrib.h
345
346tar:
347        tar cf Singular-${SINGULAR_VERSION}-src.tar ${DISTFILES}
348        gzip -f Singular-${SINGULAR_VERSION}-src.tar
349
350
351TAGS:   ${SOURCES} ${HEADERS} ${INCS}
352        etags ${SOURCES} ${HEADERS}
353
354tags:   
355        ctags *.y *.l *.c *.h *.cc *.inc
356
357echoLIBS:
358        @echo ${SLIBS}
359
360##
361## Below here is stuff for developpers
362#################################################################
363
364##
365## compiler and linker options for debug version
366##
367
368CCG             = gcc
369CXXG            = gcc
370CXXM            = gcc -MM -MG -DGENERATE_DEPEND
371CCM             = gcc -MM -MG -DGENERATE_DEPEND
372
373CFLAGSG         = -g -Wall -Wno-unused ${PIPE}
374CXXFLAGSG       = -g -Wall -Wno-unused ${PIPE}
375CXXTEMPLFLAGSG  = -fno-implicit-templates
376DEFSG           = -D@SING_UNAME@ @DEFS@
377
378##
379## .og files for having -O and -g object versions available at the same time
380##
381
382OBJG1 := $(CXXSOURCES:.cc=.og)
383OBJG2 := $(CSOURCES:.c=.og)
384
385
386OBJG=$(OBJG1) $(OBJG2)
387
388##
389## Debug Targets
390##
391
392claptmpl.og: claptmpl.cc mod2.h
393        $(CXXG)  ${CXXFLAGSG} ${CPPFLAGS} ${DEFSG} -c $< -o $@
394
395$(OBJG1) : %.og: %.cc
396        $(CXXG) ${CXXFLAGSG} ${CXXTEMPLFLAGSG} ${CPPFLAGS} ${DEFSG} -c $< -o $@
397
398$(OBJG2) gmalloc.og: %.og: %.c
399        $(CCG)  ${CFLAGSG} ${CPPFLAGS} ${DEFSG} -c $< -o $@
400
401Singularg: scanner.cc gmalloc.og \
402           $(ASO_OBJS) $(OBJG)  \
403           iparith.og mpsr_Tok.og claptmpl.og tesths.cc version.h
404        $(CXXG) ${CXXFLAGSG} ${CXXTEMPLFLAGSG} ${CPPFLAGS} ${DEFSG} -o Singularg \
405        tesths.cc iparith.og mpsr_Tok.og claptmpl.og $(OBJG) ${LDFLAGS} ${LIBS} \
406        ${LD_DYN_FLAGS} gmalloc.og
407
408iparith.og: iparith.inc iparith.cc
409        $(CXXG)  ${CXXFLAGSG} ${CXXTEMPLFLAGSG} ${CPPFLAGS} ${DEFSG} -c iparith.cc -o iparith.og
410
411mpsr_Tok.og: iparith.inc mpsr_Tok.cc
412        $(CXXG) ${CXXFLAGSG} ${CPPFLAGS} ${CXXTEMPLFLAGSG} ${DEFSG} -c mpsr_Tok.cc -o mpsr_Tok.og
413
414installg: Singularg
415        ${MKINSTALLDIRS} ${bindir}
416        ${INSTALL_PROGRAM} Singularg ${bindir} 
417
418##
419## compiler and linker options for profile version
420##
421
422CCP             = gcc
423CXXP            = gcc
424
425CFLAGSP         = -pg -O3 ${PIPE}
426CXXFLAGSP       = -pg -O3 ${PIPE}
427CXXTEMPLFLAGSP  = -fno-implicit-templates
428DEFSP           = -DNDEBUG -DDO_PROFILE -D@SING_UNAME@ @DEFS@
429LDFLAGSP        = -static @LDFLAGS@
430
431CFLAGSB         = -g -O3 ${PIPE}
432CXXFLAGSB       = -g -O3 ${PIPE}
433CXXTEMPLFLAGSB  = -fno-implicit-templates
434DEFSB           = -D@SING_UNAME@ -DNDEBUG @DEFS@
435LDFLAGSB        = -static @LDFLAGS@
436
437# bprof object  file to link with
438BPROFOBJ        = /usr/local/lib/bmon.o
439
440DEFST           = -DNDEBUG -D@SING_UNAME@ -DMTRACK @DEFS@
441LDFLAGST        = @LDFLAGS@
442CFLAGST         = -g  -w ${PIPE}
443CXXFLAGST       = -g  -w ${PIPE}
444
445##
446## op and ob files for gprof and bprof, ot for mtrack
447##
448
449OBJP1 := $(CXXSOURCES:.cc=.op)
450OBJP2 := $(CSOURCES:.c=.op)
451OBJP=$(OBJP1) $(OBJP2)
452
453OBJB1 := $(CXXSOURCES:.cc=.ob)
454OBJB2 := $(CSOURCES:.c=.ob)
455OBJB=$(OBJB1) $(OBJB2)
456
457OBJT1 := $(CXXSOURCES:.cc=.ot)
458OBJT2 := $(CSOURCES:.c=.ot)
459OBJT=$(OBJT1) $(OBJT2)
460
461##
462## profile targets
463##
464
465## for gprof
466claptmpl.op: claptmpl.cc mod2.h
467        $(CXXP)  ${CXXFLAGSP} ${CPPFLAGS} ${DEFSP} -c $< -o $@
468
469$(OBJP1): %.op: %.cc
470        $(CXXP) ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSP} -c $< -o $@
471
472$(OBJP2) gmalloc.op: %.op: %.c
473        $(CCP)  ${CFLAGSP} ${CPPFLAGS} ${DEFSP} -c $< -o $@
474
475Singularp: scanner.cc  gmalloc.op \
476           $(ASO_OBJS) $(OBJP) \
477           iparith.op mpsr_Tok.op claptmpl.op tesths.cc version.h
478        $(CXXP) ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSP} -o Singularp \
479        tesths.cc iparith.op mpsr_Tok.op claptmpl.op $(OBJP) ${LDFLAGSP} ${LIBS} \
480        ${LD_DYN_FLAGS} gmalloc.op
481
482iparith.op: iparith.inc iparith.cc
483        $(CXXP)  ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSP} -c iparith.cc -o iparith.op
484
485mpsr_Tok.op: iparith.inc mpsr_Tok.cc
486        $(CXXP) ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSP} -c mpsr_Tok.cc -o mpsr_Tok.op
487
488
489## for bprof
490claptmpl.ob: claptmpl.cc mod2.h
491        $(CXXP)  ${CXXFLAGSP} ${CPPFLAGS} ${DEFSB} -c $< -o $@
492
493$(OBJB1): %.ob: %.cc
494        $(CXXP) ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSB} -c $< -o $@
495
496$(OBJB2) gmalloc.ob: %.ob: %.c
497        $(CCP)  ${CFLAGSP} ${CPPFLAGS} ${DEFSB} -c $< -o $@
498
499Singularb: scanner.cc  gmalloc.ob $(OBJB) iparith.ob mpsr_Tok.ob claptmpl.ob tesths.cc version.h
500        $(CXXP) ${CXXFLAGSP} ${CPPFLAGS} ${DEFSB} -o Singularb \
501        tesths.cc iparith.ob mpsr_Tok.ob claptmpl.ob $(OBJB) $(BPROFOBJ) \
502        ${LDFLAGSP} ${LIBS} ${LD_DYN_FLAGS} gmalloc.ob
503
504iparith.ob: iparith.inc iparith.cc
505        $(CXXP)  ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSB} -c iparith.cc -o iparith.ob
506
507mpsr_Tok.ob: iparith.inc mpsr_Tok.cc
508        $(CXXP) ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSB} -c mpsr_Tok.cc -o mpsr_Tok.ob
509
510#
511# for mtrack
512#
513claptmpl.ot: claptmpl.cc mod2.h
514        $(CXXP)  ${CXXFLAGST} ${CPPFLAGS} ${DEFST} -c $< -o $@
515
516$(OBJT1): %.ot: %.cc
517        $(CXXP) ${CXXFLAGST} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFST} -c $< -o $@
518
519$(OBJT2) gmalloc.ot: %.ot: %.c
520        $(CCP)  ${CFLAGST} ${CPPFLAGS} ${DEFST} -c $< -o $@
521
522Singulart: scanner.cc  gmalloc.ot $(OBJT) iparith.ot mpsr_Tok.ot claptmpl.ot tesths.cc version.h
523        $(CXXP) ${CXXFLAGST} ${CPPFLAGS} ${DEFST} -o Singulart \
524        tesths.cc iparith.ot mpsr_Tok.ot claptmpl.ot $(OBJT) ${LDFLAGST} ${LIBS} \
525        ${LD_DYN_FLAGS} gmalloc.ot
526
527iparith.ot: iparith.inc iparith.cc
528        $(CXXP)  ${CXXFLAGST} ${CXXTEMPLFLAGSB} ${CPPFLAGS} ${DEFST} -c iparith.cc -o iparith.ot
529
530mpsr_Tok.ot: iparith.inc mpsr_Tok.cc
531        $(CXXP) ${CXXFLAGST} ${CXXTEMPLFLAGSB} ${CPPFLAGS} ${DEFST} -c mpsr_Tok.cc -o mpsr_Tok.ot
532
533
534##
535## check_aso
536##
537check_aso:
538        ${PERL5} check_aso.pl $(SOURCES)
539##
540## dependencies
541##
542
543%.aso.dd: %.aso.cc mod2.h aso.h
544        $(CXXM) ${CPPFLAGS} ${DEFS} $< >> $@
545
546%.dd: %.cc mod2.h
547        echo $(@:.dd=.og) $(@:.dd=.op) $(@:.dd=.ob) $(@:.dd=.ot)" " \\ > $@
548        $(CXXM) -DGENTABLE ${CPPFLAGS} ${DEFSG} $< >> $@
549
550%.d: %.c mod2.h
551        echo $(@:.d=.og) $(@:.d=.op) $(@:.d=.ob) $(@:.d=.ot)" " \\ > $@
552        $(CCM) ${CPPFLAGS} ${DEFSG} $< >> $@
553
554depend:   $(ASO_SOURCES:.cc=.dd) $(CXXSOURCES:.cc=.dd) $(CSOURCES:.c=.d) mod2.h
555        cat *.d *.dd >depend
556
557ifeq (depend,$(wildcard depend))
558include depend
559endif
560
561
562
Note: See TracBrowser for help on using the repository browser.