Bug 552635 Port fix of Bug 550371 to comm-central r=dmose
authorGinn Chen <ginn.chen@sun.com>
Sat, 10 Apr 2010 08:02:36 +0800
changeset 5424 6327ffb044aa33d44dea95ab1c0a6bf4b9aa9f9f
parent 5423 c4701f6cd60f83a82b925c08148dc351040919a4
child 5425 b1b40a0933a64c1c2e6ea98d205c01b7f7a59d45
push idunknown
push userunknown
push dateunknown
reviewersdmose
bugs552635, 550371
Bug 552635 Port fix of Bug 550371 to comm-central r=dmose
configure.in
--- a/configure.in
+++ b/configure.in
@@ -2639,16 +2639,18 @@ alpha*-*-osf*)
     MOZ_MEMORY=1
     if test "$SOLARIS_SUNPRO_CC"; then
        LIBS="-lCrun -lCstd $LIBS"
        NS_USE_NATIVE=1
        MOZ_FIX_LINK_PATHS=
        AC_DEFINE(NSCAP_DISABLE_DEBUG_PTR_TYPES)
        CFLAGS="$CFLAGS -xlibmieee -xstrconst -xbuiltin=%all"
        CXXFLAGS="$CXXFLAGS -xlibmieee -xbuiltin=%all -features=tmplife -norunpath"
+       _MOZ_EXCEPTIONS_FLAGS_ON='-features=except'
+       _MOZ_EXCEPTIONS_FLAGS_OFF='-features=no%except'
        LDFLAGS="-xildoff -z lazyload -z combreloc $LDFLAGS"
        if test -z "$CROSS_COMPILE" && test -f /usr/lib/ld/map.noexstk; then
            _SAVE_LDFLAGS=$LDFLAGS
            LDFLAGS="-M /usr/lib/ld/map.noexstk $LDFLAGS" 
            AC_TRY_LINK([#include <stdio.h>],
                        [printf("Hello World\n");],
                        ,
                        [LDFLAGS=$_SAVE_LDFLAGS])
@@ -6738,26 +6740,27 @@ if test "$_MOZ_USE_RTTI"; then
    _MOZ_RTTI_FLAGS=$_MOZ_RTTI_FLAGS_ON
 else
    _MOZ_RTTI_FLAGS=$_MOZ_RTTI_FLAGS_OFF
 fi
 
 AC_SUBST(_MOZ_RTTI_FLAGS_ON)
 
 dnl ========================================================
-dnl C++ exceptions (g++/egcs only - for now)
+dnl C++ exceptions (g++/VC/irix6/Sun only - for now)
 dnl Should be smarter and check that the compiler does indeed have exceptions
 dnl ========================================================
 MOZ_ARG_ENABLE_BOOL(cpp-exceptions,
 [  --enable-cpp-exceptions Enable C++ exceptions ],
 [ _MOZ_CPP_EXCEPTIONS=1 ],
 [ _MOZ_CPP_EXCEPTIONS= ])
 
 if test "$_MOZ_CPP_EXCEPTIONS"; then
     _MOZ_EXCEPTIONS_FLAGS=$_MOZ_EXCEPTIONS_FLAGS_ON
+    AC_DEFINE(MOZ_CPP_EXCEPTIONS)
 else
     _MOZ_EXCEPTIONS_FLAGS=$_MOZ_EXCEPTIONS_FLAGS_OFF
 fi
 
 AC_SUBST(_MOZ_EXCEPTIONS_FLAGS_ON)
 
 # Irix & OSF native compilers do not like exception declarations 
 # when exceptions are disabled