source: git/Singular/Makefile.am @ 3cc5ad

fieker-DuValspielwiese
Last change on this file since 3cc5ad was 3cc5ad, checked in by Oleksandr Motsak <motsak@…>, 10 years ago
Fixed Singular/iparith.inc generation/dependencies (but no plural_cmd.inc)
  • Property mode set to 100644
File size: 7.4 KB
Line 
1ACLOCAL_AMFLAGS = -I ../m4
2
3GIT_VERSION := $(shell $(top_srcdir)/git-version-gen $(top_srcdir)/.tarball-git-version)
4
5AM_CPPFLAGS = -I${top_srcdir} -I${top_builddir} -I${top_srcdir}/kernel -I${top_builddir}/kernel -I${top_srcdir}/libpolys -I${top_builddir}/libpolys $(FACTORY_INCLUDES)  $(GMP_CFLAGS) $(NTL_CFLAGS) $(FLINT_CFLAGS) -DGIT_VERSION='"$(GIT_VERSION)"'
6
7SUBDIRS = dyn_modules
8
9########################### Possible builtin modules... #########################
10BUILTIN_FLAGS = ${BUILTIN_LIBS}
11
12########################### libSingular* #########################
13
14libSingular_LTLIBRARIES = libSingular.la
15libSingulardir = $(libdir)
16
17libSingular_la_CPPFLAGS = ${AM_CPPFLAGS} -DLIBSINGULAR ${PTHREAD_CFLAGS}
18
19SOURCES = \
20   links/asciiLink.cc\
21   attrib.cc\
22   blackbox.cc\
23   calcSVD.cc\
24   cntrlc.cc\
25   countedref.cc\
26   denom_list.cc\
27   eigenval_ip.cc\
28   extra.cc\
29   feOpt.cc\
30   fehelp.cc\
31   fevoices.cc\
32   fglm.cc\
33   gms.cc\
34   grammar.cc\
35   iparith.cc\
36   ipassign.cc\
37   ipconv.cc\
38   ipid.cc\
39   iplib.cc\
40   ipprint.cc\
41   ipshell.cc\
42   libparse.cc\
43   linearAlgebra_ip.cc\
44   lists.cc\
45   maps_ip.cc\
46   misc_ip.cc\
47   mod_lib.cc\
48   links/ndbm.cc\
49   newstruct.cc\
50   number2.cc\
51   pcv.cc\
52   links/pipeLink.cc\
53   scanner.cc\
54   sdb.cc\
55   links/silink.cc\
56   links/sing_dbm.cc\
57   sing_win.cc\
58   links/slInit_Static.cc\
59   links/ssiLink.cc\
60   links/semaphore.c\
61   subexpr.cc\
62   pyobject_setup.cc\
63   walk.cc\
64   walk_ip.cc\
65   wrapper.cc\
66   mmstd.c claptmpl.cc\
67   febase.cc
68
69#   links/slInit_Dynamic.cc
70
71libSingular_la_SOURCES   = $(SOURCES)
72
73SingularHEADERS = \
74   attrib.h \
75   blackbox.h \
76   cntrlc.h \
77   countedref.h \
78   links/dbm_sl.h \
79   distrib.h \
80   eigenval_ip.h \
81   feOpt.h feOptTab.h fehelp.h \
82   fglm.h \
83   gms.h \
84   grammar.h \
85   idrec.h \
86   ipconv.h \
87   ipid.h \
88   ipprint.h \
89   ipshell.h \
90   libparse.h \
91   libsingular.h \
92   linearAlgebra_ip.h\
93   lists.h \
94   locals.h \
95   maps_ip.h \
96   misc_ip.h \
97   mmalloc.h \
98   mod_lib.h \
99   number2.h \
100   omSingularConfig.h \
101   links/ndbm.h \
102   newstruct.h \
103   pcv.h \
104   links/pipeLink.h \
105   pyobject_setup.h \
106   run.h \
107   sdb.h \
108   links/silink.h \
109   links/sing_dbm.h \
110   sing_win.h \
111   links/slInit.h \
112   links/ssiLink.h \
113   links/simpleipc.h \
114   stype.h \
115   subexpr.h \
116   table.h \
117   tok.h \
118   walk.h \
119   fevoices.h
120
121
122# -DMAKE_DISTRIBUTION
123
124# plural_cmd.inc
125nodist_libSingular_la_SOURCES = feOpt.inc iparith.inc
126
127libSingular_la_LDFLAGS    =${USEPPROCSDYNAMICLDFLAGS} ${USEPPROCSDYNAMICLD} -release ${PACKAGE_VERSION} ${PTHREAD_LDFLAGS}
128libSingular_la_LIBADD     =${USEPPROCSDYNAMICLDFLAGS} ${USEPPROCSDYNAMICLD} ${BUILTIN_FLAGS} ${top_builddir}/kernel/libkernel.la ${PTHREAD_LIBS}
129
130libSingular_includedir = ${includedir}/singular/Singular
131nobase_libSingular_include_HEADERS = $(SingularHEADERS)
132
133#########################################################
134# handle all the generated *.inc
135
136noinst_PROGRAMS = gentable1 feOptGen feOptES feOptTS
137
138gentable1_SOURCES = gentable.cc grammar.h tok.h table.h
139gentable1_CPPFLAGS = ${AM_CPPFLAGS}
140
141feOptGen_SOURCES = feOptGen.cc feOptGen.h
142feOptGen_CPPFLAGS = ${AM_CPPFLAGS}
143
144feOptES_SOURCES = feOptGen.cc feOptGen.h
145feOptES_CPPFLAGS = ${AM_CPPFLAGS} -DESINGULAR
146
147feOptTS_SOURCES = feOptGen.cc feOptGen.h
148feOptTS_CPPFLAGS = ${AM_CPPFLAGS} -DTSINGULAR
149
150########################### Singular* #########################
151
152EXTRA_PROGRAMS =  libparse Singulard
153
154# the "optional_programs" variable should be defined in the configure
155# script, and listed in an AC_SUBST macro
156optional_Singular_programs =
157
158bin_PROGRAMS = Singular ESingular TSingular $(optional_Singular_programs)
159
160Singular ESingular TSingular $(optional_Singular_programs): ${abs_builddir}/LIB
161
162Singular_SOURCES = tesths.cc mmalloc.cc fegetopt.c fegetopt.h utils.cc  utils.h
163
164Singular_LDADD = libSingular.la ${BUILTIN_FLAGS}
165
166Singular_LDFLAGS = -static ${AM_LDFLAGS} ${BUILTIN_FLAGS}
167
168Singulard_SOURCES = tesths.cc mmalloc.cc fegetopt.c fegetopt.h utils.cc  utils.h
169
170Singulard_LDADD = libSingular.la ${BUILTIN_FLAGS}
171
172Singulard_LDFLAGS = -shared ${AM_LDFLAGS} ${BUILTIN_FLAGS}
173
174scriptdir = $(libexecdir)/singular/MOD
175dist_script_SCRIPTS = singularsurf
176
177#### ESingular
178ESingular_CPPFLAGS = ${AM_CPPFLAGS} -DESINGULAR -DPROTO
179# ESingular_LDFLAGS = -static ${AM_LDFLAGS}
180ESingular_LDADD =  ${top_builddir}/libpolys/reporter/libreporter.la \
181${top_builddir}/libpolys/misc/libmisc.la ${top_builddir}/omalloc/libomalloc.la \
182${top_builddir}/resources/libresources.la
183
184
185ESingular_SOURCES = emacs.cc fegetopt.c fegetopt.h feOptES.inc feOpt.cc
186
187#### same for TSingular
188TSingular_CPPFLAGS = ${AM_CPPFLAGS} -DTSINGULAR -DPROTO
189# TSingular_LDFLAGS = -static ${AM_LDFLAGS}
190TSingular_LDADD = ${top_builddir}/libpolys/reporter/libreporter.la \
191${top_builddir}/libpolys/misc/libmisc.la ${top_builddir}/omalloc/libomalloc.la \
192${top_builddir}/resources/libresources.la
193
194TSingular_SOURCES = emacs.cc fegetopt.c fegetopt.h feOptTS.inc feOpt.cc
195# utils.cc utils.h
196
197
198#### libparse
199libparse_CPPFLAGS = ${AM_CPPFLAGS} -DSTANDALONE_PARSER
200
201libparse_SOURCES = libparse.cc fegetopt.c fegetopt.h utils.cc  utils.h
202
203libparse_LDADD = ${top_builddir}/omalloc/libomalloc.la
204libparse_LDFLAGS = -static ${AM_LDFLAGS}
205
206#########################################################
207# the Singular library (*.lib files)
208
209include ${srcdir}/singular-libs
210
211singularlibrarydir = ${datadir}/singular
212singularlibrary = $(SLIB0:%=LIB/%) $(SLIB1:%=LIB/%) $(PLIBS:%=LIB/%)
213nobase_dist_singularlibrary_DATA = LIB/tst.lib LIB/help.cnf ${singularlibrary}
214EXTRA_DIST = make_alllib.sh LIB/all.lib.tmpl singular-libs \
215             LIB/help.cnf links/slInit_Dynamic.cc
216
217singularalllibrarydir = ${datadir}/singular/LIB
218singularalllibrary = all.lib
219nobase_dist_singularalllibrary_DATA = all.lib
220
221all.lib: ${srcdir}/make_alllib.sh ${srcdir}/LIB/all.lib.tmpl ${singularlibrary}
222        ${srcdir}/make_alllib.sh ${srcdir}/LIB/all.lib.tmpl ${SLIB0} ${PLIBS}
223
224########################### TEST #########################
225TESTS_ENVIRONMENT = SINGULARPATH='${top_builddir}/Singular/LIB:${top_srcdir}/Singular/LIB:${top_builddir}/libpolys/polys/.libs:${top_builddir}/factory/gftables'
226TESTS_ENVIRONMENT += SINGULAR_ROOT_DIR='${top_builddir}'
227
228TESTS=test
229
230check_PROGRAMS=$(TESTS)
231
232test_SOURCES = test.cc
233test_LDADD = libSingular.la
234
235#########################################################
236### plural_cmd.inc
237# These files are built first
238BUILT_SOURCES = feOpt.inc feOptTS.inc feOptES.inc iparith.inc all.lib gftables MOD
239
240CLEANFILES = $(BUILT_SOURCES) $(EXTRA_PROGRAMS)
241
242clean-local:
243        if [ "${abs_builddir}" != "${abs_srcdir}" ]; then \
244          if [ -L ${abs_builddir}/LIB ]; then unlink ${abs_builddir}/LIB; fi \
245        fi
246
247feOpt.inc: feOptGen$(EXEEXT)
248        ${builddir}/feOptGen$(EXEEXT)
249
250feOptES.inc: feOptES$(EXEEXT)
251        ${builddir}/feOptES$(EXEEXT)
252
253feOptTS.inc: feOptTS$(EXEEXT)
254        ${builddir}/feOptTS$(EXEEXT)
255
256# plural_cmd.inc is only necessary for documentation generation
257#plural_cmd.inc: gentable1$(EXEEXT)
258#       ${builddir}/gentable1$(EXEEXT) argument
259
260iparith.inc: gentable1$(EXEEXT) table.h
261        ${builddir}/gentable1$(EXEEXT)
262
263# # fake rule to fix parallel make http://www.gnu.org/s/hello/manual/automake/Multiple-Outputs.html
264
265gftables: ${top_srcdir}/factory/gftables
266        ln -snf ${top_srcdir}/factory/gftables ${builddir}/gftables
267
268${abs_builddir}/LIB: ${srcdir}/LIB
269        if [ "${abs_builddir}" != "${abs_srcdir}" ]; then \
270          ln -snf ${abs_srcdir}/LIB ${abs_builddir}/; \
271        fi
272
273MOD:
274        if [ -d "${top_builddir}/libpolys/polys/.libs" ]; then \
275          ln -snf ${top_builddir}/libpolys/polys/.libs/ ${abs_builddir}/MOD; \
276        fi       
277
Note: See TracBrowser for help on using the repository browser.