2 MAYBE_BERNSTEIN = bernstein
4 SUBDIRS = $(MAYBE_BERNSTEIN) lib . omega doc
6 AM_CPPFLAGS = -I$(srcdir)/bernstein/include -I$(srcdir)/lib @GINACLIB_CPPFLAGS@
9 lib_LTLIBRARIES = libbarvinok.la
10 bin_PROGRAMS = barvinok_count barvinok_enumerate barvinok_enumerate_e \
12 noinst_PROGRAMS = test randomtest \
13 remove_redundant_equalities \
14 barvinok_union barvinok_maximize polytope_volume \
16 EXTRA_PROGRAMS = piptest verify_lexsmaller polyhedron_sample 4coins lexmin \
18 pkginclude_HEADERS = \
27 barvinok/basis_reduction.h \
32 BERNSTEIN_CC = bernstein.cc
35 BR_CDD = basis_reduction_cdd.cc initcdd.cc
38 BR_GLPK = basis_reduction_glpk.c
40 libbarvinok_la_SOURCES = \
59 genfun_constructor.cc \
60 genfun_constructor.h \
80 EXTRA_libbarvinok_la_SOURCES = \
86 BERNSTEIN_LA = $(top_builddir)/bernstein/libbernstein.la
88 libbarvinok_la_LIBADD = @LTLIBOBJS@ $(BERNSTEIN_LA) lib/libgnu.la
89 libbarvinok_la_LDFLAGS = @BV_LDFLAGS@ -version-info @versioninfo@
90 LDADD = libbarvinok.la
93 barvinok_count_SOURCES = barvinok_count.c
94 barvinok_ehrhart_SOURCES = barvinok_ehrhart.cc
95 barvinok_union_SOURCES = barvinok_union.cc
97 BEEO_SOURCES = omega/Exit.cc omega/convert.cc
101 barvinok_enumerate_SOURCES = \
102 barvinok_enumerate.cc \
111 barvinok_enumerate_e_SOURCES = \
112 barvinok_enumerate_e.cc \
122 barvinok_enumerate_e_CPPFLAGS = @OMEGA_CPPFLAGS@ $(AM_CPPFLAGS)
123 barvinok_enumerate_e_LDFLAGS = @OMEGA_LDFLAGS@ @LDFLAGS@
124 barvinok_enumerate_e_LDADD = @OMEGA_LIBS@ libbarvinok.la
125 barvinok_maximize_SOURCES = \
133 4coins_SOURCES = 4coins.cc
135 POLYSIGN = polysign_cddf.cc polysign_cdd.cc
154 EXTRA_lexmin_SOURCE = polysign_cddf.cc polysign_cdd.cc polysign.c
156 TESTFILES = $(shell find $(top_srcdir)/tests -type f ! -path '*CVS*')
164 doc/applications.tex \
174 polymake/Makefile.in \
176 polymake/autogen.sh \
177 polymake/configure.in \
178 polymake/lattice_points.cc
180 ACLOCAL_AMFLAGS = -I m4
183 @test -z "$(pkgconfig_libdir)" || $(mkdir_p) "$(DESTDIR)$(pkgconfig_libdir)"
184 $(INSTALL_DATA) $(pkgconfig_libfile) "$(DESTDIR)$(pkgconfig_libdir)/$(pkgconfig_libfile)"
187 rm -f "$(DESTDIR)$(pkgconfig_libdir)/$(pkgconfig_libfile)"
190 (cd $(distdir)/polymake; \
191 ./autogen.sh; rm -rf autogen.sh autom4te.cache)
192 (cd doc; make barvinok.pdf)
193 cp doc/barvinok.pdf $(distdir)/doc/
194 if test -f $(top_srcdir)/.git/HEAD; then \
195 echo @GIT_HEAD_VERSION@ > $(distdir)/GIT_HEAD_ID; \
197 echo $(GIT_HEAD_ID) > $(distdir)/GIT_HEAD_ID; \
201 BEE_TESTDIRS = ehrhart_e ehrhart_e/scarf ehrhart_e/piplib
203 BEE_TESTDIRS = ehrhart_e ehrhart_e/scarf
206 check: check-enumerate check-enumerate_e check-test check-lexmin
207 check-enumerate: barvinok_enumerate
208 @for i in $(top_srcdir)/tests/ehrhart/*; do \
209 if test -f $$i; then \
211 for options in '' '--series' '--series --primal'; do \
212 for spec in 'random' 'bf' 'df'; do \
213 opt="--specialization=$$spec $$options"; \
215 ./barvinok_enumerate --verify $$opt < $$i; \
220 check-enumerate_e: barvinok_enumerate_e
221 @for dir in $(BEE_TESTDIRS); do \
222 for i in $(top_srcdir)/tests/$$dir/*; do \
223 if test -f $$i; then \
224 for options in '' '--pip' '--pip --omega'; do \
225 for spec in 'random' 'bf' 'df'; do \
226 opt="--specialization=$$spec $$options"; \
228 ./barvinok_enumerate_e --verify $$opt < $$i; \
234 @for i in $(top_srcdir)/tests/ehrhart_e/scarf/*; do \
235 if test -f $$i; then \
236 for spec in 'random' 'bf' 'df'; do \
237 opt="--specialization=$$spec --scarf"; \
239 ./barvinok_enumerate_e --verify $$opt < $$i; \
244 @for i in $(top_srcdir)/tests/*; do \
245 if test -f $$i; then \
246 for options in '--index=10' '--primal --index=10'; do \
247 for spec in 'random' 'bf' 'df'; do \
248 opt="--specialization=$$spec $$options"; \
250 ./test $$opt < $$i || echo -n " NOT"; \
258 @for i in $(top_srcdir)/tests/lexmin/*; do \
259 if test -f $$i; then \
260 for spec in 'random' 'bf' 'df'; do \
261 opt="--specialization=$$spec"; \
263 ./lexmin --verify $$opt < $$i; \
271 version.h: @GIT_HEAD@
272 echo '#define GIT_HEAD_ID "'@GIT_HEAD_VERSION@'"' > $@