summaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/apple30
-rw-r--r--config/examples.am24
-rw-r--r--config/linux-gnulibc190
-rw-r--r--config/solaris2.x40
4 files changed, 181 insertions, 3 deletions
diff --git a/config/apple b/config/apple
index 8c4cc8e..10674fb 100644
--- a/config/apple
+++ b/config/apple
@@ -55,3 +55,33 @@ if test "X-" != "X-$enable_fortran"; then
enable_shared="no"
fi
+# compiler version strings
+case $CC in
+ *gcc*)
+ cc_version_info=`$CC $CFLAGS $H5_CFLAGS --version 2>&1 | grep -v 'PathScale' |\
+ grep 'GCC' | sed 's/.*\((GCC) [-a-z0-9\. ]*.*\)/\1/'`
+ ;;
+
+ *)
+ echo "No match to get cc_version_info for $CC"
+ ;;
+esac
+
+case $FC in
+ *gfortran*)
+ fc_version_info=`$FC $FCFLAGS $H5_FCFLAGS --version 2>&1 |\
+ grep 'GCC' | sed 's/\(.*(GCC) [-a-z0-9\. ]*\).*/\1/'`
+ ;;
+esac
+
+# get c++ version info
+case $CXX in
+ *g++*)
+ cxx_version_info=`$CXX $CXXFLAGS $H5_CXXFLAGS --version 2>&1 |\
+ grep 'GCC' | sed 's/.*\((GCC) [-a-z0-9\. ]*.*\)/\1/'`
+ ;;
+ *)
+ echo "No match to get cxx_version_info for $CXX"
+ ;;
+esac
+
diff --git a/config/examples.am b/config/examples.am
index 28bd447..30ea717 100644
--- a/config/examples.am
+++ b/config/examples.am
@@ -30,6 +30,8 @@
##
## INSTALL_FILES
## The source files that the examples use which should be installed.
+## INSTALL_SCRIPT_FILES
+## INSTALL_TOP_SCRIPT_FILES
##
## EXAMPLEDIR
## The directory into which examples should be installed.
@@ -52,6 +54,8 @@ CLEANFILES=$(TEST_PROG) $(TEST_PROG_PARA)
# How to create EXAMPLEDIR if it doesn't already exist
$(EXAMPLEDIR):
-$(top_srcdir)/bin/mkdirs $@
+$(EXAMPLETOPDIR):
+ -$(top_srcdir)/bin/mkdirs $@
# Install and uninstall rules. We install the source files, not the
# example programs themselves.
@@ -66,10 +70,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES)
(set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\
fi; \
done
+ @for f in X $(INSTALL_SCRIPT_FILES); do \
+ if test $$f != X; then \
+ (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\
+ fi; \
+ done
+ @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \
+ if test $$f != X; then \
+ (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \
+ fi; \
+ done
uninstall-examples:
- @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \
- set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \
+ @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \
+ set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \
+ fi
+ @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \
+ set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \
+ fi
+ @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \
+ set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \
fi
installcheck-local:
diff --git a/config/linux-gnulibc1 b/config/linux-gnulibc1
index 667f04e..26a0c3a 100644
--- a/config/linux-gnulibc1
+++ b/config/linux-gnulibc1
@@ -35,6 +35,7 @@ fi
# Figure out Intel C compiler flags
. $srcdir/config/intel-flags
+echo "CC_BASENAME is $CC_BASENAME."
# Use default Fortran 90 compiler according to what C compiler is used.
if test "X-" = "X-$FC"; then
case $CC_BASENAME in
@@ -61,7 +62,7 @@ else
ifc*|ifort*|pgf90*)
;;
- *)
+ *f95*)
# Figure out which compiler we are using: pgf90 or Absoft f95
RM='rm -f'
tmpfile=/tmp/cmpver.$$
@@ -75,6 +76,10 @@ else
fi
fi
$RM $tmpfile
+ fc_version_info=`$FC -V | grep Absoft`
+ ;;
+
+ *)
;;
esac
fi
@@ -131,3 +136,86 @@ fi
hdf5_cv_mpi_special_collective_io_works=${hdf5_cv_mpi_special_collective_io_works='no'}
hdf5_cv_mpi_complex_derived_datatype_works=${hdf5_cv_mpi_complex_derived_datatype_works='no'}
+# compiler version strings
+case $CC in
+ # whatever matches *pgcc* will also match *gcc*, so this one must come first
+ *pgcc*)
+ cc_version_info=`$CC $CFLAGS $H5_CFLAGS -V 2>&1 | grep 'pgcc'`
+ ;;
+
+ *gcc*)
+ cc_version_info=`$CC $CFLAGS $H5_CFLAGS --version 2>&1 | grep -v 'PathScale' |\
+ grep 'GCC' | sed 's/\(.*(GCC) [-a-z0-9\. ]*\).*/\1/'`
+ ;;
+
+ *icc*)
+ cc_version_info=`$CC $CCFLAGS $H5_CCFLAGS -V 2>&1 | grep 'Version' |\
+ sed 's/\(Intel.* Compiler\).*\( Version [a-z0-9\.]*\).*\( Build [0-9]*\)/\1\2\3/'`
+ ;;
+
+ *)
+ echo "No match to get cc_version_info for $CC"
+ ;;
+esac
+
+# get fortran version info
+case $FC in
+ *gfortran*)
+ fc_version_info=`$FC $FCFLAGS $H5_FCFLAGS --version 2>&1 |\
+ grep 'GCC' | sed 's/\(.*(GCC) [-a-z0-9\. ]*\).*/\1/'`
+ ;;
+
+ *ifc*|*ifort*)
+ fc_version_info=`$FC $FCFLAGS $H5_FCFLAGS -V 2>&1 | grep 'Version' |\
+ sed 's/\(Intel.* Compiler\).*\( Version [a-z0-9\.]*\).*\( Build [0-9]*\)/\1\2\3/'`
+ ;;
+
+ *f95*)
+ # Figure out which compiler we are using: pgf90 or Absoft f95
+ RM='rm -f'
+ tmpfile=/tmp/cmpver.$$
+ $FC -V >$tmpfile
+ if test -s "$tmpfile"; then
+ if( grep -s 'Absoft' $tmpfile > /dev/null) then
+ FC_BASENAME=f95
+ fi
+ fi
+ $RM $tmpfile
+ fc_version_info=`$FC -V | grep Absoft`
+ ;;
+
+ *g95*)
+ fc_version_info=`$FC $FCFLAGS $H5_FCFLAGS --version 2>&1 |\
+ grep 'GCC'`
+ ;;
+
+ *pgf90*)
+ fc_version_info=`$FC $FCFLAGS $H5_FCFLAGS -V 2>&1 | grep 'pgf90'`
+ ;;
+
+ *)
+ echo "No match to get fc_version_info for $FC"
+ ;;
+esac
+
+
+# get c++ version info
+case $CXX in
+ *g++*)
+ cxx_version_info=`$CXX $CXXFLAGS $H5_CXXFLAGS --version 2>&1 |\
+ grep 'GCC' | sed 's/\(.*(GCC) [-a-z0-9\. ]*\).*/\1/'`
+ ;;
+ *icpc*)
+ cxx_version_info=`$CXX $CXXFLAGS $H5_CXXFLAGS -V 2>&1 | grep 'Version' |\
+ sed 's/\(Intel.* Compiler\).*\( Version [a-z0-9\.]*\).*\( Build [0-9]*\)/\1\2\3/'`
+ ;;
+ *pgCC*)
+ cxx_version_info=`$CXX $CXXFLAGS $H5_CXXFLAGS -V 2>&1 | grep 'pgCC'`
+ ;;
+
+
+ *)
+ echo "No match to get cxx_version_info for $CXX"
+ ;;
+esac
+
diff --git a/config/solaris2.x b/config/solaris2.x
index 5ef6415..cea71bd 100644
--- a/config/solaris2.x
+++ b/config/solaris2.x
@@ -111,3 +111,43 @@ if test -z "$cxx_flags_set"; then
PROFILE_CPPFLAGS=
cxx_flags_set=yes
fi
+
+# compiler version strings
+case $CC in
+ *cc*)
+ cc_version_info=`$CC $CFLAGS $H5_CFLAGS -V 2>&1 | grep 'Sun' |\
+ sed 's/.*\(Sun.*\)/\1 /'`
+ ;;
+
+ *)
+ echo "No match to get cc_version_info for $CC"
+ ;;
+esac
+echo "C compiler '$CC' is $cc_version_info"
+
+case $FC in
+ # The PGI and Intel compilers are automatically detected below
+ *f90*)
+ fc_version_info=`$FC $FCFLAGS $H5_FCFLAGS -V 2>&1 | grep 'Sun' |\
+ sed 's/.*\(Sun.*\)/\1 /'`
+ ;;
+
+ *)
+ echo "No match to get fc_version_info for $FC"
+ ;;
+esac
+echo "Fortran compiler '$FC' is $fc_version_info"
+
+# get c++ version info
+case $CXX in
+ *CC*)
+ cxx_version_info=`$CXX $CXXFLAGS $H5_CXXFLAGS -V 2>&1 | grep 'Sun' |\
+ sed 's/.*\(Sun.*\)/\1 /'`
+ ;;
+
+ *)
+ echo "No match to get cxx_version_info for $CXX"
+ ;;
+esac
+
+