source: git/factory/Makefile.am @ 1d3be3

spielwiese
Last change on this file since 1d3be3 was 1d3be3, checked in by Oleksandr Motsak <motsak@…>, 12 years ago
ADD: consistently define HAVE_CONFIG_H in automake CPPFLAGS
  • Property mode set to 100644
File size: 8.7 KB
Line 
1ACLOCAL_AMFLAGS = -I ../m4
2
3CXXTEMPLFLAGS      =  --no-exceptions ## -fno-implicit-templates
4
5INCLUDES = -I${top_srcdir} -I${top_srcdir}/.. -I${top_builddir} -I${top_builddir}/.. -I${srcdir} ${GMP_CFLAGS} ${NTL_CFLAGS}
6
7lib_LTLIBRARIES = libfactory.la libfactory_g.la
8
9libfactory_la_libdir = $(libdir)
10libfactory_g_la_libdir = $(libdir)
11
12libfactory_la_CXXFLAGS   = -O3 -fomit-frame-pointer --no-rtti ${CXXTEMPLFLAGS}
13libfactory_g_la_CXXFLAGS = -g -Wextra -Wall -pedantic -Wno-long-long ${CXXTEMPLFLAGS}
14
15# factory source files
16SOURCES = \
17                algext.cc \
18                canonicalform.cc \
19                cf_algorithm.cc \
20                cf_binom.cc \
21                cf_char.cc \
22                cf_chinese.cc \
23                cf_cyclo.cc \
24                cf_eval.cc \
25                cf_factor.cc \
26                cf_factory.cc \
27                cf_gcd.cc \
28                cf_gcd_smallp.cc \
29                cf_generator.cc \
30                cf_globals.cc \
31                cf_hnf.cc \
32                cf_inline.cc \
33                cf_irred.cc \
34                cf_iter.cc \
35                cf_iter_inline.cc \
36                cf_linsys.cc \
37                cf_map.cc \
38                cf_map_ext.cc \
39                cfNewtonPolygon.cc \
40                cfModResultant.cc \
41                cf_ops.cc \
42                cf_primes.cc \
43                cf_random.cc \
44                cf_resultant.cc \
45                cf_reval.cc \
46                cf_switches.cc \
47                cf_util.cc \
48                debug.cc \
49                DegreePattern.cc \
50                ExtensionInfo.cc \
51                facAlgExt.cc \
52                facBivar.cc \
53                fac_berlekamp.cc \
54                fac_cantzass.cc \
55                fac_distrib.cc \
56                fac_ezgcd.cc \
57                facFactorize.cc \
58                fac_iterfor.cc \
59                fac_multihensel.cc \
60                fac_multivar.cc \
61                fac_sqrfree.cc \
62                fac_univar.cc \
63                fac_util.cc \
64                facFqBivar.cc \
65                facFqBivarUtil.cc \
66                facFqFactorize.cc \
67                facFqFactorizeUtil.cc \
68                facFqSquarefree.cc \
69                facHensel.cc \
70                facIrredTest.cc \
71                fieldGCD.cc \
72                ffops.cc \
73                gf_tabutil.cc \
74                gfops.cc \
75                imm.cc \
76                int_cf.cc \
77                int_int.cc \
78                int_intdiv.cc \
79                int_poly.cc \
80                int_pp.cc \
81                int_rat.cc \
82                sm_sparsemod.cc \
83                sm_util.cc \
84                variable.cc \
85                NTLconvert.cc \
86                abs_fac.cc \
87                bifac.cc \
88                lgs.cc \
89                singext.cc \
90                parseutil.cc \
91                ftmpl_inst.cc
92
93if WITH_PARSER_FOR_CANONICAL_FORM
94    SOURCES +=  readcf.yy
95endif
96
97libfactory_la_SOURCES = $(SOURCES)
98libfactory_g_la_SOURCES = $(SOURCES)
99
100libfactory_la_CPPFLAGS  = -DHAVE_CONFIG_H -DOM_NDEBUG -DNDEBUG
101libfactory_g_la_CPPFLAGS= -DHAVE_CONFIG_H
102
103nodist_libfactory_la_SOURCES = cplusplus.h factory.h factoryconf.h
104nodist_libfactory_g_la_SOURCES = cplusplus.h factory.h factoryconf.h
105
106
107# factory header files
108factory_headers = \
109                cf_assert.h \
110                canonicalform.h \
111                cf_algorithm.h \
112                cf_cyclo.h \
113                cf_binom.h \
114                cf_defs.h \
115                cf_eval.h \
116                cf_factory.h \
117                cf_generator.h \
118                cf_globals.h \
119                cf_gcd_smallp.h \
120                cf_hnf.h \
121                cf_irred.h \
122                cf_iter.h \
123                cf_map.h \
124                cf_map_ext.h \
125                cfNewtonPolygon.h \
126                cfModResultant.h \
127                cf_primes.h \
128                cf_primetab.h \
129                cf_random.h \
130                cf_reval.h \
131                cf_switches.h \
132                cf_util.h \
133                debug.h \
134                DegreePattern.h \
135                ExtensionInfo.h \
136                facAlgExt.h \
137                facBivar.h \
138                fac_berlekamp.h \
139                fac_cantzass.h \
140                fac_distrib.h \
141                facFactorize.h \
142                fac_iterfor.h \
143                fac_multivar.h \
144                fac_sqrfree.h \
145                fac_univar.h \
146                fac_util.h \
147                facFqBivar.h \
148                facFqBivarUtil.h \
149                facFqFactorize.h \
150                facFqFactorizeUtil.h \
151                facFqSquarefree.h \
152                facHensel.h \
153                facIrredTest.h \
154                fieldGCD.h \
155                ffops.h \
156                gf_tabutil.h \
157                gfops.h \
158                gmpext.h \
159                imm.h \
160                int_cf.h \
161                int_int.h \
162                int_poly.h \
163                int_pp.h \
164                int_rat.h \
165                sm_sparsemod.h \
166                sm_util.h \
167                timing.h \
168                variable.h \
169                NTLconvert.h \
170                bifac.h \
171                bifacConfig.h \
172                lgs.h \
173                algext.h \
174                singext.h \
175                parseutil.h
176
177noinst_HEADERS = $(factory_headers)
178
179libfactory_includedir=$(includedir)/factory
180
181nobase_libfactory_include_HEADERS = \
182    cf_gmp.h $(templateincl)
183
184nodist_libfactory_include_HEADERS = cplusplus.h factory.h factoryconf.h
185
186
187####################################################
188# Documentation
189include $(top_srcdir)/aminclude.am
190
191doxysrc = $(SOURCES) parseutil.cc
192doxyincl = $(factory_headers) parseutil.h
193
194# doxygen targets
195doxy:           factory.cfg $(doxysrc) $(doxyincl)
196                doxygen $<
197
198doxyclean:
199                rm -rf doxygen
200
201####################################################
202# the precomputed GF(q)-tables
203
204gftablesdir=$(datadir)/gftables
205dist_gftables_DATA = gftables/10201 gftables/1024 gftables/10609 gftables/11449 \
206gftables/11881 gftables/121 gftables/12167 gftables/125 gftables/12769 \
207gftables/128 gftables/1331 gftables/1369 gftables/14641 \
208gftables/15625 gftables/16 gftables/16129 gftables/16384 \
209gftables/16807 gftables/1681 gftables/169 gftables/17161 gftables/1849 \
210gftables/18769 gftables/19321 gftables/19683 gftables/2048 \
211gftables/2187 gftables/2197 gftables/2209 gftables/22201 \
212gftables/22801 gftables/2401 gftables/243 gftables/24389 \
213gftables/24649 gftables/25 gftables/256 gftables/26569 gftables/27 \
214gftables/27889 gftables/2809 gftables/28561 gftables/289 \
215gftables/29791 gftables/29929 gftables/3125 gftables/32 gftables/32041 \
216gftables/32761 gftables/32768 gftables/343 gftables/3481 gftables/361 \
217gftables/36481 gftables/3721 gftables/37249 gftables/38809 \
218gftables/39601 gftables/4 gftables/4096 gftables/44521 gftables/4489 \
219gftables/49 gftables/4913 gftables/49729 gftables/5041 \
220gftables/50653 gftables/512 gftables/51529 gftables/52441 gftables/529 \
221gftables/5329 gftables/54289 gftables/57121 gftables/58081 \
222gftables/59049 gftables/6241 gftables/625 gftables/63001 \
223gftables/64 gftables/6561 gftables/6859 gftables/6889 gftables/729 \
224gftables/7921 gftables/8 gftables/81 gftables/8192 gftables/841 \
225gftables/9 gftables/9409 gftables/961
226
227
228####################################################
229# Support for building GF(q)-tables
230#
231# gengftables needs libfactory.la and factory.h AND is needed for
232# generating gftable but the tables are not necessarily needed to
233# compile and use libfactory (though it will be a lot slower).
234
235EXTRA_PROGRAMS = gengftables
236gengftables_SOURCES = gengftables-conway.cc
237gengftables_LDADD = -L${builddir} -lfactory $(GMP_LIBS) $(NTL_LIBS)
238
239
240####################################################
241# These files listed below are not used anywhere but are included in
242# the distribution. So they will be tacked on to EXTRA_DIST.
243
244templatesrc =   templates/ftmpl_array.cc \
245                templates/ftmpl_factor.cc \
246                templates/ftmpl_functions.h \
247                templates/ftmpl_list.cc \
248                templates/ftmpl_matrix.cc
249
250templateincl =  templates/ftmpl_array.h \
251                templates/ftmpl_factor.h \
252                templates/ftmpl_list.h \
253                templates/ftmpl_matrix.h
254
255# header templates
256hdrtemplsrc =   factoryconf.template \
257                factory.template
258
259# FTE source files
260ftestsrc =      ftest/ftest_io.cc \
261                ftest/ftest_util.cc \
262                ftest/ntl_util.cc
263
264# FTE header files
265ftestincl =     ftest/ftest_io.h \
266                ftest/ftest_util.h \
267                ftest/ntl_util.h
268
269ftestm4src =    ftest/commonden.m4 \
270                ftest/degree.m4 \
271                ftest/deriv.m4 \
272                ftest/divides.m4 \
273                ftest/divrem.m4 \
274                ftest/extgcd.m4 \
275                ftest/factorize.m4 \
276                ftest/fbinops.m4 \
277                ftest/feval.m4 \
278                ftest/gcd.m4 \
279                ftest/gcd.ntl.m4 \
280                ftest/insert.m4 \
281                ftest/norm.m4 \
282                ftest/resultant.m4 \
283                ftest/revert.m4 \
284                ftest/sqrfree.m4 \
285                ftest/size.m4 \
286                ftest/totaldegree.m4
287
288ftestdistfiles = \
289                ftest/ftest_util.m4
290
291EXTRA_DIST =    test_install.cc \
292                $(templatesrc) $(hdrtemplsrc) \
293                $(ftestsrc) $(ftestincl) $(ftestm4src) $(ftestdistfiles) \
294                doxygen.cfg factory.cfg \
295                examples/application.cc \
296                examples/factorize.cc examples/gcd.cc \
297                bin/folding.el bin/fold-docu.el \
298                bin/makeheader bin/gen-readcf readcf.yy
299
300##################################################
301# autogenerated sources
302
303noinst_PROGRAMS = cplusplus
304
305BUILT_SOURCES = cplusplus.h factory.h factoryconf.h
306
307CLEANFILES = $(BUILT_SOURCES)
308
309
310cplusplus_SOURCES = cplusplus.cc
311
312cplusplus.h: cplusplus
313        ${abs_builddir}/cplusplus > ${abs_builddir}/cplusplus.h
314
315.template.h:
316        ${srcdir}/bin/makeheader $< $@
317
318# factory/gfops.cc has the gftables path hardcoded in, so we create a
319# symlink. Remove this rule once gfopts.cc has been fixed. Note that
320# check-local would run in parallel with check, so we can't use it
321# here!
322all-local:
323        [ -d ${builddir}/gftables ] || ln -s ${srcdir}/gftables ${builddir}
324
325####################################################
326## Test program
327##
328TESTS = test-s-g test-s-r test-d-g test-d-r
329check_PROGRAMS = $(TESTS)
330
331TESTSSOURCES = test.cc
332
333test_s_g_SOURCES = $(TESTSSOURCES)
334test_s_g_CFLAGS = -g -Wextra -Wall -pedantic -Wno-long-long -fomit-frame-pointer --no-rtti
335#ftmpl_inst.o
336test_s_g_LDADD = -L${builddir} -lfactory_g $(GMP_LIBS) $(NTL_LIBS)
337
338test_s_r_SOURCES = $(TESTSSOURCES)
339test_s_r_CFLAGS = -O3 -fomit-frame-pointer --no-rtti
340#ftmpl_inst.o
341test_s_r_LDADD = -L${builddir} -lfactory $(GMP_LIBS) $(NTL_LIBS)
342
343test_s_r_LDFLAGS = -static
344test_s_g_LDFLAGS = -static
345
346
347
348test_d_g_SOURCES = $(TESTSSOURCES)
349test_d_g_CFLAGS = -g -Wextra -Wall -pedantic -Wno-long-long -fomit-frame-pointer --no-rtti
350#ftmpl_inst.o
351test_d_g_LDADD = -L${builddir} -lfactory_g $(GMP_LIBS) $(NTL_LIBS)
352
353test_d_r_SOURCES = $(TESTSSOURCES)
354test_d_r_CFLAGS = -O3 -fomit-frame-pointer --no-rtti
355#ftmpl_inst.o
356test_d_r_LDADD = -L${builddir} -lfactory $(GMP_LIBS) $(NTL_LIBS)
Note: See TracBrowser for help on using the repository browser.