Commit f430c71d authored by gsell's avatar gsell

configure.ac and related Makefile.am's:

- conditionally compile examples
parent 4a1d4d2d
ACLOCAL_AMFLAGS = -I m4
EXTRA_DIST = autogen.sh
SUBDIRS = \
src \
test \
tools \
doc
SUBDIRS = \
src \
test \
tools \
doc \
examples/H5 \
examples/H5Part \
examples/H5Block \
examples/H5Fed
MAINTAINERCLEANFILES = \
config.h \
config.log \
config.status \
stamp-h.in \
MAINTAINERCLEANFILES = \
config.h \
config.log \
config.status \
stamp-h.in \
stamp-h1
AC_INIT([H5hut], [1.99.14], [h5part@lists.psi.ch], H5hut)
AC_INIT([H5hut], [1.99.15], [h5part@lists.psi.ch], H5hut)
AC_PREREQ(2.60)
AC_CONFIG_HEADERS(config.h)
AC_CONFIG_MACRO_DIR([m4])
......@@ -58,6 +58,13 @@ AC_ARG_ENABLE(
[ENABLE_VTKCONVERTER=$enableval])
AM_CONDITIONAL([ENABLE_VTKCONVERTER], [test "$ENABLE_VTKCONVERTER" = "yes"])
AC_ARG_ENABLE(
[examples],
[AS_HELP_STRING([--enable-examples],
[Compile the H5hut examples [default=no]])],
[ENABLE_EXAMPLES=$enableval])
AM_CONDITIONAL([ENABLE_EXAMPLES], [test "$ENABLE_EXAMPLES" = "yes"])
AC_ARG_WITH(
[hdf5],
[AS_HELP_STRING([--with-hdf5],
......@@ -356,6 +363,15 @@ else
AC_MSG_RESULT([no])
fi
###############################################################################
# EXAMPLES
AC_MSG_CHECKING([if we have to compile the H5hut examples])
if test "X$ENABLE_EXAMPLES" = "Xyes"; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
fi
###############################################################################
# EXPORTING VARIABLES & CREATING OUTPUT FILES
AM_CPPFLAGS=$CPPFLAGS
......
......@@ -22,6 +22,7 @@ LDADD += -lH5hut
noinst_PROGRAMS =
if ENABLE_EXAMPLES
if ENABLE_C
noinst_PROGRAMS += \
attach_file \
......@@ -49,6 +50,7 @@ read_step_attribsf_SOURCES = read_step_attribsf.f90
write_file_attribsf_SOURCES = write_file_attribsf.f90
write_step_attribsf_SOURCES = write_step_attribsf.f90
endif
endif
%.o : %.f90
$(FC) $(FFLAGS) -c $<
......@@ -13,6 +13,7 @@ AM_LDFLAGS += -L${abs_top_builddir}/src/h5core/.libs
LDADD =
if ENABLE_EXAMPLES
if ENABLE_FORTRAN
LDADD += -lH5hutF
AM_LDFLAGS += -L${abs_top_builddir}/src/Fortran/.libs
......@@ -36,6 +37,8 @@ fields_SOURCES = fields.c
read_write_scalar_field_SOURCES = read_write_scalar_field.c
read_write_scalar_fieldf_SOURCES = read_write_scalar_fieldf.f90
endif
%.o : %.f90
$(FC) $(FFLAGS) -c $<
......
......@@ -10,6 +10,8 @@ endif
LDADD += -lH5hut
if ENABLE_EXAMPLES
if ENABLE_EXPERIMENTAL
noinst_PROGRAMS = \
tetmesh_write \
tetmesh_write1 \
......@@ -41,7 +43,8 @@ EXTRA_DIST = \
trimesh_write.c \
trimesh_2gnuplot.c \
trimesh_write_dunetest.c
endif
endif
# map_tet2globalid.c \
# map_triangle2globalid.c \
# $(bin_SCRIPTS)
......
......@@ -13,6 +13,7 @@ AM_LDFLAGS += -L${abs_top_builddir}/src/h5core/.libs
LDADD =
if ENABLE_EXAMPLES
if ENABLE_C
LDADD +=
endif
......@@ -28,6 +29,7 @@ noinst_PROGRAMS =
if ENABLE_C
noinst_PROGRAMS += \
read_core_vfd \
read_canonicalview \
read_setnparticles \
read_setview \
......@@ -40,6 +42,7 @@ endif
if ENABLE_FORTRAN
noinst_PROGRAMS += \
read_core_vfdf \
read_canonicalviewf \
read_setnparticlesf \
read_setviewf \
......@@ -52,6 +55,7 @@ endif
EXTRA_PROGRAMS =
read_core_vfdf_SOURCES = read_core_vfdf.f90
read_canonicalviewf_SOURCES = read_canonicalviewf.f90
read_setnparticlesf_SOURCES = read_setnparticlesf.f90
read_setviewf_SOURCES = read_setviewf.f90
......@@ -61,6 +65,8 @@ write_setnparticlesf_SOURCES = write_setnparticlesf.f90
write_setviewf_SOURCES = write_setviewf.f90
write_stridedf_SOURCES = write_stridedf.f90
endif
%.o : %.f90
$(FC) $(FFLAGS) -c $<
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment