summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAlbert Cheng <acheng@hdfgroup.org>2007-04-11 23:17:58 (GMT)
committerAlbert Cheng <acheng@hdfgroup.org>2007-04-11 23:17:58 (GMT)
commitde71a7fe74ca0954efec963066e2606d798691f4 (patch)
tree130c8bc9868070bc7242543d49f3b3ea8d6f795b /tools
parente7a398d07453e24eee5681d73e0d6bcfb40af6c7 (diff)
downloadhdf5-de71a7fe74ca0954efec963066e2606d798691f4.zip
hdf5-de71a7fe74ca0954efec963066e2606d798691f4.tar.gz
hdf5-de71a7fe74ca0954efec963066e2606d798691f4.tar.bz2
[svn-r13647] Purpose:
bug fix. Description: If a non-existing or empty source file is used with -c option, the script ended up doing nothing and exit 0--a false success. Changed code so that it would do compile and end in error. Tested: Kagiso.
Diffstat (limited to 'tools')
-rwxr-xr-xtools/misc/h5cc.in11
1 files changed, 9 insertions, 2 deletions
diff --git a/tools/misc/h5cc.in b/tools/misc/h5cc.in
index 398440d..1ead951 100755
--- a/tools/misc/h5cc.in
+++ b/tools/misc/h5cc.in
@@ -1,5 +1,5 @@
#! /bin/sh
-#
+##
# Copyright by The HDF Group.
# Copyright by the Board of Trustees of the University of Illinois.
# All rights reserved.
@@ -12,7 +12,9 @@
# is linked from the top-level documents page. It can also be found at
# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have
# access to either file, you may request a copy from help@hdfgroup.org.
-#
+##
+
+# This tool is adapted from the mpicc command of the MPICH Software.
############################################################################
## ##
@@ -235,6 +237,11 @@ for arg in $@ ; do
esac
done
+if test "$dash_c" = "yes" -a "$do_compile" = no -a "$do_link" = no ; then
+ # -c was specified. Force do_compile on.
+ do_compile=yes
+fi
+
if test "x$do_compile" = "xyes"; then
if test "x$dash_c" != "xyes"; then
compile_args="-c $compile_args"