forked from ForestClaw/forestclaw
-
Notifications
You must be signed in to change notification settings - Fork 0
/
configure.ac
121 lines (99 loc) · 3.93 KB
/
configure.ac
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
dnl
dnl This file is part of ForestClaw.
dnl
dnl TODO: We need a forwarding email for both Donna and Carsten.
AC_INIT([ForestClaw],
[m4_esyscmd([build-aux/git-version-gen .tarball-version])],
AC_PREREQ(2.61)
AC_CONFIG_HEADERS([src/pre_config.h])
AC_CONFIG_SRCDIR([src/fclaw_base.h])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_MACRO_DIR([config])
AC_PREFIX_DEFAULT([$PWD/local])
AX_PREFIX_CONFIG_H([src/fclaw_config.h], [FCLAW])
AM_INIT_AUTOMAKE([parallel-tests subdir-objects])
AM_SILENT_RULES
SC_VERSION([FCLAW])
echo "o---------------------------------------"
echo "| Checking options"
echo "o---------------------------------------"
FCLAW_ARG_ENABLE([debug], [Enable debug mode (assertions and extra checks)],
[DEBUG])
FCLAW_ARG_ENABLE([geoclaw], [Enable geoclaw library and applications],
[GEOCLAW])
FCLAW_ARG_ENABLE([geoclaw_development], [Enable Geoclaw applications under development],
[GEOCLAW_DEVELOPMENT])
FCLAW_ARG_ENABLE([ash3d], [enable ash3d library and applications],
[ASH3D])
FCLAW_ARG_ENABLE([clawpack], [Enable clawpack libraries 4.6 and 5.0 and applications],
[CLAWPACK])
FCLAW_ARG_ENABLE([development], [Enable general applications under development],
[DEVELOPMENT])
echo "o---------------------------------------"
echo "| Checking MPI and related programs"
echo "o---------------------------------------"
SC_MPI_CONFIG([FCLAW], [yes], [yes])
SC_MPI_ENGAGE([FCLAW])
# This is needed for compatibility with automake >= 1.12
m4_ifdef([AM_PROG_AR],[AM_PROG_AR])
SC_PROG_LINT
LT_INIT
echo "o---------------------------------------"
echo "| Checking libraries"
echo "o---------------------------------------"
SC_CHECK_LIBRARIES([FCLAW])
P4EST_CHECK_LIBRARIES([FCLAW])
FCLAW_CHECK_LIBRARIES([FCLAW])
echo "o---------------------------------------"
echo "| Checking headers"
echo "o---------------------------------------"s
AC_CHECK_HEADERS([fenv.h signal.h])
echo "o---------------------------------------"
echo "| Checking functions"
echo "o---------------------------------------"
AC_CHECK_FUNCS([feenableexcept])
echo "o---------------------------------------"
echo "| Checking subpackages"
echo "o---------------------------------------"
FCLAW_DIST_DENY=
FCLAW_DISTCLEAN=
SC_AS_SUBPACKAGE([FCLAW])
export P4EST_SC_SOURCE=../sc
P4EST_AS_SUBPACKAGE([FCLAW])
AM_CONDITIONAL([FCLAW_DIST_DENY], [test "x$FCLAW_DIST_DENY" != x])
AC_SUBST([FCLAW_DISTCLEAN])
# Print summary.
AC_DEFINE_UNQUOTED(CPP, ["${CPP}"], [C preprocessor])
AC_DEFINE_UNQUOTED(CPPFLAGS, ["${CPPFLAGS}"], [C preprocessor flags])
AC_DEFINE_UNQUOTED(F77, ["${F77}"], [F77 compiler])
AC_DEFINE_UNQUOTED(FFLAGS, ["${FFLAGS}"], [F77 compiler flags])
AC_DEFINE_UNQUOTED(CC, ["${CC}"], [C compiler])
AC_DEFINE_UNQUOTED(CFLAGS, ["${CFLAGS}"], [C compiler flags])
AC_DEFINE_UNQUOTED(CXX, ["${CXX}"], [C++ compiler])
AC_DEFINE_UNQUOTED(CXXFLAGS, ["${CXXFLAGS}"], [C++ compiler flags])
AC_DEFINE_UNQUOTED(LDFLAGS, ["${LDFLAGS}"], [Linker flags])
AC_DEFINE_UNQUOTED(LIBS, ["${LIBS}"], [Libraries])
AC_DEFINE_UNQUOTED(FLIBS, ["${FLIBS}"], [Fortran libraries])
echo "o----------------------------------"
echo "| Results for ForestClaw are"
echo "o----------------------------------"
echo "| CPP: $CPP"
echo "| CPPFLAGS: $CPPFLAGS"
echo "| F77: $F77"
echo "| FFLAGS: $FFLAGS"
echo "| CC: $CC"
echo "| CFLAGS: $CFLAGS"
echo "| CXX: $CXX"
echo "| CXXFLAGS: $CXXFLAGS"
echo "| LDFLAGS: $LDFLAGS"
echo "| LIBS: $LIBS"
echo "| FLIBS: $FLIBS"
echo "o----------------------------------"
# Create output files.
AC_CONFIG_FILES([Makefile Makefile.fclaw.pre Doxyfile])
AC_OUTPUT
# Final messages.
SC_FINAL_MESSAGES([FCLAW])
P4EST_FINAL_MESSAGES([FCLAW])
FCLAW_FINAL_MESSAGES([FCLAW])