source: git/Singular/Makefile.in @ 73aa5e

fieker-DuValspielwiese
Last change on this file since 73aa5e was 73aa5e, checked in by Kai Krüger <krueger@…>, 25 years ago
Added checking Flags and libs for dynamic modules git-svn-id: file:///usr/local/Singular/svn/trunk@2719 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 16.2 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@
27
28##
29## various programs
30##
31@SET_MAKE@
32CC              = @CC@
33CXX             = @CXX@
34LEX             = @LEX@
35PERL5           = @PERL5@
36BISON           = bison
37INSTALL         = ./install-sh -c
38INSTALL_PROGRAM = ${INSTALL}
39INSTALL_DATA    = ${INSTALL} -m 644
40MKINSTALLDIRS   = ./mkinstalldirs
41LN_S            = @LN_S@
42
43##
44## compiler and linker options
45##
46PIPE            = @PIPE@
47CFLAGS          = @CFLAGS@ ${PIPE}
48CXXFLAGS        = @CXXFLAGS@ ${PIPE}
49CXXTEMPLFLAGS   = @CXXTEMPLFLAGS@
50CPPFLAGS        = -I${srcdir} @CPPFLAGS@
51DEFS            = @DEFS@ -DNDEBUG
52LDFLAGS         = @LDFLAGS@
53LD_DYN_FLAGS    = @LD_DYN_FLAGS@
54STATIC_LDFLAGS  = @STATIC_LDFLAGS@
55LIBS            = -lm @NEED_LIBS@
56
57##
58## End configuration dependend stuff
59#################################################################
60
61###
62### file sets
63###
64
65CXXSOURCES=grammar.cc scanner.cc algmap.cc attrib.cc binom.cc clapconv.cc \
66    clapmem.cc clapsing.cc claptmpl.cc cntrlc.cc \
67    extra.cc febase.cc feread.cc \
68    ffields.cc hdegree.cc hilb.cc hutil.cc \
69    ideals.cc intvec.cc iparith.cc \
70    ipassign.cc ipconv.cc ipid.cc iplib.cc \
71    ipprint.cc ipshell.cc khstd.cc kstdfac.cc \
72    comm.cc kstd1.cc kstd2.cc kutil.cc lists.cc \
73    longalg.cc longrat.cc longrat0.cc \
74    maps.cc matpol.cc misc.cc \
75    mminit.cc modulop.cc \
76    fglm.cc fglmzero.cc fglmvec.cc fglmgauss.cc fglmhom.cc fglmcomb.cc \
77    numbers.cc polys.cc polys0.cc polys1.cc polys-impl.cc \
78    ring.cc shortfl.cc silink.cc sing_mp.cc\
79    sing_dld.cc sing_dbm.cc spolys.cc spolys0.cc \
80    subexpr.cc syz.cc syz0.cc syz1.cc \
81    tesths.cc timer.cc weight.cc \
82    mpsr_Put.cc mpsr_PutPoly.cc mpsr_Tok.cc mpsr_GetPoly.cc \
83    mpsr_Get.cc mpsr_GetMisc.cc mpsr_Error.cc \
84    ndbm.cc spSpolyLoop.cc libparse.cc mod-${SINGUNAME}.cc\
85        pcv.cc
86
87CSOURCES=gmalloc.c mmalloc.c mmheap.c mmpage.c mmcheck.c  mmisc.c mmtables.c \
88    mmbt.c weight0.c find_exec.c getopt.c fereadl.c
89
90SOURCES=${CSOURCES} ${CXXSOURCES} grammar.y scanner.l libparse.l spSpolyLoop.pl
91
92HEADERS=algmap.h hutil.h lists.h stairc.h attrib.h ideals.h \
93        longalg.h mpsr_Tok.h structs.h binom.h intvec.h longrat.h \
94        numbers.h stype.h clapconv.h ipconv.h maps.h page.h \
95        subexpr.h clapsing.h ipid.h matpol.h polys.h syz.h \
96        cntrlc.h ipprint.h ring.h timer.h \
97        febase.h ipshell.h shortfl.h tok.h \
98        mmemory.h mmprivate.h mmheap.h mmpage.h \
99        ffields.h khstd.h silink.h \
100        fglm.h comm.h kstd1.h modulop.h sing_dbm.h weight.h \
101        fglmgauss.h fglmvec.h kstd2.h mpsr.h sing_mp.h \
102        kstdfac.h mpsr_Get.h spolys.h \
103        kutil.h mpsr_Put.h spolys0.h sing_dld.h\
104        ndbm.h spSpolyLoop.h polys-impl.h polys-comp.h getopt.h libparse.h \
105        pcv.h
106
107INCS=febase.inc polys.inc iparith.inc mpsr_Tok.inc spSpolyLoop.inc
108
109TESTS=${testdir}/comparecheck ${testdir}/fac_test.in ${testdir}/fac_test.out\
110        ${testdir}/general_test.in ${testdir}/general_test.out \
111        ${testdir}/mpcheck ${testdir}/mpcheck.data \
112        ${testdir}/dbm_test.in ${testdir}/dbm_test.out
113
114DISTFILES=${SOURCES} ${HEADERS} Makefile.in configure.in configure \
115        mod2.h.in si_paths.h.in grammar.h testgh install-sh mkinstalldirs \
116        ${INCS}
117
118OBJS=grammar.o scanner.o matpol.o binom.o\
119     febase.o feread.o timer.o intvec.o attrib.o lists.o\
120     longrat.o longrat0.o misc.o ring.o numbers.o maps.o\
121     hilb.o comm.o kstd1.o kstd2.o kutil.o khstd.o kstdfac.o modulop.o spolys.o\
122     ideals.o subexpr.o hdegree.o hutil.o ffields.o shortfl.o \
123     longalg.o spolys0.o syz.o syz0.o syz1.o weight.o weight0.o \
124     ipid.o ipshell.o iplib.o ipassign.o ipconv.o ipprint.o\
125     polys.o polys0.o polys1.o polys-impl.o extra.o\
126     mminit.o mmtables.o mmalloc.o mmheap.o mmpage.o \
127     mmisc.o mmcheck.o mmbt.o sing_dld.o sing_dbm.o silink.o \
128     sing_mp.o fglm.o fglmzero.o fglmvec.o fglmhom.o fglmgauss.o cntrlc.o \
129     algmap.o clapconv.o  clapmem.o clapsing.o claptmpl.o\
130     mpsr_Error.o mpsr_Put.o mpsr_PutPoly.o mpsr_GetPoly.o \
131     mpsr_Get.o mpsr_GetMisc.o ndbm.o spSpolyLoop.o libparse.o \
132     find_exec.o getopt.o fereadl.o  mod-${SINGUNAME}.o \
133        pcv.o
134
135##
136## Build Targets
137##
138.l.cc:
139        @if test "x${LEX}" = x; then \
140                echo Error: no lex given, could not rebuilt scanner.cc;\
141                exit 1; \
142        fi
143        ${LEX} -s -I -t $< > scanner.cc
144.y.cc:
145        @if test "x${BISON}" = x; then \
146                echo Error: no bison given, could not rebuilt grammar.cc;\
147                exit 1; \
148        fi
149        ${BISON} -d -t -o grammar.cc $<
150        chmod +x testgh
151        ./testgh
152
153.cc.o: 
154        ${CXX} ${CXXFLAGS} ${CXXTEMPLFLAGS} ${CPPFLAGS} ${DEFS} -c $<
155.c.o:
156        ${CC} ${CFLAGS} ${CPPFLAGS} ${DEFS} -c $<
157
158all:    Singular
159
160Singular: mod2.h si_paths.h Makefile version.h scanner.cc gmalloc.o \
161          ${OBJS} iparith.o mpsr_Tok.o tesths.cc libparse.cc
162        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXTEMPLFLAGS} ${DEFS} -o Singular \
163        tesths.cc iparith.o mpsr_Tok.o ${OBJS} ${LDFLAGS} ${LIBS} \
164        ${LD_DYN_FLAGS} gmalloc.o
165
166Singular-static: mod2.h si_paths.h Makefile version.h scanner.cc  gmalloc.o \
167                ${OBJS} iparith.o mpsr_Tok.o tesths.cc
168        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXTEMPLFLAGS} ${DEFS} \
169        -o Singular-static \
170        tesths.cc iparith.o mpsr_Tok.o \
171        ${OBJS} ${STATIC_LDFLAGS} ${LDFLAGS} ${LIBS} ${LD_DYN_FLAGS} gmalloc.o
172
173iparith.o mpsr_Tok.o : iparith.inc mpsr_Tok.inc
174
175claptmpl.o: claptmpl.cc mod2.h
176        ${CXX} ${CXXFLAGS}  ${CPPFLAGS} ${DEFS} -c $<   
177
178iparith.inc mpsr_Tok.inc: gmalloc.o iparith.cc ipconv.cc tok.h mpsr_Tok.cc grammar.h mod2.h
179        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXTEMPLFLAGS} ${DEFS} -DGENTABLE \
180             -o gentable iparith.cc tesths.cc mpsr_Tok.cc \
181             ${OBJS} ${LDFLAGS} ${LIBS} gmalloc.o
182        ./gentable
183        /bin/rm -f gentable gentable.exe
184
185
186mmtables.inc: mmtables.c mmprivate.h
187        ${CXX} ${CXXFLAGS}  ${CPPFLAGS} ${DEFS} \
188               -DGENERATE_INDEX_TABLE -DHAVE_INDEX_TABLE mmtables.c -o mmtables
189        ./mmtables > mmtables.inc
190        rm -f mmtables mmtables.exe
191
192mmtables.o mmtables.d: mmtables.inc
193
194version.h: ${SOURCES} ${HEADERS} Makefile.in mod2.h.in si_paths.h.in \
195           configure.in
196        echo "#define SINGULAR_VERSION_ID " `date '+%y%m%d%H'` >version.h
197
198spSpolyLoop.cc spSpolyLoop.dd : spSpolyLoop.inc
199
200spSpolyLoop.inc: spSpolyLoop.pl
201        @if test "x${PERL5}" = x; then \
202                echo Error: no perl5 given. Can not rebuild spSpolyLoop.inc;\
203                exit 1;\
204        fi
205        ${PERL5} spSpolyLoop.pl > spSpolyLoop.inc
206
207libparse: libparse_main.o utils.o getopt.o
208        ${CXX} -o libparse libparse_main.o utils.o getopt.o
209
210libparse_main.o: libparse.cc
211        ${CXX} -c -o libparse_main.o libparse.cc -DSTANDALONE_PARSER
212
213libparse.cc: libparse.l
214        @if test "x${LEX}" = x; then \
215                echo Error: no lex given, could not rebuilt libparse.cc;\
216                exit 1; \
217        fi
218        ${LEX} -I -Pyylp -olibparse.cc libparse.l
219
220src: scanner.cc grammar.h grammar.cc libparse.cc spSpolyLoop.inc
221
222mod2.h si_paths.h: stamp-h
223
224stamp-h : config.status mod2.h.in  si_paths.h.in
225        CONFIG_FILES= CONFIG_HEADERS="mod2.h si_paths.h" ./config.status
226
227Makefile: Makefile.in config.status
228        CONFIG_FILES="Makefile" CONFIG_HEADERS= ./config.status
229
230config.status: configure
231        ./config.status --recheck
232
233configure: configure.in
234        @echo "WARNING: You need to rerun autoconf. I am proceeding, for now."
235        @touch configure
236#       autoconf
237
238##
239## install targets
240##
241install: all installbin
242
243installbin: Singular
244        ${MKINSTALLDIRS} ${bindir}
245        ${INSTALL_PROGRAM} Singular ${bindir}/Singular-${SINGULAR_VERSION}
246        rm -f ${bindir}/Singular
247        cd ${bindir}; ${LN_S} Singular-${SINGULAR_VERSION} Singular;\
248        if test ! -x ${SINGULAR}; then \
249                ${LN_S} Singular-${SINGULAR_VERSION} ${SINGULAR};\
250        fi
251
252
253
254uninstall: uninstallbin
255
256uninstallbin:
257        rm -f ${bindir}/Singular rm -f ${bindir}/Singular-${SINGULAR_VERSION}
258        -rmdir ${bindir}
259
260##
261## clean targest
262##
263mostlyclean: clean
264
265clean:
266        -rm -f Singular Singularg Singularp Singularb libparse \
267            *.o *.og core *.op *.ob
268
269distclean: clean
270        -rm -f depend iparith.inc mpsr_Tok.inc stamp.h *.d *.dd
271        -rm -f Singular* *.gprof *.bprof *~ .\#* version.h
272        -rm -f mod2.h Makefile TAGS* config.status config.cache config.log
273
274srcclean:
275        @echo "This command is intended for maintainers to use;"
276        @echo "Rebuilding the deleted files requires flex"
277        @echo "bison, perl"
278        -rm -f scanner.cc grammar.h grammar.cc libparse.cc spSpolyLoop.inc
279
280maintainer-clean: distclean srcclean
281        @echo "This command is intended for maintainers to use;"
282        @echo "Rebuilding the deleted files requires flex"
283        @echo "bison, perl and autoconf"
284        -rm configure
285
286##
287## miscellanous targets
288##
289
290Singular-bindist: mod2.h Makefile version.h scanner.cc ${OBJS} iparith.o \
291                  mpsr_Tok.o tesths.cc libparse.cc si_paths.h depend
292        touch si_paths.h
293        ${MAKE} CXXFLAGS="${CXXFLAGS} -DMAKE_DISTRIBUTION" Singular
294        ${INSTALL} -s Singular Singular-bindist
295
296Singular-static-bindist: mod2.h Makefile version.h scanner.cc si_paths.h \
297                         ${OBJS} iparith.o mpsr_Tok.o tesths.cc \
298                         libparse.cc depend
299        touch si_paths.h
300        ${MAKE} CXXFLAGS="${CXXFLAGS} -DMAKE_DISTRIBUTION" Singular-static
301        strip Singular-static
302        mv Singular-static Singular-static-bindist
303
304tar:
305        tar cf Singular-${SINGULAR_VERSION}-src.tar ${DISTFILES}
306        gzip -f Singular-${SINGULAR_VERSION}-src.tar
307
308
309TAGS:
310        etags ${SOURCES} ${HEADERS}
311
312##
313## Below here is stuff for developpers
314#################################################################
315
316##
317## compiler and linker options for debug version
318##
319
320CCG             = gcc
321CXXG            = gcc
322CXXM            = gcc -MM
323CCM             = gcc -MM
324
325CFLAGSG         = -g -Wall -Wno-unused ${PIPE}
326CXXFLAGSG       = -g -Wall -Wno-unused ${PIPE}
327CXXTEMPLFLAGSG  = -fno-implicit-templates
328DEFSG           = @DEFS@
329
330##
331## .og files for having -O and -g object versions available at the same time
332##
333
334OBJG1=  grammar.og scanner.og matpol.og binom.og\
335     febase.og feread.og timer.og intvec.og attrib.og lists.og\
336     longrat.og longrat0.og misc.og ring.og numbers.og maps.og\
337     hilb.og comm.og kstd1.og kstd2.og kutil.og khstd.og kstdfac.og modulop.og \
338     spolys.og ideals.og subexpr.og hdegree.og hutil.og ffields.og shortfl.og \
339     longalg.og spolys0.og syz.og syz0.og syz1.og weight.og \
340     ipid.og ipshell.og iplib.og ipassign.og ipconv.og ipprint.og\
341     polys.og polys0.og polys1.og polys-impl.og extra.og\
342     mminit.og sing_dld.og sing_dbm.og silink.og \
343     sing_mp.og fglm.og fglmzero.og fglmvec.og fglmgauss.og fglmhom.og\
344     algmap.og clapconv.og  clapmem.og clapsing.og \
345     cntrlc.og  \
346     mpsr_Error.og mpsr_Put.og mpsr_PutPoly.og mpsr_GetPoly.og \
347     mpsr_Get.og mpsr_GetMisc.og \
348     ndbm.og spSpolyLoop.og libparse.og  mod-${SINGUNAME}.og \
349        pcv.og
350
351OBJG2= mmalloc.og mmheap.og mmpage.og mmcheck.og mmbt.og \
352     mmisc.og mmtables.og weight0.og find_exec.og getopt.og fereadl.og
353
354
355OBJG=$(OBJG1) $(OBJG2) claptmpl.og
356
357##
358## Debug Targets
359##
360
361claptmpl.og: claptmpl.cc mod2.h
362        $(CXXG)  ${CXXFLAGSG} ${CPPFLAGS} ${DEFSG} -c $< -o $@
363$(OBJG1): %.og: %.cc
364        $(CXXG) ${CXXFLAGSG} ${CXXTEMPLFLAGSG} ${CPPFLAGS} ${DEFSG} -c $< -o $@
365
366$(OBJG2) gmalloc.og: %.og: %.c
367        $(CCG)  ${CFLAGSG} ${CPPFLAGS} ${DEFSG} -c $< -o $@
368
369Singularg: scanner.cc gmalloc.og $(OBJG) iparith.og mpsr_Tok.og tesths.cc version.h
370        $(CXXG) ${CXXFLAGSG} ${CXXTEMPLFLAGSG} ${CPPFLAGS} ${DEFSG} -o Singularg \
371        tesths.cc iparith.og mpsr_Tok.og $(OBJG) ${LDFLAGS} ${LIBS} \
372        ${LD_DYN_FLAGS} gmalloc.og
373
374iparith.og: iparith.inc iparith.cc
375        $(CXXG)  ${CXXFLAGSG} ${CXXTEMPLFLAGSG} ${CPPFLAGS} ${DEFSG} -c iparith.cc -o iparith.og
376
377mpsr_Tok.og: iparith.inc mpsr_Tok.cc
378        $(CXXG) ${CXXFLAGSG} ${CPPFLAGS} ${CXXTEMPLFLAGSG} ${DEFSG} -c mpsr_Tok.cc -o mpsr_Tok.og
379
380installg: Singularg
381        ${MKINSTALLDIRS} ${bindir}
382        ${INSTALL_PROGRAM} Singularg ${bindir} 
383
384##
385## compiler and linker options for profile version
386##
387
388CCP             = gcc
389CXXP            = gcc
390
391CFLAGSP         = -pg -O3 ${PIPE} 
392CXXFLAGSP       = -pg -O3 ${PIPE}
393CXXTEMPLFLAGSP  = -fno-implicit-templates
394DEFSP           = @DEFS@ -DNDEBUG -DDO_PROFILE
395LDFLAGSP        = -static @LDFLAGS@
396
397CFLAGSB         = -g -O3 ${PIPE} 
398CXXFLAGSB       = -g -O3 ${PIPE}
399CXXTEMPLFLAGSB  = -fno-implicit-templates
400DEFSB           = @DEFS@ -DNDEBUG
401LDFLAGSB        = -static @LDFLAGS@
402# bprof object  file to link with
403BPROFOBJ        = /usr/local/lib/bmon.o
404
405
406##
407## .op files for gprof
408##
409
410OBJP1=  grammar.op scanner.op matpol.op binom.op\
411     febase.op feread.op timer.op intvec.op attrib.op lists.op\
412     longrat.op longrat0.op misc.op ring.op numbers.op maps.op\
413     hilb.op comm.op kstd1.op kstd2.op kutil.op khstd.op kstdfac.op modulop.op \
414     spolys.op ideals.op subexpr.op hdegree.op hutil.op ffields.op shortfl.op \
415     longalg.op spolys0.op syz.op syz0.op syz1.op weight.op \
416     ipid.op ipshell.op iplib.op ipassign.op ipconv.op ipprint.op\
417     polys.op polys0.op polys1.op polys-impl.op extra.op\
418     mminit.op sing_dld.op sing_dbm.op silink.op \
419     sing_mp.op fglm.op fglmzero.op fglmvec.op fglmgauss.op fglmhom.op\
420     algmap.op clapconv.op  clapmem.op clapsing.op \
421     cntrlc.op  \
422     mpsr_Error.op mpsr_Put.op mpsr_PutPoly.op mpsr_GetPoly.op \
423     mpsr_Get.op mpsr_GetMisc.op \
424     ndbm.op spSpolyLoop.op libparse.op  mod-${SINGUNAME}.op \
425        pcv.op
426
427OBJP2= mmalloc.op mmheap.op mmpage.op mmcheck.op mmbt.op \
428     mmisc.op mmtables.op weight0.op find_exec.op getopt.op fereadl.op
429
430OBJP=$(OBJP1) $(OBJP2) claptmpl.op
431
432##
433## .ob files for bprof
434##
435
436OBJB1=  grammar.ob scanner.ob matpol.ob binom.ob\
437     febase.ob feread.ob timer.ob intvec.ob attrib.ob lists.ob\
438     longrat.ob longrat0.ob misc.ob ring.ob numbers.ob maps.ob\
439     hilb.ob comm.ob kstd1.ob kstd2.ob kutil.ob khstd.ob kstdfac.ob modulop.ob \
440     spolys.ob ideals.ob subexpr.ob hdegree.ob hutil.ob ffields.ob shortfl.ob \
441     longalg.ob spolys0.ob syz.ob syz0.ob syz1.ob weight.ob \
442     ipid.ob ipshell.ob iplib.ob ipassign.ob ipconv.ob ipprint.ob\
443     polys.ob polys0.ob polys1.ob polys-impl.ob extra.ob\
444     mminit.ob sing_dld.ob sing_dbm.ob silink.ob \
445     sing_mp.ob fglm.ob fglmzero.ob fglmvec.ob fglmgauss.ob fglmhom.ob\
446     algmap.ob clapconv.ob  clapmem.ob clapsing.ob \
447     cntrlc.ob  \
448     mpsr_Error.ob mpsr_Put.ob mpsr_PutPoly.ob mpsr_GetPoly.ob \
449     mpsr_Get.ob mpsr_GetMisc.ob \
450     ndbm.ob spSpolyLoop.ob libparse.ob mod-${SINGUNAME}.ob \
451        pcv.ob
452
453OBJB2= mmalloc.ob mmheap.ob mmpage.ob mmcheck.ob mmbt.ob \
454     mmisc.ob mmtables.ob weight0.ob find_exec.ob getopt.ob fereadl.ob
455
456OBJB=$(OBJB1) $(OBJB2) claptmpl.ob
457
458##
459## profile targets
460##
461
462## for gprof
463claptmpl.op: claptmpl.cc mod2.h
464        $(CXXP)  ${CXXFLAGSP} ${CPPFLAGS} ${DEFSP} -c $< -o $@
465
466$(OBJP1): %.op: %.cc
467        $(CXXP) ${CXXFLAGSP} ${CXXTEMPLFLAGSP} ${CPPFLAGS} ${DEFSP} -c $< -o $@
468
469$(OBJP2) gmalloc.op: %.op: %.c
470        $(CCP)  ${CFLAGSP} ${CPPFLAGS} ${DEFSP} -c $< -o $@
471
472Singularp: scanner.cc  gmalloc.op $(OBJP) iparith.op mpsr_Tok.op tesths.cc version.h
473        $(CXXP) ${CXXFLAGSP} ${CPPFLAGS} ${DEFSP} -o Singularp \
474        tesths.cc iparith.op mpsr_Tok.op $(OBJP) ${LDFLAGSP} ${LIBS} \
475        ${LD_DYN_FLAGS} gmalloc.op
476
477iparith.op: iparith.inc iparith.cc
478        $(CXXP)  ${CXXFLAGSP} ${CPPFLAGS} ${DEFSP} -c iparith.cc -o iparith.op
479
480mpsr_Tok.op: iparith.inc mpsr_Tok.cc
481        $(CXXP) ${CXXFLAGSP} ${CPPFLAGS} ${DEFSP} -c mpsr_Tok.cc -o mpsr_Tok.op
482
483## for pbrof
484claptmpl.ob: claptmpl.cc mod2.h
485        $(CXXP)  ${CXXFLAGSB} ${CPPFLAGS} ${DEFSB} -c $< -o $@
486
487$(OBJB1): %.ob: %.cc
488        $(CXXP) ${CXXFLAGSB} ${CXXTEMPLFLAGSB} ${CPPFLAGS} ${DEFSB} -c $< -o $@
489
490$(OBJB2) gmalloc.ob: %.ob: %.c
491        $(CCP)  ${CFLAGSB} ${CPPFLAGS} ${DEFSB} -c $< -o $@
492
493Singularb: scanner.cc gmalloc.ob $(OBJB) iparith.ob mpsr_Tok.ob tesths.cc version.h
494        $(CXXP) ${CXXFLAGSB} ${CPPFLAGS} ${DEFSB} -o Singularb \
495        tesths.cc iparith.ob mpsr_Tok.ob $(OBJB)  $(BPROFOBJ) \
496        ${LDFLAGSB} ${LIBS} gmalloc.ob
497
498iparith.ob: iparith.inc iparith.cc
499        $(CXXP)  ${CXXFLAGSB} ${CPPFLAGS} ${DEFSB} -c iparith.cc -o iparith.ob
500
501mpsr_Tok.ob: iparith.inc mpsr_Tok.cc
502        $(CXXP) ${CXXFLAGSB} ${CPPFLAGS} ${DEFSB} -c mpsr_Tok.cc -o mpsr_Tok.ob
503
504
505installp: Singularp
506        ${MKINSTALLDIRS} ${bindir}
507        ${INSTALL_PROGRAM} Singularp ${bindir} 
508
509
510##
511## dependencies
512##
513%.dd: %.cc mod2.h
514        echo $(@:.dd=.og) $(@:.dd=.op) $(@:.dd=.ob) " " \\ > $@
515        $(CXXM) -DGENTABLE ${CPPFLAGS} ${DEFSG} $< >> $@
516
517%.d: %.c mod2.h
518        echo $(@:.d=.og) $(@:.d=.op) $(@:.d=.ob) " " \\ > $@
519        $(CCM) ${CPPFLAGS} ${DEFSG} $< >> $@
520
521depend: $(CXXSOURCES:.cc=.dd) $(CSOURCES:.c=.d) mod2.h
522        cat *.d *.dd >depend
523
524#include $(SOURCES:.cc=.dd) $(CSOURCES:.c=.d)
525#include *.d *.dd
526ifeq (depend,$(wildcard depend))
527include depend
528endif
529
530
Note: See TracBrowser for help on using the repository browser.