summaryrefslogtreecommitdiffstats
path: root/fortran/src/h5fc.in
diff options
context:
space:
mode:
authorLarry Knox <lrknox@hdfgroup.org>2010-09-20 22:07:27 (GMT)
committerLarry Knox <lrknox@hdfgroup.org>2010-09-20 22:07:27 (GMT)
commita779518cf92213c96cb06ba16b744d4b95d76c1c (patch)
treeda197cc7e5c736b6f7d479f32ef62ee4f4a7e9ce /fortran/src/h5fc.in
parentd688fc55a94acc6bdf43607e5224bc28009ee5e8 (diff)
downloadhdf5-a779518cf92213c96cb06ba16b744d4b95d76c1c.zip
hdf5-a779518cf92213c96cb06ba16b744d4b95d76c1c.tar.gz
hdf5-a779518cf92213c96cb06ba16b744d4b95d76c1c.tar.bz2
[svn-r19442] Move $LIBS to just after $lib_objs in the link command line. Otherwise the linker doesn't find the functions called by the program being compiled. $LIBS is ofr libraries specified by the compile script user.
We don't currently have any tests checked in to do this. Tested with netCDF-4 and hdf5 on jam.
Diffstat (limited to 'fortran/src/h5fc.in')
-rwxr-xr-xfortran/src/h5fc.in17
1 files changed, 10 insertions, 7 deletions
diff --git a/fortran/src/h5fc.in b/fortran/src/h5fc.in
index cfb3cb4..9e9409d 100755
--- a/fortran/src/h5fc.in
+++ b/fortran/src/h5fc.in
@@ -81,9 +81,11 @@ FLINKERBASE="@FC@"
# FLAGS brought from the hdf5 build are put in H5BLD_*FLAGS.
# User's FFLAGS come after their H5BLD counterparts to override
-# them. User's LDFLAGS and $LIBS come just before clibpath and the hdf5
-# libraries in $link_args, followed by any external library paths and libraries
-# from AM_LDFLAGS, LDFLAGS, AM_LIBS or LIBS carried in from the hdf5 build.
+# them. User's LDFLAGS come just before clibpath, user's LIBS come after
+# $link_objs and before the hdf5 libraries in $link_args, followed by any
+# external library paths and libraries from AM_LDFLAGS, LDFLAGS, AM_LIBS
+# or LIBS carried in from the hdf5 build.
+
H5BLD_FFLAGS="@AM_FCFLAGS@ @FCFLAGS@"
F9XMODFLAG="@F9XMODFLAG@"
F9XSUFFIXFLAG="@F9XSUFFIXFLAG@"
@@ -343,10 +345,11 @@ if test "x$do_link" = "xyes"; then
link_args="$link_args $H5BLD_LDFLAGS $H5BLD_LIBS"
# User's FFLAGS come after their H5BLD counterparts to override
- # them. User's LDFLAGS and $LIBS come just before clibpath and the hdf5
- # libraries in $link_args, followed by any external library paths and libraries
- # from AM_LDFLAGS, LDFLAGS, AM_LIBS or LIBS carried in from the hdf5 build.
- $SHOW $FLINKER $FFLAGS $H5BLD_FFLAGS $F9XSUFFIXFLAG $LDFLAGS $LIBS $fmodules $link_objs $link_args $shared_link
+ # them. User's LDFLAGS come just before clibpath, user's LIBS come after
+ # $link_objs and before the hdf5 libraries in $link_args, followed by any
+ # external library paths and libraries from AM_LDFLAGS, LDFLAGS, AM_LIBS
+ # or LIBS carried in from the hdf5 build.
+ $SHOW $FLINKER $FFLAGS $H5BLD_FFLAGS $F9XSUFFIXFLAG $LDFLAGS $fmodules $link_objs $LIBS $link_args $shared_link
status=$?
fi