Get rid of the warning about ignoring the return value of fgets
[cloog.git] / Makefile.am
blobf968b2e68e9b45d087f22bb66e5382678fac070b
2 #   /**-------------------------------------------------------------------**
3 #    **                              CLooG                                **
4 #    **-------------------------------------------------------------------**
5 #    **                           makefile.in                             **
6 #    **-------------------------------------------------------------------**
7 #    **                   First version: october 25th 2001                **
8 #    **-------------------------------------------------------------------**/
10 # makefile.in (or makefile if generated) of CLooG, the Chunky LOOp Generator.
11 # makefile.in is not a makefile, you must run the 'configure' shellscript to
12 # generate the makefile thanks to this file.
14 #/*****************************************************************************
15 # *               CLooG : the Chunky Loop Generator (experimental)            *
16 # *****************************************************************************
17 # *                                                                           *
18 # * Copyright (C) 2001 Cedric Bastoul                                         *
19 # *                                                                           *
20 # * This library is free software; you can redistribute it and/or             *
21 # * modify it under the terms of the GNU Lesser General Public                *
22 # * License as published by the Free Software Foundation; either              *
23 # * version 2.1 of the License, or (at your option) any later version.        *
24 # *                                                                           *
25 # * This library is distributed in the hope that it will be useful,           *
26 # * but WITHOUT ANY WARRANTY; without even the implied warranty of            *
27 # * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU         *
28 # * Lesser General Public License for more details.                           *
29 # *                                                                           *
30 # * You should have received a copy of the GNU Lesser General Public          *
31 # * License along with this library; if not, write to the Free Software       *
32 # * Foundation, Inc., 51 Franklin Street, Fifth Floor,                        *
33 # * Boston, MA  02110-1301  USA                                               *
34 # *                                                                           *
35 # * CLooG, the Chunky Loop Generator                                          *
36 # * Written by Cedric Bastoul, Cedric.Bastoul@inria.fr                        *
37 # *                                                                           *
38 # *****************************************************************************/
39 if BUNDLED_ISL
40     MAYBE_ISL = isl
41     ISL_LA = $(top_builddir)/isl/libisl.la
42 endif
44 if BUNDLED_OSL
45     MAYBE_OSL = osl
46     OSL_LA = $(top_builddir)/osl/libosl.la
47 endif
49 AUTOMAKE_OPTIONS = subdir-objects
50 SUBDIRS = $(MAYBE_ISL) $(MAYBE_OSL) . doc test
51 DIST_SUBDIRS = $(MAYBE_ISL) $(MAYBE_OSL) . doc test
53 ACLOCAL_AMFLAGS = -I m4
55 FORCE:
56 isl/libisl.la: FORCE
57         cd isl; $(MAKE) $(AM_MAKEFLAGS) libisl.la
59 if NO_ISL
60 CLOOG =
61 LIBCLOOG =
62 else
63 CLOOG = cloog
64 LIBCLOOG = libcloog-isl.la
65 endif
66 bin_PROGRAMS = $(CLOOG)
67 lib_LTLIBRARIES = $(LIBCLOOG)
69 if NEED_GET_MEMORY_FUNCTIONS
70 GET_MEMORY_FUNCTIONS=source/mp_get_memory_functions.c
71 endif
73 SOURCES_CORE = \
74         $(GET_MEMORY_FUNCTIONS) \
75         source/block.c \
76         source/clast.c \
77         source/matrix.c \
78         source/state.c \
79         source/input.c \
80         source/int.c \
81         source/loop.c \
82         source/names.c \
83         source/options.c \
84         source/pprint.c \
85         source/program.c \
86         source/statement.c \
87         source/stride.c \
88         source/union_domain.c \
89         source/util.c \
90         source/version.c
92 AM_CPPFLAGS = -I. -I$(top_builddir)/include -I$(top_srcdir)/include
93 AM_CFLAGS = $(CFLAGS_WARN)
94 libcloog_isl_la_CPPFLAGS = -I. -I$(top_builddir)/include -I$(top_srcdir)/include @ISL_CPPFLAGS@ @OSL_CPPFLAGS@
95 libcloog_isl_la_LDFLAGS = -version-info @versioninfo@ \
96         -rpath $(libdir) @ISL_LDFLAGS@ @OSL_LDFLAGS@
97 libcloog_isl_la_LIBADD = @ISL_LIBS@ @OSL_LIBS@ $(ISL_LA) $(OSL_LA)
98 libcloog_isl_la_SOURCES = \
99         $(SOURCES_CORE) \
100         source/isl/domain.c \
101         source/isl/constraints.c \
102         source/isl/backend.c
103 LDADD = libcloog-isl.la
104 cloog_DEPENDENCIES = libcloog-isl.la
105 cloog_SOURCES = source/cloog.c
107 pkginclude_HEADERS = \
108         include/cloog/block.h \
109         include/cloog/clast.h \
110         include/cloog/cloog.h \
111         include/cloog/input.h \
112         include/cloog/int.h \
113         include/cloog/matrix.h \
114         include/cloog/state.h \
115         include/cloog/domain.h \
116         include/cloog/loop.h \
117         include/cloog/constraints.h \
118         include/cloog/names.h \
119         include/cloog/options.h \
120         include/cloog/pprint.h \
121         include/cloog/program.h \
122         include/cloog/statement.h \
123         include/cloog/stride.h \
124         include/cloog/union_domain.h \
125         include/cloog/util.h \
126         include/cloog/version.h
128 pkgmatrixincludedir = $(pkgincludedir)/matrix
129 pkgmatrixinclude_HEADERS = \
130         include/cloog/matrix/constraintset.h
132 pkgislincludedir = $(pkgincludedir)/isl
133 pkgislinclude_HEADERS = \
134         include/cloog/isl/backend.h \
135         include/cloog/isl/cloog.h \
136         include/cloog/isl/domain.h \
137         include/cloog/isl/constraintset.h
139 version.h: @GIT_INDEX@
140         echo '#define CLOOG_HEAD "'`$(top_builddir)/genversion.sh`'"' > $@
142 EXTRA_DIST = \
143         autoconf/Doxyfile.in \
144         source/matrix/constraintset.c \
145         cmake \
146         doc/cloog.texi \
147         doc/images \
148         examples
150 install-data-local:
151         @test -z "$(pkgconfig_libdir)" || $(mkdir_p) "$(DESTDIR)$(pkgconfig_libdir)"
152         $(INSTALL_DATA) $(pkgconfig_libfile) "$(DESTDIR)$(pkgconfig_libdir)/$(pkgconfig_libfile)"
153         @test -z "$(DESTDIR)$(libdir)/isl" || $(mkdir_p) "$(DESTDIR)$(libdir)/isl"
154         $(INSTALL_DATA) "$(top_srcdir)/cmake/isl-config.cmake" "$(DESTDIR)$(libdir)/isl/"
155         @test -z "$(DESTDIR)$(libdir)/$(PACKAGE_NAME)" || $(mkdir_p) "$(DESTDIR)$(libdir)/$(PACKAGE_NAME)"
156         $(INSTALL_DATA) "$(top_srcdir)/cmake/cloog-isl-config.cmake" "$(DESTDIR)$(libdir)/$(PACKAGE_NAME)/"
158 uninstall-local:
159         rm -f "$(DESTDIR)$(pkgconfig_libdir)/$(pkgconfig_libfile)"
160         rm -f "$(DESTDIR)$(libdir)/isl/isl-config.cmake"
161         rm -f "$(DESTDIR)$(libdir)/$(PACKAGE_NAME)/cloog-isl-config.cmake"
163 dist-hook:
164         rm -f $(distdir)/test/Makefile
165         $(top_builddir)/genversion.sh > $(distdir)/CLOOG_HEAD
166         (cd doc; make cloog.pdf) && cp doc/cloog.pdf $(distdir)/doc/
168 #/*****************************************************************************
169 # *                                   Rules                                   *
170 # *****************************************************************************/
172 valcheck:
173         $(MAKE) test_valgrind -C test
175 total:
176         @echo "             /*-----------------------------------------------*"
177         @echo "              *                     CLooG                     *"
178         @echo "              *-----------------------------------------------*/"
179         $(MAKE) uninstall
180         $(MAKE) clean
181         $(MAKE)
182         $(MAKE) install
184 doc:
185         @echo "             /*-----------------------------------------------*"
186         @echo "              *        Generating CLooG's documentation       *"
187         @echo "              *-----------------------------------------------*/"
188         doxygen ./autoconf/Doxyfile