Hi Dave,

The patch allowed both HPUX and Solaris builds to succeed.

Ashley Zinyk
XSLT Development



"David Bertoni (JIRA)" <[email protected]>

10/12/2005 10:21 AM

To
Ashley Zinyk/Toronto/[EMAIL PROTECTED]
cc
Subject
[jira] Commented: (XALANC-569) Compile-time assert on 32-bit Solaris & HPUX due to IEEE754 issue





    [ http://issues.apache.org/jira/browse/XALANC-569?page=comments#action_12331901 ]

David Bertoni commented on XALANC-569:
--------------------------------------

Can you try the following patch:

cvs diff -c4 -- DoubleSupport.cpp (in directory V:\xml-xalan\c\src\xalanc\PlatformSupport\)
Index: DoubleSupport.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/xalanc/PlatformSupport/DoubleSupport.cpp,v
retrieving revision 1.12
diff -c -4 -r1.12 DoubleSupport.cpp
*** DoubleSupport.cpp                 7 Oct 2005 22:40:28 -0000                 1.12
--- DoubleSupport.cpp                 12 Oct 2005 16:15:51 -0000
***************
*** 68,81 ****
     s_NaN.d = std::sqrt(-2.01);
 #else
     s_NaN.d = sqrt(-2.01);
 #endif
! #else
!     #if defined(XALAN_NO_STD_NAMESPACE)
!         XALAN_STATIC_ASSERT(numeric_limits<double>::is_iec559);
!     #else
!         XALAN_STATIC_ASSERT(std::numeric_limits<double>::is_iec559);
!     #endif
 #endif
 }
 
 
--- 68,77 ----
     s_NaN.d = std::sqrt(-2.01);
 #else
     s_NaN.d = sqrt(-2.01);
 #endif
! #elif !defined(XALAN_NO_STD_NAMESPACE)
!     XALAN_STATIC_ASSERT(std::numeric_limits<double>::has_quiet_NaN);
 #endif
 }


> Compile-time assert on 32-bit Solaris & HPUX due to IEEE754 issue
> -----------------------------------------------------------------
>
>          Key: XALANC-569
>          URL: http://issues.apache.org/jira/browse/XALANC-569
>      Project: XalanC
>         Type: Bug
>   Components: XalanC
>     Versions: 1.10
>  Environment: 32-bit Solaris & HPUX
>     Reporter: Ashley Zinyk
>      Fix For: 1.10

>
> The following error occurs while compiling DoubleSupport.cpp on Solaris:
> CC -g     -KPIC -mt -xs -ptr../../obj -features=rtti -DSOLARIS -D_REENTRANT -DXALAN_INMEM_MSG_LOADER -c -I/export/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-solaris_28-cc_62/c/src -I/export/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-solaris_28-cc_62/c/include -I../../nls/include -I/export/home/torxslt/BuildClient/xalanc_root/xerces-c_2_7_0-solaris_28-cc_62/src/ -I/export/home/torxslt/BuildClient/xalanc_root/xerces-c_2_7_0-solaris_28-cc_62/include/xercesc -I/export/home/torxslt/BuildClient/xalanc_root/xerces-c_2_7_0-solaris_28-cc_62/include/  -o ../../obj/DoubleSupport.o /export/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-solaris_28-cc_62/c/src/xalanc/PlatformSupport/DoubleSupport.cpp
> "/export/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-solaris_28-cc_62/c/src/xalanc/Include/PlatformDefinitions.hpp", line 126: Error: An array must have at least one element.
> "/export/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-solaris_28-cc_62/c/src/xalanc/PlatformSupport/DoubleSupport.cpp", line 76:     Where: While specializing "xalanc_1_10::XalanCompileErrorBoolean<0>".
> "/export/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-solaris_28-cc_62/c/src/xalanc/PlatformSupport/DoubleSupport.cpp", line 76:     Where: Specialized in non-template code.
> The error is similar on HPUX:
> aCC -g   +DAportable   +Z -DHPUX -D_THREAD_SAFE +W849,930 -mt  -Wc,-koenig_lookup,on -Wc,-ansi_for_scope,on -DXALAN_INMEM_MSG_LOADER -c -I/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/src -I/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/include -I../../nls/include -I/home/torxslt/BuildClient/xalanc_root/xerces-c_2_7_0-hpux_11i-acc_a03/src/ -I/home/torxslt/BuildClient/xalanc_root/xerces-c_2_7_0-hpux_11i-acc_a03/include/xercesc -I/home/torxslt/BuildClient/xalanc_root/xerces-c_2_7_0-hpux_11i-acc_a03/include/  -o ../../obj/DoubleSupport.o /home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/src/xalanc/PlatformSupport/DoubleSupport.cpp
> Error 419: "/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/src/xalanc/PlatformSupport/DoubleSupport.cpp", line 74 # 'is_iec559' is used as a type, but has not been defined as a type.
>             XALAN_STATIC_ASSERT(numeric_limits<double>::is_iec559);
>             ^^^^^^^^^^^^^^^^^^^                                    
> Error 502: "/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/src/xalanc/PlatformSupport/DoubleSupport.cpp", line 74 # Attempt to access 'numeric_limits<double>::<type inserted by compiler>' is invalid; '<type inserted by compiler>' is not a member of 'numeric_limits<double>' or any base class.
>             XALAN_STATIC_ASSERT(numeric_limits<double>::is_iec559);
>             ^^^^^^^^^^^^^^^^^^^                                    
> Error 322: "/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/src/xalanc/PlatformSupport/DoubleSupport.cpp", line 74 # An _expression_ was expected instead of type 'bool (int)' in the specialization of template 'XalanCompileErrorBoolean'.
>             XALAN_STATIC_ASSERT(numeric_limits<double>::is_iec559);
>             ^^^^^^^^^^^^^^^^^^^                                    
> Error 187: "/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/src/xalanc/PlatformSupport/DoubleSupport.cpp", line 74 # Referenced object '@$XalanCompileErrorBoolean' is not a member of class XalanCompileErrorBoolean<bool (int)> ["/home/torxslt/BuildClient/xalanc_root/LatestC-CVS-hpux_11i-acc_a03/c/src/xalanc/PlatformSupport/DoubleSupport.cpp", line 74].
>             XALAN_STATIC_ASSERT(numeric_limits<double>::is_iec559);
>             ^^^^^^^^^^^^^^^^^^^                                    
> The problem was introduced in XALANC-511, which introduces a compile-time check to verify that the platform has IEEE754 (standard floating point) support.  

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
  http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
  http://www.atlassian.com/software/jira


Reply via email to