diff options
author | Albert Cheng <acheng@hdfgroup.org> | 2012-10-10 05:08:59 (GMT) |
---|---|---|
committer | Albert Cheng <acheng@hdfgroup.org> | 2012-10-10 05:08:59 (GMT) |
commit | 9ea64eb0b875f4295ce8a24e004975c6632739fe (patch) | |
tree | aa70ccec985951e026416e898b4e02ae0d9e68b0 /config | |
parent | f6d4f0ef8f93c73e85a4efacbd6d71fc386a9020 (diff) | |
download | hdf5-9ea64eb0b875f4295ce8a24e004975c6632739fe.zip hdf5-9ea64eb0b875f4295ce8a24e004975c6632739fe.tar.gz hdf5-9ea64eb0b875f4295ce8a24e004975c6632739fe.tar.bz2 |
[svn-r22880] Bug Fix: HDFFV 8017
dt_arith would fail in Lion and Mountain Lion system when GCC version 4.2.1
is used with --enable-production. Somehow the -O optimization will fail some of
the hard conversion code.
Solution:
This is just a temporary patch by detecting if this is a Lion or Mountain Lion
system using GCC 4.2.1, then just remove the any -O option from the PROD_CFLAGS.
A better fix should be deviced later.
Tested: Duck(lion) and Owl (mountain lion) tested with --enable-production.
Also tested in Fred and Tejeda, both Snow Leopard systems to verify there is
no undesired side effect.
Diffstat (limited to 'config')
-rw-r--r-- | config/apple | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/config/apple b/config/apple index a2d6ae4..34085e0 100644 --- a/config/apple +++ b/config/apple @@ -28,6 +28,22 @@ fi # Figure out compiler flags . $srcdir/config/gnu-flags +# temp patch: if GCC 4.2.1 is used in Lion or Mountain Lion systems, do not +# use -O option as it causes failures in test/dt_arith. +#echo host_os=$host_os +case "$host_os" in + darwin1[12].*) # lion & mountain lion + #echo cc_vendor=$cc_vendor'-'cc_version=$cc_version + case "$cc_vendor-$cc_version" in + gcc-4.2.1) + # Remove any -O flags + #echo PROD_CFLAGS=$PROD_CFLAGS + PROD_CFLAGS="`echo $PROD_CFLAGS | sed -e 's/-O[0-3]*//'`" + #echo new PROD_CFLAGS=$PROD_CFLAGS + ;; + esac + ;; +esac . $srcdir/config/intel-flags if test "X-" = "X-$FC"; then |