diff options
author | Dana Robinson <derobins@hdfgroup.org> | 2017-08-01 11:12:03 (GMT) |
---|---|---|
committer | Dana Robinson <derobins@hdfgroup.org> | 2017-08-01 11:12:03 (GMT) |
commit | fd0d8738e07c602c1871a5052b4fe836c37b8d64 (patch) | |
tree | e4bbe74c8732b589e92085af502a990cf7316d8c /configure.ac | |
parent | 274f71be174c431be6e94b1d4f4c100ff090e749 (diff) | |
parent | 823f6a133302f1d6ba904020ad092723d2657d02 (diff) | |
download | hdf5-fd0d8738e07c602c1871a5052b4fe836c37b8d64.zip hdf5-fd0d8738e07c602c1871a5052b4fe836c37b8d64.tar.gz hdf5-fd0d8738e07c602c1871a5052b4fe836c37b8d64.tar.bz2 |
Merge branch 'develop' into h5pl_commit
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 40 |
1 files changed, 37 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index 163f6d3..47f5897 100644 --- a/configure.ac +++ b/configure.ac @@ -3338,6 +3338,28 @@ else STATIC_SHARED="none" fi +if test "X$HDF_FORTRAN" = "Xyes"; then + + ### libtool does not pass the correct argument linking (-WL,-WL,,) for the NAG Fortran compiler + ### on Linux (other OSs have not been tested). + ### Therefore, detect if we are using the NAG Fortran compiler, and replace the wl="-Wl," for Fortran to + ### wl="-Wl,-WL,," in the libtool file. (HDFFV-10037) + case "`uname`" in + Linux*) + + fortran_linux_linker_option="-Wl," + + if (grep -i 'NAG_Fortran' libtool > /dev/null); then + fortran_linux_linker_option="-Wl,-Wl,," + fi + + ## Set the correct linker option for use in h5fc.in markup + AC_SUBST([fortran_linux_linker_option]) + ;; + esac + +fi + ## ---------------------------------------------------------------------- ## Set a macro if shared library is enabled. ## @@ -3473,6 +3495,10 @@ AC_CONFIG_COMMANDS([.classes], [], [$MKDIR_P java/src/.classes; AC_OUTPUT chmod 755 tools/src/misc/h5cc +if test "X$HDF_CXX" = "Xyes"; then + chmod 755 c++/src/h5c++ +fi + if test "X$HDF_FORTRAN" = "Xyes"; then chmod 755 fortran/src/h5fc @@ -3484,10 +3510,18 @@ if test "X$HDF_FORTRAN" = "Xyes"; then cat libtool | awk '/wl=\"/{c++;if(c==3){sub("wl=\"\"","wl=\"-Wl,\"");c=0}}1' > libtool.tmp && mv -f libtool.tmp libtool && chmod 755 libtool ;; esac -fi -if test "X$HDF_CXX" = "Xyes"; then - chmod 755 c++/src/h5c++ + ### libtool does not pass the correct argument linking (-WL,-WL,,) for the NAG Fortran compiler + ### on Linux (other OSs have not been tested). + ### Therefore, detect if we are using the NAG Fortran compiler, and replace the wl="-Wl," for Fortran to + ### wl="-Wl,-WL,," in the libtool file. (HDFFV-10037) + case "`uname`" in + Linux*) + if (grep -i 'NAG_Fortran' libtool > /dev/null); then + cat libtool | awk '/NAG_Fortran/{flag=1}flag&&/wl=/{$NF="wl=\"-Wl,Wl,,\"";flag=0}1' > libtool.tmp && mv -f libtool.tmp libtool && chmod 755 libtool + fi + ;; + esac fi ## HDF5 configure code created by autotools with gcc 4.9.2 is adding problematic |