annotate src/configure.ac @ 230:1a3674836579

Provide flags for just-in-time compilation * src/configure.ac: add inst/private/get_vars.m as configured file * inst/private/get_vars.m.in: a function returning proper compiler or linker flags * inst/provate/generate_makefile.m: use flags * src/Makefile.in: add get_vars.m in the cleanall recipe
author Eugenio Gianniti <eugenio.gianniti@mail.polimi.it>
date Fri, 13 Jun 2014 18:45:40 +0200
parents 194f8c66b45a
children e348b84ecb70
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
1 AC_PREREQ([2.67])
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
2 AC_INIT([Fem-fenics Package], [0.0.1])
5
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
3
210
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
4 AC_USE_SYSTEM_EXTENSIONS
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
5
5
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
6 AC_PROG_CXX
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
7 AC_LANG(C++)
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
8
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
9 PKG_PROG_PKG_CONFIG
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
10
210
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
11 # Get Dense include locations
211
5b2a3d09f524 maint: changing configure.ac option to ---with-eigen-includedir
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 210
diff changeset
12 AC_ARG_WITH([eigen-includedir],
5b2a3d09f524 maint: changing configure.ac option to ---with-eigen-includedir
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 210
diff changeset
13 [AS_HELP_STRING([--with-eigen-includedir=DIR],
5b2a3d09f524 maint: changing configure.ac option to ---with-eigen-includedir
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 210
diff changeset
14 [location of the Eigen headers, defaults to /usr/include/])],
210
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
15 [DENSE_CPPFLAGS="-I$withval"],
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
16 [DENSE_CPPFLAGS='-I/usr/include/'])
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
17 AC_SUBST(DENSE_CPPFLAGS)
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
18 echo $DENSE_CPPFLAGS
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
19
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
20 ## Check for Eigen
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
21 AC_MSG_CHECKING([for eigen3])
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
22
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
23 EIGEN_CPPFLAGS=
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
24 EIGEN_LIBS=
210
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
25
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
26 PKG_CHECK_EXISTS([eigen3],
229
194f8c66b45a Add unused compiler/linker flags
Eugenio Gianniti <eugenio.gianniti@mail.polimi.it>
parents: 217
diff changeset
27 [EIGEN_CPPFLAGS=`$PKG_CONFIG --cflags eigen3`
194f8c66b45a Add unused compiler/linker flags
Eugenio Gianniti <eugenio.gianniti@mail.polimi.it>
parents: 217
diff changeset
28 EIGEN_LIBS=`$PKG_CONFIG --libs eigen3`
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
29 AC_MSG_RESULT([yes])],
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
30 [AC_MSG_RESULT([no])
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
31 AC_MSG_ERROR([eigen3 required to install $PACKAGE_NAME])]
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
32 )
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
33
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
34 AC_SUBST(EIGEN_CPPFLAGS)
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
35 AC_SUBST(EIGEN_LIBS)
210
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
36
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
37 ## Check for dolfin
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
38 AC_MSG_CHECKING([for dolfin])
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
39
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
40 DOLFIN_CPPFLAGS=
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
41 DOLFIN_LIBS=
210
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
42
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
43 PKG_CHECK_EXISTS([dolfin],
229
194f8c66b45a Add unused compiler/linker flags
Eugenio Gianniti <eugenio.gianniti@mail.polimi.it>
parents: 217
diff changeset
44 [DOLFIN_CPPFLAGS=`$PKG_CONFIG --cflags dolfin`
194f8c66b45a Add unused compiler/linker flags
Eugenio Gianniti <eugenio.gianniti@mail.polimi.it>
parents: 217
diff changeset
45 DOLFIN_LIBS=`$PKG_CONFIG --libs dolfin`
217
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
46 AC_MSG_RESULT([yes])],
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
47 [AC_MSG_RESULT([no])
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
48 AC_MSG_ERROR([dolfin required to install $PACKAGE_NAME])]
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
49 )
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
50
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
51 AC_SUBST(DOLFIN_CPPFLAGS)
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
52 AC_SUBST(DOLFIN_LIBS)
5292e0614efc New patches submitted from eg123 for the automatization of
gedeone-octave <marcovass89@hotmail.it>
parents: 211
diff changeset
53
210
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
54
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
55 AC_CHECK_PROG([HAVE_FFC], [ffc], [yes], [no])
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
56 if [test $HAVE_FFC = "no"]; then
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
57 AC_MSG_ERROR([ffc required to install $PACKAGE_NAME])
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
58 fi
b9999ff4fe5e maint: configure.ac accpets includedir for Dense.
Juan Pablo Carbajal <ajuanpi+dev@gmail.com>
parents: 27
diff changeset
59
5
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
60 AC_CHECK_PROG([HAVE_MKOCTFILE], [mkoctfile], [yes], [no])
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
61 if [test $HAVE_MKOCTFILE = "no"]; then
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
62 AC_MSG_ERROR([mkoctfile required to install $PACKAGE_NAME])
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
63 fi
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
64
230
1a3674836579 Provide flags for just-in-time compilation
Eugenio Gianniti <eugenio.gianniti@mail.polimi.it>
parents: 229
diff changeset
65 AC_CONFIG_FILES([Makefile ../inst/private/get_vars.m])
5
e74ff416fd54 File for the configuration and compilation of the pkg
gedeone-octave <marco.vassallo@outlook.com>
parents:
diff changeset
66 AC_OUTPUT