rpms/openoffice.org/devel openoffice.org-2.3.1.ooo84001.slideshow.gccisaprick.patch, NONE, 1.1 openoffice.org.spec, 1.1346, 1.1347

Caolan McNamara (caolanm) fedora-extras-commits at redhat.com
Tue Nov 27 08:58:30 UTC 2007


Author: caolanm

Update of /cvs/pkgs/rpms/openoffice.org/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv8249

Modified Files:
	openoffice.org.spec 
Added Files:
	openoffice.org-2.3.1.ooo84001.slideshow.gccisaprick.patch 
Log Message:
add openoffice.org-2.3.1.ooo84001.slideshow.gccisaprick.patch because gcc wants to WASTE MY TIME

openoffice.org-2.3.1.ooo84001.slideshow.gccisaprick.patch:

--- NEW FILE openoffice.org-2.3.1.ooo84001.slideshow.gccisaprick.patch ---
Index: source/engine/smilfunctionparser.cxx
===================================================================
RCS file: /cvs/graphics/slideshow/source/engine/smilfunctionparser.cxx,v
retrieving revision 1.7.12.1
diff -u -r1.7.12.1 smilfunctionparser.cxx
--- openoffice.org.orig/slideshow/source/engine/smilfunctionparser.cxx	26 Oct 2007 15:11:25 -0000	1.7.12.1
+++ openoffice.org/slideshow/source/engine/smilfunctionparser.cxx	27 Nov 2007 08:50:17 -0000
@@ -100,191 +100,197 @@
 
             typedef ::boost::shared_ptr< ParserContext > ParserContextSharedPtr;
 
+        }
 
-            template< typename Generator > class ShapeBoundsFunctor
+        template< typename Generator > class ShapeBoundsFunctor
+        {
+        public:
+            ShapeBoundsFunctor( Generator 						aGenerator,
+                                const ParserContextSharedPtr& 	rContext ) :
+                maGenerator( aGenerator ),
+                mpContext( rContext )
             {
-            public:
-                ShapeBoundsFunctor( Generator 						aGenerator,
-                                    const ParserContextSharedPtr& 	rContext ) :
-                    maGenerator( aGenerator ),
-                    mpContext( rContext )
-                {
-                    ENSURE_AND_THROW( mpContext,
-                                      "ShapeBoundsFunctor::ShapeBoundsFunctor(): Invalid context" );
-                }
+                ENSURE_AND_THROW( mpContext,
+                                  "ShapeBoundsFunctor::ShapeBoundsFunctor(): Invalid context" );
+            }
 
-                void operator()( StringIteratorT, StringIteratorT ) const
-                {
-                    mpContext->maOperandStack.push( 
-                        ExpressionNodeFactory::createConstantValueExpression( 
-                            maGenerator( mpContext->maShapeBounds ) ) );
-                }
+            void operator()( StringIteratorT, StringIteratorT ) const
+            {
+                mpContext->maOperandStack.push( 
+                    ExpressionNodeFactory::createConstantValueExpression( 
+                        maGenerator( mpContext->maShapeBounds ) ) );
+            }
 
-            private:
-                Generator				maGenerator;
-                ParserContextSharedPtr	mpContext;
-            };
+        private:
+            Generator				maGenerator;
+            ParserContextSharedPtr	mpContext;
+        };
 
+        namespace
+        {
             template< typename Generator > ShapeBoundsFunctor< Generator > 
 	            makeShapeBoundsFunctor( const Generator& 				rGenerator,
                                         const ParserContextSharedPtr&	rContext )
             {
                 return ShapeBoundsFunctor<Generator>(rGenerator, rContext);
             }
+        }
 
-            /** Generate apriori constant value
-             */
-            class ConstantFunctor
+        /** Generate apriori constant value
+         */
+        class ConstantFunctor
+        {
+        public:
+            ConstantFunctor( double 						rValue,
+                             const ParserContextSharedPtr&	rContext ) :
+                mnValue( rValue ),
+                mpContext( rContext )
             {
-            public:
-                ConstantFunctor( double 						rValue,
-                                 const ParserContextSharedPtr&	rContext ) :
-                    mnValue( rValue ),
-                    mpContext( rContext )
-                {
-                    ENSURE_AND_THROW( mpContext,
-                                      "ConstantFunctor::ConstantFunctor(): Invalid context" );
-                }
+                ENSURE_AND_THROW( mpContext,
+                                  "ConstantFunctor::ConstantFunctor(): Invalid context" );
+            }
 
-                void operator()( StringIteratorT, StringIteratorT ) const
-                {
-                    mpContext->maOperandStack.push( 
-                        ExpressionNodeFactory::createConstantValueExpression( mnValue ) );
-                }
+            void operator()( StringIteratorT, StringIteratorT ) const
+            {
+                mpContext->maOperandStack.push( 
+                    ExpressionNodeFactory::createConstantValueExpression( mnValue ) );
+            }
 
-            private:
-                const double			mnValue;
-                ParserContextSharedPtr	mpContext;
-            };
+        private:
+            const double			mnValue;
+            ParserContextSharedPtr	mpContext;
+        };
+
+        /** Generate parse-dependent-but-then-constant value
+         */
+        class DoubleConstantFunctor
+        {
+        public:
+            DoubleConstantFunctor( const ParserContextSharedPtr& rContext ) :
+                mpContext( rContext )
+            {
+                ENSURE_AND_THROW( mpContext,
+                                  "DoubleConstantFunctor::DoubleConstantFunctor(): Invalid context" );
+            }
 
-            /** Generate parse-dependent-but-then-constant value
-             */
-            class DoubleConstantFunctor
+            void operator()( double n ) const
             {
-            public:
-                DoubleConstantFunctor( const ParserContextSharedPtr& rContext ) :
-                    mpContext( rContext )
-                {
-                    ENSURE_AND_THROW( mpContext,
-                                      "DoubleConstantFunctor::DoubleConstantFunctor(): Invalid context" );
-                }
+                // push constant value expression to the stack
+                mpContext->maOperandStack.push( 
+                    ExpressionNodeFactory::createConstantValueExpression( n ) );
+            }
+
+        private:
+            ParserContextSharedPtr	mpContext;
+        };
+
+        /** Generate special t value expression node
+        */
+        class ValueTFunctor
+        {
+        public:
+            ValueTFunctor( const ParserContextSharedPtr& rContext ) :
+                mpContext( rContext )
+            {
+                ENSURE_AND_THROW( mpContext,
+                    "ValueTFunctor::ValueTFunctor(): Invalid context" );
+            }
 
-                void operator()( double n ) const
+            void operator()( StringIteratorT, StringIteratorT ) const
+            {
+                if( !mpContext->mbParseAnimationFunction )
                 {
-                    // push constant value expression to the stack
-                    mpContext->maOperandStack.push( 
-                        ExpressionNodeFactory::createConstantValueExpression( n ) );
+                    OSL_ENSURE( false,
+                        "ValueTFunctor::operator(): variable encountered, but we're not parsing a function here" );
+                    throw ParseError();
                 }
 
-            private:
-                ParserContextSharedPtr	mpContext;
-            };
+                // push special t value expression to the stack
+                mpContext->maOperandStack.push( 
+                    ExpressionNodeFactory::createValueTExpression() );
+            }
 
-            /** Generate special t value expression node
+        private:
+            ParserContextSharedPtr	mpContext;
+        };
+
+        template< typename Functor > class UnaryFunctionFunctor
+        {
+        private:
+            /** ExpressionNode implementation for unary
+                function over one ExpressionNode
              */
-            class ValueTFunctor
+            class UnaryFunctionExpression : public ExpressionNode
             {
             public:
-                ValueTFunctor( const ParserContextSharedPtr& rContext ) :
-                    mpContext( rContext )
+                UnaryFunctionExpression( const Functor&					rFunctor,
+                                         const ExpressionNodeSharedPtr&	rArg ) :
+                    maFunctor( rFunctor ),
+                    mpArg( rArg )
                 {
-                    ENSURE_AND_THROW( mpContext,
-                                      "ValueTFunctor::ValueTFunctor(): Invalid context" );
                 }
 
-                void operator()( StringIteratorT, StringIteratorT ) const
+                virtual double operator()( double t ) const
                 {
-                    if( !mpContext->mbParseAnimationFunction )
-                    {
-                        OSL_ENSURE( false,
-                                    "ValueTFunctor::operator(): variable encountered, but we're not parsing a function here" );
-                        throw ParseError();
-                    }
-
-                    // push special t value expression to the stack
-                    mpContext->maOperandStack.push( 
-                        ExpressionNodeFactory::createValueTExpression() );
+                    return maFunctor( (*mpArg)(t) );
+                }
+                
+                virtual bool isConstant() const
+                {
+                    return mpArg->isConstant();
                 }
 
             private:
-                ParserContextSharedPtr	mpContext;
+                Functor					maFunctor;
+                ExpressionNodeSharedPtr	mpArg;
             };
 
-            template< typename Functor > class UnaryFunctionFunctor
+        public:
+            UnaryFunctionFunctor( const Functor& 				rFunctor,
+                                  const ParserContextSharedPtr&	rContext ) :
+                maFunctor( rFunctor ),
+                mpContext( rContext )
             {
-            private:
-                /** ExpressionNode implementation for unary
-                    function over one ExpressionNode
-                 */
-                class UnaryFunctionExpression : public ExpressionNode
-                {
-                public:
-                    UnaryFunctionExpression( const Functor&					rFunctor,
-                                             const ExpressionNodeSharedPtr&	rArg ) :
-                        maFunctor( rFunctor ),
-                        mpArg( rArg )
-                    {
-                    }
+                ENSURE_AND_THROW( mpContext,
+                                  "UnaryFunctionFunctor::UnaryFunctionFunctor(): Invalid context" );
+            }
 
-                    virtual double operator()( double t ) const
-                    {
-                        return maFunctor( (*mpArg)(t) );
-                    }
-                    
-                    virtual bool isConstant() const
-                    {
-                        return mpArg->isConstant();
-                    }
+            void operator()( StringIteratorT, StringIteratorT ) const
+            {
+                ParserContext::OperandStack& rNodeStack( mpContext->maOperandStack );
 
-                private:
-                    Functor					maFunctor;
-                    ExpressionNodeSharedPtr	mpArg;
-                };
+                if( rNodeStack.size() < 1 )
+                    throw ParseError( "Not enough arguments for unary operator" );
 
-            public:
-                UnaryFunctionFunctor( const Functor& 				rFunctor,
-                                      const ParserContextSharedPtr&	rContext ) :
-                    maFunctor( rFunctor ),
-                    mpContext( rContext )
+                // retrieve arguments
+                ExpressionNodeSharedPtr pArg( rNodeStack.top() );
+                rNodeStack.pop();
+
+                // check for constness
+                if( pArg->isConstant() )
                 {
-                    ENSURE_AND_THROW( mpContext,
-                                      "UnaryFunctionFunctor::UnaryFunctionFunctor(): Invalid context" );
+                    rNodeStack.push( 
+                        ExpressionNodeFactory::createConstantValueExpression(
+                            maFunctor( (*pArg)(0.0) ) ) );
                 }
-
-                void operator()( StringIteratorT, StringIteratorT ) const
+                else
                 {
-                    ParserContext::OperandStack& rNodeStack( mpContext->maOperandStack );
-
-                    if( rNodeStack.size() < 1 )
-                        throw ParseError( "Not enough arguments for unary operator" );
-
-                    // retrieve arguments
-                    ExpressionNodeSharedPtr pArg( rNodeStack.top() );
-                    rNodeStack.pop();
-
-                    // check for constness
-                    if( pArg->isConstant() )
-                    {
-                        rNodeStack.push( 
-                            ExpressionNodeFactory::createConstantValueExpression(
-                                maFunctor( (*pArg)(0.0) ) ) );
-                    }
-                    else
-                    {
-                        // push complex node, that calcs the value on demand
-                        rNodeStack.push( 
-                            ExpressionNodeSharedPtr(
-                                new UnaryFunctionExpression( 
-                                    maFunctor,
-                                    pArg ) ) );
-                    }
+                    // push complex node, that calcs the value on demand
+                    rNodeStack.push( 
+                        ExpressionNodeSharedPtr(
+                            new UnaryFunctionExpression( 
+                                maFunctor,
+                                pArg ) ) );
                 }
+            }
 
-            private:
-                Functor					maFunctor;
-                ParserContextSharedPtr	mpContext;
-            };
+        private:
+            Functor					maFunctor;
+            ParserContextSharedPtr	mpContext;
+        };
 
+	namespace
+	{
             // TODO(Q2): Refactor makeUnaryFunctionFunctor,
             // makeBinaryFunctionFunctor and the whole
             // ExpressionNodeFactory, to use a generic
@@ -306,95 +312,100 @@
             {
                 return UnaryFunctionFunctor< double (*)(double) >( pFunc, rContext );
             }
+        }
 
-            /** Implements a binary function over two ExpressionNodes
+        /** Implements a binary function over two ExpressionNodes
 
-                @tpl Generator
-                Generator functor, to generate an ExpressionNode of
-                appropriate type
-                
-             */
-            template< class Generator > class BinaryFunctionFunctor
+            @tpl Generator
+            Generator functor, to generate an ExpressionNode of
+            appropriate type
+            
+         */
+        template< class Generator > class BinaryFunctionFunctor
+        {
+        public:
+            BinaryFunctionFunctor( const Generator& 				rGenerator,
+                                   const ParserContextSharedPtr&	rContext ) :
+                maGenerator( rGenerator ),
+                mpContext( rContext )
             {
-            public:
-                BinaryFunctionFunctor( const Generator& 				rGenerator,
-                                       const ParserContextSharedPtr&	rContext ) :
-                    maGenerator( rGenerator ),
-                    mpContext( rContext )
-                {
-                    ENSURE_AND_THROW( mpContext,
-                                      "BinaryFunctionFunctor::BinaryFunctionFunctor(): Invalid context" );
-                }
+                ENSURE_AND_THROW( mpContext,
+                                  "BinaryFunctionFunctor::BinaryFunctionFunctor(): Invalid context" );
+            }
 
-                void operator()( StringIteratorT, StringIteratorT ) const
-                {
-                    ParserContext::OperandStack& rNodeStack( mpContext->maOperandStack );
+            void operator()( StringIteratorT, StringIteratorT ) const
+            {
+                ParserContext::OperandStack& rNodeStack( mpContext->maOperandStack );
 
-                    if( rNodeStack.size() < 2 )
-                        throw ParseError( "Not enough arguments for binary operator" );
+                if( rNodeStack.size() < 2 )
+                    throw ParseError( "Not enough arguments for binary operator" );
 
-                    // retrieve arguments
-                    ExpressionNodeSharedPtr pSecondArg( rNodeStack.top() );
-                    rNodeStack.pop();
-                    ExpressionNodeSharedPtr pFirstArg( rNodeStack.top() );
-                    rNodeStack.pop();
-
-                    // create combined ExpressionNode
-                    ExpressionNodeSharedPtr pNode( maGenerator( pFirstArg,
-                                                                pSecondArg ) );
-                    // check for constness
-                    if( pFirstArg->isConstant() &&
-                        pSecondArg->isConstant() )
-                    {
-                        // call the operator() at pNode, store result
-                        // in constant value ExpressionNode.
-                        rNodeStack.push( 
-                            ExpressionNodeFactory::createConstantValueExpression(
-                                (*pNode)( 0.0 ) ) );
-                    }
-                    else
-                    {
-                        // push complex node, that calcs the value on demand
-                        rNodeStack.push( pNode );
-                    }
+                // retrieve arguments
+                ExpressionNodeSharedPtr pSecondArg( rNodeStack.top() );
+                rNodeStack.pop();
+                ExpressionNodeSharedPtr pFirstArg( rNodeStack.top() );
+                rNodeStack.pop();
+
+                // create combined ExpressionNode
+                ExpressionNodeSharedPtr pNode( maGenerator( pFirstArg,
+                                                            pSecondArg ) );
+                // check for constness
+                if( pFirstArg->isConstant() &&
+                    pSecondArg->isConstant() )
+                {
+                    // call the operator() at pNode, store result
+                    // in constant value ExpressionNode.
+                    rNodeStack.push( 
+                        ExpressionNodeFactory::createConstantValueExpression(
+                            (*pNode)( 0.0 ) ) );
                 }
+                else
+                {
+                    // push complex node, that calcs the value on demand
+                    rNodeStack.push( pNode );
+                }
+            }
 
-            private:
-                Generator				maGenerator;
-                ParserContextSharedPtr	mpContext;
-            };
+        private:
+            Generator				maGenerator;
+            ParserContextSharedPtr	mpContext;
+        };
 
+        namespace
+        {
             template< typename Generator > BinaryFunctionFunctor<Generator> 
             	makeBinaryFunctionFunctor( const Generator&					rGenerator,
                                            const ParserContextSharedPtr&	rContext )
             {
                 return BinaryFunctionFunctor<Generator>( rGenerator, rContext );
             }
+        }
 
+        // Workaround for MSVC compiler anomaly (stack trashing)
+        //
+        // The default ureal_parser_policies implementation of parse_exp 
+        // triggers a really weird error in MSVC7 (Version 13.00.9466), in 
+        // that the real_parser_impl::parse_main() call of parse_exp() 
+        // overwrites the frame pointer _on the stack_ (EBP of the calling
+        // function gets overwritten while lying on the stack). 
+        //
+        // For the time being, our parser thus can only read the 1.0E10 
+        // notation, not the 1.0e10 one.
+        //
+        // TODO(F1): Also handle the 1.0e10 case here.
+        template< typename T > struct custom_real_parser_policies : public ::boost::spirit::ureal_parser_policies<T>
+        {
+            template< typename ScannerT >
+                    static typename ::boost::spirit::parser_result< ::boost::spirit::chlit<>, ScannerT >::type
+            parse_exp(ScannerT& scan)
+            { 
+                // as_lower_d somehow breaks MSVC7
+                return ::boost::spirit::ch_p('E').parse(scan); 
+            }
+        };
 
-            // Workaround for MSVC compiler anomaly (stack trashing)
-            //
-            // The default ureal_parser_policies implementation of parse_exp 
-            // triggers a really weird error in MSVC7 (Version 13.00.9466), in 
-            // that the real_parser_impl::parse_main() call of parse_exp() 
-            // overwrites the frame pointer _on the stack_ (EBP of the calling
-            // function gets overwritten while lying on the stack). 
-            //
-            // For the time being, our parser thus can only read the 1.0E10 
-            // notation, not the 1.0e10 one.
-            //
-            // TODO(F1): Also handle the 1.0e10 case here.
-            template< typename T > struct custom_real_parser_policies : public ::boost::spirit::ureal_parser_policies<T>
-            {
-                template< typename ScannerT >
-	                static typename ::boost::spirit::parser_result< ::boost::spirit::chlit<>, ScannerT >::type
-                parse_exp(ScannerT& scan)
-                { 
-                    // as_lower_d somehow breaks MSVC7
-                    return ::boost::spirit::ch_p('E').parse(scan); 
-                }
-            };
-
+        namespace
+        {
             /* This class implements the following grammar (more or
                less literally written down below, only slightly
                obfuscated by the parser actions):


Index: openoffice.org.spec
===================================================================
RCS file: /cvs/pkgs/rpms/openoffice.org/devel/openoffice.org.spec,v
retrieving revision 1.1346
retrieving revision 1.1347
diff -u -r1.1346 -r1.1347
--- openoffice.org.spec	25 Nov 2007 14:33:45 -0000	1.1346
+++ openoffice.org.spec	27 Nov 2007 08:57:54 -0000	1.1347
@@ -157,6 +157,7 @@
 Patch74: openoffice.org-2.3.1.ooo83877.sal.allowsoftlinkdelete.patch
 Patch75: openoffice.org-2.3.1.ooo83878.unopkg.enablelinking.patch
 Patch76: openoffice.org-2.3.1.ooo83930.sw.flushanchors.patch
+Patch77: openoffice.org-2.3.1.ooo84001.slideshow.gccisaprick.patch
 
 %define instdir %{_libdir}/openoffice.org
 
@@ -1112,6 +1113,7 @@
 %patch74 -p1 -b .ooo83877.sal.allowsoftlinkdelete.patch
 %patch75 -p1 -b .ooo83878.unopkg.enablelinking.patch
 %patch76 -p1 -b .ooo83930.sw.flushanchors.patch
+%patch77 -p1 -b .ooo84001.slideshow.gccisaprick.patch
 
 %if %{linkopt}
 chmod a+x solenv/bin/mklinkscript.pl
@@ -2812,6 +2814,7 @@
 * Sat Nov 24 2007 Caolan McNamara <caolanm at redhat.com> - 1:2.3.1-9.4
 - Resolves: rhbz#384391 add openoffice.org-2.3.1.ooo83930.sw.flushanchors.patch
 - split out libhyphen and hyphenators
+- add openoffice.org-2.3.1.ooo84001.slideshow.gccisaprick.patch coz gcc hates us
 
 * Thu Nov 22 2007 Caolan McNamara <caolanm at redhat.com> - 1:2.3.1-9.3
 - Resolves: rhbz#247634 add openoffice.org-2.3.1.ooo82911.sd.insertbackground.patch (jnavrati)




More information about the fedora-extras-commits mailing list