This build of SeaMonkey for OS/2 was made from code in comm-central and mozilla-1.9.1 dated 2009-05-14 11:20:20 PDT (changesets bb38d33f5744 and 4be322ea507d, resp.). But the build could only be completed (with GCC 3.3.5) by adding the patches for bug 487567, bug 451278, and bug 453705. See all patches against mozilla-1.9.1 below. diff --git a/js/src/xpconnect/src/qsgen.py b/js/src/xpconnect/src/qsgen.py --- a/js/src/xpconnect/src/qsgen.py +++ b/js/src/xpconnect/src/qsgen.py @@ -470,6 +470,12 @@ "XPCVariant::newVariant(ccx, ${argVal})));\n" " if (!${name})\n" " return JS_FALSE;\n") + if os.name == 'os2': # Workaround for GCC 3.3.x bug. + template = ( + " nsCOMPtr ${name}(" + "XPCVariant::newVariant(ccx, ${argVal}));\n" + " if (!${name})\n" + " return JS_FALSE;\n") f.write(substitute(template, params)) return elif type.name == 'nsIAtom': diff --git a/xpcom/string/public/nsTString.h b/xpcom/string/public/nsTString.h --- a/xpcom/string/public/nsTString.h +++ b/xpcom/string/public/nsTString.h @@ -439,19 +439,24 @@ class nsTFixedString_CharT : public nsTS * fixed-size buffer to be used by the string (the contents of * this buffer may be modified by the string) * @param storageSize * the size of the fixed buffer * @param length (optional) * the length of the string already contained in the buffer */ +#ifdef XP_OS2 /* Workaround for GCC 3.3.x bug. */ + nsTFixedString_CharT( char_type* data, size_type storageSize ) NS_COM; + nsTFixedString_CharT( char_type* data, size_type storageSize, size_type length ) NS_COM; +#else NS_COM nsTFixedString_CharT( char_type* data, size_type storageSize ); NS_COM nsTFixedString_CharT( char_type* data, size_type storageSize, size_type length ); +#endif // |operator=| does not inherit, so we must define our own self_type& operator=( char_type c ) { Assign(c); return *this; } self_type& operator=( const char_type* data ) { Assign(data); return *this; } self_type& operator=( const substring_type& str ) { Assign(str); return *this; } self_type& operator=( const substring_tuple_type& tuple ) { Assign(tuple); return *this; } protected: diff --git a/xpcom/string/public/nsTSubstring.h b/xpcom/string/public/nsTSubstring.h --- a/xpcom/string/public/nsTSubstring.h +++ b/xpcom/string/public/nsTSubstring.h @@ -491,17 +491,21 @@ class nsTSubstring_CharT public: /** * this is public to support automatic conversion of tuple to string * base type, which helps avoid converting to nsTAString. */ +#ifdef XP_OS2 /* Workaround for GCC 3.3.x bug. */ + nsTSubstring_CharT(const substring_tuple_type& tuple) NS_COM; +#else NS_COM nsTSubstring_CharT(const substring_tuple_type& tuple); +#endif /** * allows for direct initialization of a nsTSubstring object. * * NOTE: this constructor is declared public _only_ for convenience * inside the string implementation. */ #ifdef XP_OS2 /* Workaround for GCC 3.3.x bug. */ @@ -517,25 +521,33 @@ class nsTSubstring_CharT // XXX GCC 3.4 needs this :-( friend class nsTPromiseFlatString_CharT; char_type* mData; size_type mLength; PRUint32 mFlags; // default initialization +#ifdef XP_OS2 /* Workaround for GCC 3.3.x bug. */ + nsTSubstring_CharT() NS_COM; +#else NS_COM nsTSubstring_CharT(); +#endif // version of constructor that leaves mData and mLength uninitialized explicit NS_COM nsTSubstring_CharT( PRUint32 flags ); // copy-constructor, constructs as dependent on given object // (NOTE: this is for internal use only) +#ifdef XP_OS2 /* Workaround for GCC 3.3.x bug. */ + nsTSubstring_CharT( const self_type& str ) NS_COM; +#else NS_COM nsTSubstring_CharT( const self_type& str ); +#endif /** * this function releases mData and does not change the value of * any of its member variables. in other words, this function acts * like a destructor. */ void NS_FASTCALL Finalize(); diff --git a/security/nss/lib/freebl/os2_rand.c b/security/nss/lib/freebl/os2_rand.c --- a/security/nss/lib/freebl/os2_rand.c +++ b/security/nss/lib/freebl/os2_rand.c @@ -369,5 +369,5 @@ size_t RNG_SystemRNG(void *dest, size_t maxLen) { - return rng_systemFromNoise(dest,maxlen); + return rng_systemFromNoise(dest,maxLen); }