source: git/factory/Makefile.am @ 3af3ca

spielwiese
Last change on this file since 3af3ca was 3af3ca, checked in by Oleksandr Motsak <motsak@…>, 13 years ago
FIX: public factory config.h should have ifndef/define/endif guards!
  • Property mode set to 100644
File size: 7.8 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_LIBRARIES = libfactory.a libfactory_g.a
8
9libfactory_a_libdir = $(libdir)
10libfactory_g_a_libdir = $(libdir)
11
12libfactory_a_CXXFLAGS   = -O3 -fomit-frame-pointer --no-rtti ${CXXTEMPLFLAGS}
13libfactory_g_a_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_a_SOURCES = $(SOURCES)
98libfactory_g_a_SOURCES = $(SOURCES)
99
100# factory header files
101factory_headers = \
102                cf_assert.h \
103                canonicalform.h \
104                cf_algorithm.h \
105                cf_cyclo.h \
106                cf_binom.h \
107                cf_defs.h \
108                cf_eval.h \
109                cf_factory.h \
110                cf_generator.h \
111                cf_globals.h \
112                cf_gcd_smallp.h \
113                cf_hnf.h \
114                cf_irred.h \
115                cf_iter.h \
116                cf_map.h \
117                cf_map_ext.h \
118                cfNewtonPolygon.h \
119                cfModResultant.h \
120                cf_primes.h \
121                cf_primetab.h \
122                cf_random.h \
123                cf_reval.h \
124                cf_switches.h \
125                cf_util.h \
126                debug.h \
127                DegreePattern.h \
128                ExtensionInfo.h \
129                facAlgExt.h \
130                facBivar.h \
131                fac_berlekamp.h \
132                fac_cantzass.h \
133                fac_distrib.h \
134                facFactorize.h \
135                fac_iterfor.h \
136                fac_multivar.h \
137                fac_sqrfree.h \
138                fac_univar.h \
139                fac_util.h \
140                facFqBivar.h \
141                facFqBivarUtil.h \
142                facFqFactorize.h \
143                facFqFactorizeUtil.h \
144                facFqSquarefree.h \
145                facHensel.h \
146                facIrredTest.h \
147                fieldGCD.h \
148                ffops.h \
149                gf_tabutil.h \
150                gfops.h \
151                gmpext.h \
152                imm.h \
153                int_cf.h \
154                int_int.h \
155                int_poly.h \
156                int_pp.h \
157                int_rat.h \
158                sm_sparsemod.h \
159                sm_util.h \
160                timing.h \
161                variable.h \
162                NTLconvert.h \
163                bifac.h \
164                bifacConfig.h \
165                lgs.h \
166                algext.h \
167                singext.h \
168                parseutil.h
169
170noinst_HEADERS = $(factory_headers)
171
172libfactory_includedir=$(includedir)/factory
173nobase_libfactory_include_HEADERS = \
174                cplusplus.h factory.h factoryconf.h \
175                cf_gmp.h $(templateincl)
176
177# Documentation
178include $(top_srcdir)/aminclude.am
179
180doxysrc = $(SOURCES) parseutil.cc
181doxyincl = $(factory_headers) parseutil.h
182
183# doxygen targets
184doxy:           factory.cfg $(doxysrc) $(doxyincl)
185                doxygen $<
186
187doxyclean:
188                rm -rf doxygen
189
190# the precomputed GF(q)-tables
191
192gftablesdir=$(datadir)/gftables
193dist_gftables_DATA = gftables/10201 gftables/1024 gftables/10609 gftables/11449 \
194gftables/11881 gftables/121 gftables/12167 gftables/125 gftables/12769 \
195gftables/128 gftables/1331 gftables/1369 gftables/14641 \
196gftables/15625 gftables/16 gftables/16129 gftables/16384 \
197gftables/16807 gftables/1681 gftables/169 gftables/17161 gftables/1849 \
198gftables/18769 gftables/19321 gftables/19683 gftables/2048 \
199gftables/2187 gftables/2197 gftables/2209 gftables/22201 \
200gftables/22801 gftables/2401 gftables/243 gftables/24389 \
201gftables/24649 gftables/25 gftables/256 gftables/26569 gftables/27 \
202gftables/27889 gftables/2809 gftables/28561 gftables/289 \
203gftables/29791 gftables/29929 gftables/3125 gftables/32 gftables/32041 \
204gftables/32761 gftables/32768 gftables/343 gftables/3481 gftables/361 \
205gftables/36481 gftables/3721 gftables/37249 gftables/38809 \
206gftables/39601 gftables/4 gftables/4096 gftables/44521 gftables/4489 \
207gftables/49 gftables/4913 gftables/49729 gftables/5041 \
208gftables/50653 gftables/512 gftables/51529 gftables/52441 gftables/529 \
209gftables/5329 gftables/54289 gftables/57121 gftables/58081 \
210gftables/59049 gftables/6241 gftables/625 gftables/63001 \
211gftables/64 gftables/6561 gftables/6859 gftables/6889 gftables/729 \
212gftables/7921 gftables/8 gftables/81 gftables/8192 gftables/841 \
213gftables/9 gftables/9409 gftables/961
214
215
216# Support for building GF(q)-tables
217#
218# gengftables needs libfactory.a and factory.h AND is needed for
219# generating gftable but the tables are not necessarily needed to
220# compile and use libfactory (though it will be a lot slower).
221
222EXTRA_PROGRAMS = gengftables
223gengftables_SOURCES = gengftables-conway.cc
224gengftables_LDADD = -L${builddir} -lfactory $(GMP_LIBS) $(NTL_LIBS)
225
226
227# These files listed below are not used anywhere but are included in
228# the distribution. So they will be tacked on to EXTRA_DIST.
229
230templatesrc =   templates/ftmpl_array.cc \
231                templates/ftmpl_factor.cc \
232                templates/ftmpl_functions.h \
233                templates/ftmpl_list.cc \
234                templates/ftmpl_matrix.cc
235
236templateincl =  templates/ftmpl_array.h \
237                templates/ftmpl_factor.h \
238                templates/ftmpl_list.h \
239                templates/ftmpl_matrix.h
240
241# header templates
242hdrtemplsrc =   factoryconf.template \
243                factory.template
244
245# FTE source files
246ftestsrc =      ftest/ftest_io.cc \
247                ftest/ftest_util.cc \
248                ftest/ntl_util.cc
249
250# FTE header files
251ftestincl =     ftest/ftest_io.h \
252                ftest/ftest_util.h \
253                ftest/ntl_util.h
254
255ftestm4src =    ftest/commonden.m4 \
256                ftest/degree.m4 \
257                ftest/deriv.m4 \
258                ftest/divides.m4 \
259                ftest/divrem.m4 \
260                ftest/extgcd.m4 \
261                ftest/factorize.m4 \
262                ftest/fbinops.m4 \
263                ftest/feval.m4 \
264                ftest/gcd.m4 \
265                ftest/gcd.ntl.m4 \
266                ftest/insert.m4 \
267                ftest/norm.m4 \
268                ftest/resultant.m4 \
269                ftest/revert.m4 \
270                ftest/sqrfree.m4 \
271                ftest/size.m4 \
272                ftest/totaldegree.m4
273
274ftestdistfiles = \
275                ftest/ftest_util.m4
276
277EXTRA_DIST =    test_install.cc \
278                $(templatesrc) $(hdrtemplsrc) \
279                $(ftestsrc) $(ftestincl) $(ftestm4src) $(ftestdistfiles) \
280                doxygen.cfg factory.cfg \
281                examples/application.cc \
282                examples/factorize.cc examples/gcd.cc \
283                bin/folding.el bin/fold-docu.el \
284                bin/makeheader bin/gen-readcf
285
286##################################################
287# autogenerated sources
288
289noinst_PROGRAMS = cplusplus
290
291BUILT_SOURCES = cplusplus.h factory.h factoryconf.h readcf.cc
292
293CLEANFILES = $(BUILT_SOURCES)
294
295
296cplusplus_SOURCES = cplusplus.cc
297
298cplusplus.h: cplusplus
299        ${builddir}/cplusplus > ${builddir}/cplusplus.h
300
301.template.h:
302        ${srcdir}/bin/makeheader $< $@
303
304# factory/gfops.cc has the gftables path hardcoded in, so we create a
305# symlink. Remove this rule once gfopts.cc has been fixed. Note that
306# check-local would run in parallel with check, so we can't use it
307# here!
308all-local:
309        [ -d ${builddir}/gftables ] || ln -s ${srcdir}/gftables ${builddir}
310
311####################################################
312## Test program
313##
314TESTS = test-g test-r
315check_PROGRAMS = $(TESTS)
316
317TESTSSOURCES = test.cc
318
319test_g_SOURCES = $(TESTSSOURCES)
320test_g_CFLAGS = -g -Wextra -Wall -pedantic -Wno-long-long -fomit-frame-pointer --no-rtti #ftmpl_inst.o
321test_g_LDADD = -L${builddir} -lfactory_g $(GMP_LIBS) $(NTL_LIBS)
322
323test_r_SOURCES = $(TESTSSOURCES)
324test_r_CFLAGS = -O3 -fomit-frame-pointer --no-rtti #ftmpl_inst.o
325test_r_LDADD = -L${builddir} -lfactory $(GMP_LIBS) $(NTL_LIBS)
326
327
328####################################################
329## The following is due to AX_PREFIX_CONFIG_H
330##
331
332# DISTCLEANFILES=_configs.sed factory_config.h
Note: See TracBrowser for help on using the repository browser.