diff options
author | trevor <trevor@FreeBSD.org> | 2003-06-01 15:25:10 +0800 |
---|---|---|
committer | trevor <trevor@FreeBSD.org> | 2003-06-01 15:25:10 +0800 |
commit | 982d2409162b58ae79a7e80148a839fecb557c36 (patch) | |
tree | 28171504e67b17cad8c89ec1d0fd2bb0b01337fd | |
parent | c2ae62a618929625a70ab4d4c6cdeaa09dc4c3d0 (diff) | |
download | freebsd-ports-gnome-982d2409162b58ae79a7e80148a839fecb557c36.tar.gz freebsd-ports-gnome-982d2409162b58ae79a7e80148a839fecb557c36.tar.zst freebsd-ports-gnome-982d2409162b58ae79a7e80148a839fecb557c36.zip |
patch to enable compilation with GCC 3.2.2
-rw-r--r-- | x11-wm/clementine/Makefile | 8 | ||||
-rw-r--r-- | x11-wm/clementine/files/patch-painter.cpp | 42 |
2 files changed, 43 insertions, 7 deletions
diff --git a/x11-wm/clementine/Makefile b/x11-wm/clementine/Makefile index 49d262a55d4b..8ffc370056ed 100644 --- a/x11-wm/clementine/Makefile +++ b/x11-wm/clementine/Makefile @@ -17,12 +17,6 @@ COMMENT= Has title bars, iconizing, and styles (unstable) RUN_DEPENDS= xv:${PORTSDIR}/graphics/xv \ rxvt:${PORTSDIR}/x11/rxvt -.include <bsd.port.pre.mk> - -.if ${OSVERSION} >= 500113 -BROKEN= "Does not compile (bad C++ code)" -.endif - PLIST= ${WRKDIR}/pkg-plist PKGMESSAGE= ${WRKDIR}/pkg-message USE_GMAKE= yes @@ -69,4 +63,4 @@ do-install: post-install: @${CAT} ${PKGMESSAGE} -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/x11-wm/clementine/files/patch-painter.cpp b/x11-wm/clementine/files/patch-painter.cpp new file mode 100644 index 000000000000..a0cde107049b --- /dev/null +++ b/x11-wm/clementine/files/patch-painter.cpp @@ -0,0 +1,42 @@ +$FreeBSD$ + +--- painter.cpp.orig Sat Mar 23 03:23:17 2002 ++++ painter.cpp Tue May 27 19:25:40 2003 +@@ -9,6 +9,7 @@ + #include <cassert> + #include <algorithm> + #include <cmath> ++#include <iostream> + + #define DEF_FONT "fixed" + #define DEF_ACTIVE_FG "white" +@@ -420,7 +421,7 @@ + cs = look->activeButtonFacet()->color(); + else + cs = look->inactiveButtonFacet()->color(); +- if ( std::fmod(width,2) == 0 ) ++ if ( std::fmod((float)width,2) == 0 ) + width--; + height = width; + int half = height/2; +@@ -428,13 +429,13 @@ + y += half - int(.2*height); // move down a bit + height = half; // reduce height + setForeground( cs.color.pixel() ); +- drawLine( d, x, y, x + std::ceil(width/2) + 1, y + height + 1 ); +- drawLine( d, x + 1, y, x + std::ceil(width/2) + 1, y + height ); +- drawLine( d, x, y + 1, x + std::ceil(width/2), y + height + 1 ); +- drawLine( d, x + std::ceil(width/2), y + height, x + width, y -1 ); +- drawLine( d, x + std::ceil(width/2), y + height-1, x +width-1, y-1 ); +- drawLine( d, x + std::ceil(width/2)+1, y + height, x +width, y ); +- drawPoint( d, x + std::ceil(width/2), y + height + 1 ); ++ drawLine( d, x, y, x + (int) std::ceil((float)width/2) + 1, y + height + 1 ); ++ drawLine( d, x + 1, y, x + (int) std::ceil((float)width/2) + 1, y + height ); ++ drawLine( d, x, y + 1, x + (int) std::ceil((float)width/2), y + height + 1 ); ++ drawLine( d, x + (int) std::ceil((float)width/2), y + height, x + width, y -1 ); ++ drawLine( d, x + (int) std::ceil((float)width/2), y + height-1, x +width-1, y-1 ); ++ drawLine( d, x + (int) std::ceil((float)width/2)+1, y + height, x +width, y ); ++ drawPoint( d, x + (int) std::ceil((float)width/2), y + height + 1 ); + } + + void Painter::setButtonBackground( Drawable d, Painter::Button b, bool active, |