Package: synfig
Version: 0.61.05-3
Severity: important
Tags: patch

When building 'synfig' on amd64/unstable, I get the following error:

 x86_64-linux-gnu-g++ -DHAVE_CONFIG_H -I../.. -I../.. -I../../src 
-I../../libltdl -I/usr/include/libxml++-2.6 -I/usr/lib/libxml++-2.6/include 
-I/usr/include/libxml2 -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include 
-I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0 
-I/usr/lib/glib-2.0/include -I/usr/include/sigc++-2.0 
-I/usr/lib/sigc++-2.0/include -DSYNFIG_NO_DEPRECATED -DLIBDIR=\"/usr/lib\" 
-DSYSCONFDIR=\"/etc/synfig\" -DNDEBUG -g -O2 -ffast-math -W -Wall 
-Wno-unused-parameter -fpermissive -MT libsynfig_la-layer_shape.lo -MD -MP -MF 
.deps/libsynfig_la-layer_shape.Tpo -c layer_shape.cpp  -fPIC -DPIC -o 
.libs/libsynfig_la-layer_shape.o
context.h:55: warning: 'class synfig::Context' has virtual functions but 
non-virtual destructor
/usr/include/ETL/_surface.h: In member function 'void etl::surface<T, AT, 
VP>::blit_to(_pen&, int, int, int, int) [with _pen = 
etl::generic_pen<synfig::Color, synfig::Color>, T = synfig::Color, AT = 
synfig::Color, VP = synfig::ColorPrep]':
../../src/synfig/surface.h:99:   instantiated from 'void 
synfig::Surface::blit_to(_pen&, int, int, int, int) [with _pen = 
etl::generic_pen<synfig::Color, synfig::Color>]'
../../src/synfig/surface.h:94:   instantiated from 'void 
synfig::Surface::blit_to(_pen&) [with _pen = etl::generic_pen<synfig::Color, 
synfig::Color>]'
layer_shape.cpp:2491:   instantiated from here
/usr/include/ETL/_surface.h:277: error: no matching function for call to 
'min(int&, long int)'
make[4]: *** [libsynfig_la-layer_shape.lo] Error 1
make[4]: Leaving directory `/synfig-0.61.05/src/synfig'

This can be fixed by the following patch to 'etl':

diff -urN ../tmp-orig/etl-0.04.08/ETL/_surface.h ./ETL/_surface.h
--- ../tmp-orig/etl-0.04.08/ETL/_surface.h      2006-02-19 10:03:19.000000000 
+0000
+++ ./ETL/_surface.h    2006-03-28 11:01:25.000000000 +0000
@@ -274,8 +274,8 @@
                }
                                
                //clip width against dest width
-               w = std::min(w,DEST_PEN.end_x()-DEST_PEN.x());
-               h = std::min(h,DEST_PEN.end_y()-DEST_PEN.y());
+               w = std::min((long)w,(long)(DEST_PEN.end_x()-DEST_PEN.x()));
+               h = std::min((long)h,(long)(DEST_PEN.end_y()-DEST_PEN.y()));
                
                //clip width against src width
                w = std::min(w,w_-x);           

Then I still get the following error:

if /bin/sh ../../libtool --tag=CXX --mode=compile x86_64-linux-gnu-g++ 
-DHAVE_CONFIG_H -I../.. -I../.. -I../../src -I../../libltdl   
-I/usr/include/libxml++-2.6 -I/usr/lib/libxml++-2.6/include 
-I/usr/include/libxml2 -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include 
-I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0 
-I/usr/lib/glib-2.0/include -I/usr/include/sigc++-2.0 
-I/usr/lib/sigc++-2.0/include -DSYNFIG_NO_DEPRECATED -DLIBDIR="\"/usr/lib\"" 
-DSYSCONFDIR="\"/etc/synfig\"" -DNDEBUG -g -O2 -ffast-math -W -Wall 
-Wno-unused-parameter -fpermissive -MT libsynfig_la-surface.lo -MD -MP -MF 
".deps/libsynfig_la-surface.Tpo" -c -o libsynfig_la-surface.lo `test -f 
'surface.cpp' || echo './'`surface.cpp; \
        then mv -f ".deps/libsynfig_la-surface.Tpo" 
".deps/libsynfig_la-surface.Plo"; else rm -f ".deps/libsynfig_la-surface.Tpo"; 
exit 1; fi
 x86_64-linux-gnu-g++ -DHAVE_CONFIG_H -I../.. -I../.. -I../../src 
-I../../libltdl -I/usr/include/libxml++-2.6 -I/usr/lib/libxml++-2.6/include 
-I/usr/include/libxml2 -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include 
-I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0 
-I/usr/lib/glib-2.0/include -I/usr/include/sigc++-2.0 
-I/usr/lib/sigc++-2.0/include -DSYNFIG_NO_DEPRECATED -DLIBDIR=\"/usr/lib\" 
-DSYSCONFDIR=\"/etc/synfig\" -DNDEBUG -g -O2 -ffast-math -W -Wall 
-Wno-unused-parameter -fpermissive -MT libsynfig_la-surface.lo -MD -MP -MF 
.deps/libsynfig_la-surface.Tpo -c surface.cpp  -fPIC -DPIC -o 
.libs/libsynfig_la-surface.o
surface.cpp: In member function 'void 
synfig::Surface::blit_to(synfig::Surface::alpha_pen&, int, int, int, int)':
surface.cpp:161: error: no matching function for call to 'min(int&, long int)'
make[4]: *** [libsynfig_la-surface.lo] Error 1
make[4]: Leaving directory `/synfig-0.61.05/src/synfig'

This can be fixed by the following patch:

diff -urN ../tmp-orig/synfig-0.61.05/src/synfig/surface.cpp 
./src/synfig/surface.cpp
--- ../tmp-orig/synfig-0.61.05/src/synfig/surface.cpp   2005-12-05 
18:56:50.000000000 +0000
+++ ./src/synfig/surface.cpp    2006-03-28 11:52:37.000000000 +0000
@@ -158,8 +158,8 @@
                }
                                
                //clip width against dest width
-               w = min(w,pen.end_x()-pen.x());
-               h = min(h,pen.end_y()-pen.y());
+               w = min((long)w,(long)(pen.end_x()-pen.x()));
+               h = min((long)h,(long)(pen.end_y()-pen.y()));
                
                //clip width against src width
                w = min(w,get_w()-x);           

Regards
Andreas Jochens



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to