lexmin.cc: use barvinok_options
[barvinok.git] / Makefile.am
blobe8bdff2e5ca99249f977073780dc8f004c5d6e2c
1 SUBDIRS = . omega doc
3 lib_LTLIBRARIES = libbarvinok.la
4 noinst_PROGRAMS = test barvinok_count randomtest barvinok_enumerate \
5                   barvinok_ehrhart \
6                   verif_ehrhart barvinok_enumerate_e \
7                   barvinok_series remove_redundant_equalities \
8                   barvinok_union \
9                   @bv_extra_programs@
10 EXTRA_PROGRAMS = piptest verify_lexsmaller polyhedron_sample 4coins lexmin \
11                  polytope_scan
12 pkginclude_HEADERS = \
13     barvinok/NTL_QQ.h \
14     barvinok/barvinok.h \
15     barvinok/util.h \
16     barvinok/evalue.h \
17     barvinok/genfun.h \
18     barvinok/options.h
19 LINK = $(CXXLINK)
21 libbarvinok_la_SOURCES = \
22     barvinok/evalue.h \
23     barvinok/genfun.h \
24     barvinok/util.h \
25     barvinok/barvinok.h \
26     NTL_QQ.cc \
27     evalue.c \
28     genfun.cc \
29     util.c \
30     bfcounter.cc \
31     bfcounter.h \
32     conversion.cc \
33     conversion.h \
34     decomposer.cc \
35     decomposer.h \
36     dpoly.cc \
37     dpoly.h \
38     genfun_constructor.cc \
39     genfun_constructor.h \
40     lattice_point.cc \
41     lattice_point.h \
42     options.c \
43     reduce_domain.c \
44     reduce_domain.h \
45     reducer.cc \
46     reducer.h \
47     mat_util.cc \
48     mat_util.h \
49     barvinok.cc
50 EXTRA_libbarvinok_la_SOURCES = \
51     piputil.h
52 libbarvinok_la_LIBADD = @LTLIBOBJS@
53 libbarvinok_la_LDFLAGS = @BV_LDFLAGS@ -version-info @versioninfo@
54 LDADD = libbarvinok.la
56 test_SOURCES = test.c
57 barvinok_count_SOURCES = barvinok_count.c
58 barvinok_ehrhart_SOURCES = barvinok_ehrhart.cc
59 barvinok_series_SOURCES = barvinok_series.cc
60 barvinok_union_SOURCES = barvinok_union.cc
61 if HAVE_OMEGA
62 BEEO_SOURCES = omega/Exit.cc omega/convert.cc
63 else
64 BEEO_SOURCES = 
65 endif
66 barvinok_enumerate_e_SOURCES = \
67         barvinok_enumerate_e.cc \
68         scarf.cc \
69         $(BEEO_SOURCES)
70 barvinok_enumerate_e_CPPFLAGS = @OMEGA_CPPFLAGS@ @CPPFLAGS@
71 barvinok_enumerate_e_LDFLAGS = @OMEGA_LDFLAGS@ @LDFLAGS@
72 barvinok_enumerate_e_LDADD = @OMEGA_LIBS@ libbarvinok.la
73 verif_ehrhart_SOURCES = verif_ehrhart.c verify_main.cc verif_ehrhart.h
74 4coins_SOURCES = 4coins.cc scarf.cc
75 lexmin_SOURCES = lexmin.cc combine.c combine.h fdstream.cc fdstream.h
77 TESTFILES = $(shell find $(top_srcdir)/tests -type f ! -path '*CVS*')
79 EXTRA_DIST = \
80     README.Solaris \
81     ChangeLog \
82     $(TESTFILES) \
83     latte2polylib.pl \
84     NTL_5_3_2.patch \
85     doc/Internal.tex \
86     doc/Usage.tex \
87     doc/barvinok.bib \
88     doc/barvinok.gdf \
89     doc/barvinok.tex \
90     doc/chicago.bst \
91     doc/chicago.sty \
92     doc/mydefs.sty \
93     polymake/Makefile.in \
94     polymake/README \
95     polymake/autogen.sh \
96     polymake/configure.in \
97     polymake/lattice_points.cc
99 ACLOCAL_AMFLAGS = -I m4
101 install-data-local:
102         @test -z "$(pkgconfig_libdir)" || $(mkdir_p) "$(DESTDIR)$(pkgconfig_libdir)"
103         $(INSTALL_DATA) $(pkgconfig_libfile) "$(DESTDIR)$(pkgconfig_libdir)/$(pkgconfig_libfile)"
105 uninstall-local:
106         rm -f "$(DESTDIR)$(pkgconfig_libdir)/$(pkgconfig_libfile)"
108 dist-hook:
109         (cd $(distdir)/polymake; \
110             ./autogen.sh; rm -rf autogen.sh autom4te.cache)
111         (cd doc; make barvinok.pdf)
112         cp doc/barvinok.pdf $(distdir)/doc/
113         if test -f $(top_srcdir)/.git/HEAD; then \
114             echo @GIT_HEAD_VERSION@ > $(distdir)/GIT_HEAD_ID; \
115         else \
116             echo $(GIT_HEAD_ID) > $(distdir)/GIT_HEAD_ID; \
117         fi
119 if HAVE_PIPLIB
120 BEE_TESTDIRS = ehrhart_e ehrhart_e/piplib
121 else
122 BEE_TESTDIRS = ehrhart_e
123 endif
125 check-series:
126         @for i in $(top_srcdir)/tests/ehrhart/*; do \
127             if test -f $$i; then \
128                 echo $$i; \
129                 ./verif_ehrhart --series < $$i; \
130             fi \
131         done
132 check:
133         @for i in $(top_srcdir)/tests/ehrhart/*; do \
134             if test -f $$i; then \
135                 echo $$i; \
136                 ./verif_ehrhart < $$i; \
137             fi \
138         done
139         @for dir in $(BEE_TESTDIRS); do \
140             for options in '' '--pip' '--pip --omega'; do \
141                 for i in $(top_srcdir)/tests/$$dir/*; do \
142                     if test -f $$i; then \
143                         echo $$i $$options; \
144                         ./barvinok_enumerate_e --verify $$options < $$i; \
145                     fi \
146                 done \
147             done \
148         done
149         @for i in $(top_srcdir)/tests/*; do \
150             if test -f $$i; then \
151                 echo -n $$i; \
152                 ./test < $$i || echo -n " NOT"; \
153                 echo " ok"; \
154             fi \
155         done
156 if HAVE_GLPK
157         @for i in $(top_srcdir)/tests/lexmin/*; do \
158             if test -f $$i; then \
159                 echo $$i; \
160                 ./lexmin --verify < $$i; \
161             fi \
162         done
163 endif
165 version.h: @GIT_HEAD@
166         echo '#define GIT_HEAD_ID "'@GIT_HEAD_VERSION@'"' > $@