source: git/Singular/Makefile.in @ b583ae

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