configure.in.in 4.12 KB
Newer Older
prudhomm's avatar
prudhomm committed
1
2
# -*- autoconf -*-
# 
prudhomm's avatar
prudhomm committed
3
#
prudhomm's avatar
prudhomm committed
4
AC_INIT([lifev], [0.6.99@CVSDATE@], [lifev-dev@webmail.mate.polimi.it])
prudhomm's avatar
prudhomm committed
5
#AC_INIT([lifev], [0.7.0], [lifev-dev@webmail.mate.polimi.it])
6

prudhomm's avatar
prudhomm committed
7
8
LIFEV_VERSION_MAJOR=0
LIFEV_VERSION_MINOR=6
prudhomm's avatar
prudhomm committed
9
LIFEV_VERSION_MICRO=99
prudhomm's avatar
prudhomm committed
10
11
12
13
14
15
16
17
18
LIFEV_VERSION_EXTRA=@CVSDATE@
AC_SUBST(LIFEV_VERSION_MAJOR)
AC_SUBST(LIFEV_VERSION_MINOR)
AC_SUBST(LIFEV_VERSION_MICRO)
AC_SUBST(LIFEV_VERSION_EXTRA)
AC_DEFINE_UNQUOTED(LIFEV_VERSION_MAJOR,$LIFEV_VERSION_MAJOR,[major version number])
AC_DEFINE_UNQUOTED(LIFEV_VERSION_MINOR,$LIFEV_VERSION_MINOR,[minor version number])
AC_DEFINE_UNQUOTED(LIFEV_VERSION_MICRO,$LIFEV_VERSION_MICRO,[micro version number])
AC_DEFINE_UNQUOTED(LIFEV_VERSION_EXTRA,$LIFEV_VERSION_EXTRA,[extra version information: date, cvs, ...])
19

20
LIFEV_PACKAGE=lifev
prudhomm's avatar
prudhomm committed
21
LIFEV_VERSION=${LIFEV_VERSION_MAJOR}.${LIFEV_VERSION_MINOR}.${LIFEV_VERSION_MICRO}${LIFEV_VERSION_EXTRA}
22

prudhomm's avatar
prudhomm committed
23
AC_DEFINE_UNQUOTED(LIFEV_VERSION_STRING,["${LIFEV_VERSION_MAJOR}.${LIFEV_VERSION_MINOR}.${LIFEV_VERSION_MICRO} (${LIFEV_VERSION_EXTRA})"],[LifeV version string])
24

prudhomm's avatar
prudhomm committed
25

26
27
28
29
30
PACKAGE=$LIFEV_PACKAGE
VERSION=$LIFEV_VERSION

AC_SUBST(LIFEV_PACKAGE)
AC_SUBST(LIFEV_VERSION)
prudhomm's avatar
prudhomm committed
31

prudhomm's avatar
prudhomm committed
32
33


prudhomm's avatar
prudhomm committed
34
35
36
37
38
39
40
AC_CONFIG_AUX_DIR(admin)

dnl What the current system and host
AC_CANONICAL_HOST
AC_CANONICAL_SYSTEM


41
AM_INIT_AUTOMAKE([foreign 1.7.8 dist-bzip2])
prudhomm's avatar
prudhomm committed
42
43
AM_CONFIG_HEADER(lifeconfig.h)

prudhomm's avatar
prudhomm committed
44
45
LIFEV_CHECK_COMPILERS

prudhomm's avatar
prudhomm committed
46
47
48

# no need for static libs 
AC_DISABLE_STATIC
prudhomm's avatar
prudhomm committed
49
50
AC_PROG_LIBTOOL

prudhomm's avatar
prudhomm committed
51
52
53
# pdflatex
AC_CHECK_PROG(PDFLATEX, pdflatex,[pdflatex],[no])

54
55
56
# doxygen
AC_CHECK_PROG(DOXYGEN, doxygen, [doxygen], [no-doxygen] )
AC_CHECK_PROG(LIFE_HAS_DOT, dot, [yes] )
prudhomm's avatar
prudhomm committed
57

prudhomm's avatar
prudhomm committed
58

59
AC_CHECK_BOOST
60
61
AC_CHECK_BOOST_GRAPH
AC_CHECK_BOOST_SIGNALS
prudhomm's avatar
prudhomm committed
62
AC_CHECK_BOOST_REGEX
63
AC_CHECK_BOOST_UNIT_TEST_FRAMEWORK
64

prudhomm's avatar
prudhomm committed
65
AC_CHECK_BOOST_PROGRAM_OPTIONS
prudhomm's avatar
prudhomm committed
66
AM_CONDITIONAL(HAVE_BOOST_PROGRAM_OPTIONS, test "x$boost_program_options_error" = "xno")
prudhomm's avatar
prudhomm committed
67

68

prudhomm's avatar
prudhomm committed
69

prudhomm's avatar
prudhomm committed
70
71
72
73
74
75
dnl
dnl checks for some scientific computing libraries
dnl 
dnl libm
AC_CHECK_LIB(m,cos,[LIBS="-lm ${LIBS}"],${LIBS})
dnl umfpack
76
77
# disable it for not since it is not used yet: need to check for "NO"
# AC_CHECK_UMFPACK(4.3.0) # at least umfpack 4.3
78
79
AM_CONDITIONAL(HAVE_UMFPACK, test "x$umfpack_libs" != "x" )

80
81
dnl lapack, blas, g2c
AC_CHECK_LAPACK
82
AC_CHECK_UMFPACK
83
AM_CONDITIONAL(HAVE_UMFPACK, test "x$umfpack_libs" != "x" )
84

prudhomm's avatar
prudhomm committed
85
86
87
88
dnl aztec
AC_CHECK_AZTEC
dnl petsc
AC_CHECK_PETSC(2.1.6) #
prudhomm's avatar
prudhomm committed
89
90
AM_CONDITIONAL(HAVE_PETSC, test "x$petsc_libs" != "x" )

prudhomm's avatar
prudhomm committed
91
92
dnl parmetis
AC_CHECK_PARMETIS
prudhomm's avatar
prudhomm committed
93

prudhomm's avatar
prudhomm committed
94
95
96
97
98
99
dnl grace 
AC_CHECK_HEADERS([grace_np.h])
AC_CHECK_LIB([grace_np],GraceClose,[grace_libs="-lgrace_np"],[grace_libs=""])
AC_SUBST(grace_libs)


prudhomm's avatar
prudhomm committed
100
101
#all_includes="-I\$(top_srcdir) -I\$(top_srcdir)/life/lifecore -I\$(top_srcdir)/life/lifearray  -I\$(top_srcdir)/life/lifemesh -I\$(top_srcdir)/life/lifealg  -I\$(top_srcdir)/life/lifefem -I\$(top_srcdir)/life/lifesolver -I\$(top_srcdir)/life/lifefilters"
#AC_SUBST(all_includes)
prudhomm's avatar
prudhomm committed
102

prudhomm's avatar
prudhomm committed
103
CPPFLAGS="-I\$(top_srcdir) ${CPPFLAGS}"
prudhomm's avatar
prudhomm committed
104

105
life_libs="\$(top_builddir)/life/lifefilters/liblifefilters.la \$(top_builddir)/life/lifesolver/liblifesolver.la  \$(top_builddir)/life/lifefem/liblifefem.la \$(top_builddir)/life/lifealg/liblifealg.la \$(top_builddir)/life/lifemesh/liblifemesh.la \$(top_builddir)/life/lifearray/liblifearray.la \$(top_builddir)/life/lifecore/liblifecore.la"
prudhomm's avatar
prudhomm committed
106

lformaggia's avatar
lformaggia committed
107
108
109
#life_libs="\$(top_builddir)/life/lifefilters/liblifefilters.la  \$(top_builddir)/life/lifesolver/liblifesolver.la \$(top_builddir)/life/lifefem/liblifefem.la \$(top_builddir)/life/lifealg/liblifealg.la \$(top_builddir)/life/lifemesh/liblifemesh.la \$(top_builddir)/life/lifearray/liblifearray.la \$(top_builddir)/life/lifecore/liblifecore.la"

#life_libs="\$(top_builddir)/life/lifefilters/liblifefilters.la  \$(top_builddir)/life/lifefem/liblifefem.la \$(top_builddir)/life/lifealg/liblifealg.la \$(top_builddir)/life/lifearray/liblifearray.la \$(top_builddir)/life/lifemesh/liblifemesh.la \$(top_builddir)/life/lifecore/liblifecore.la"
prudhomm's avatar
prudhomm committed
110
111

AC_SUBST(life_libs)
prudhomm's avatar
prudhomm committed
112
LIFEV_LIBS="-llifefilters -llifesolver -llifefem -llifealg -llifemesh -llifearray -llifecore"
prudhomm's avatar
prudhomm committed
113

prudhomm's avatar
prudhomm committed
114

115
116
117
118
119
120
121
#
# setting prefix
#  
prefix=${prefix:-"/usr"}
if test "x${prefix}" = "xNONE"; then
    prefix=/usr
fi
prudhomm's avatar
prudhomm committed
122
123
124
125


dnl testdir
AC_CONFIG_TESTDIR(testsuite)
prudhomm's avatar
prudhomm committed
126
127
128

dnl pkgconfig
AX_CREATE_PKGCONFIG_INFO(life.pc,,[${LIFEV_LIBS} $LIBS],[Finite Element Library and more],[$CPPFLAGS $CFLAGS])
129
130