Bugs item #3576397, was opened at 2012-10-11 10:49
Message generated for change (Tracker Item Submitted) made by mike-delorimier
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=536845&aid=3576397&group_id=73133

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Michael deLorimier (mike-delorimier)
Assigned to: Nobody/Anonymous (nobody)
Summary: wxc-0.90.0.4 + WxWidgets 2.9 install problem

Initial Comment:
I'm trying to install reactive-banana-wx, but wxc won't compile.

When I try
  cabal install wxc
I get a C++ compile error.

Making cabal constraints explicit shows me that this error occurs for 
wxc-0.90.0.1 through wxc-0.90.0.4

My WxWidgets library is 2.9 and I installed it from a tarball (since it doesn't 
have a debian package).
cabal --version = 0.14.0  My cabal constraint file is the default.
ghc --version = 7.4.1
gcc --version = (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
OS version:
michael-x201% cat /proc/version
Linux version 3.2.0-31-generic (buildd@allspice) (gcc version 4.6.3 
(Ubuntu/Linaro 4.6.3-1ubuntu5) ) #50-Ubuntu SMP Fri Sep 7 16:16:45 UTC 2012

Also, the bad code is in a #ifdef case when the __WXGTK__ flag is enabled.

The C++ compiler error is:
/usr/bin/gcc -Wl,--hash-size=31 -Wl,--reduce-memory-overheads -Isrc/incl
ude -I/usr/local/include/wx-2.9 -I/usr/local/lib/wx/include/gtk2-unicode
-2.9 -D__WXGTK__ -DWXUSINGDLL -D_FILE_OFFSET_BITS=64 -DwxcREFUSE_MEDIACT
RL -fPIC -c src/cpp/eljpen.cpp -o dist/build/src/cpp/eljpen.o
src/cpp/eljpen.cpp: In function ‘void wxPen_GetStipple(void*, wxBitmap*)
’:
src/cpp/eljpen.cpp:159:13: error: conversion from ‘long int’ to ‘const w
xBitmap’ is ambiguous
src/cpp/eljpen.cpp:159:13: note: candidates are:
/usr/local/include/wx-2.9/wx/gtk/bitmap.h:83:5: note: wxBitmap::wxBitmap
(GdkPixbuf*)  
/usr/local/include/wx-2.9/wx/gtk/bitmap.h:73:5: note: wxBitmap::wxBitmap
(const char* const*)
/usr/local/include/wx-2.9/wx/gtk/bitmap.h:64:24: error:   initializing a
rgument 1 of ‘wxBitmap& wxBitmap::operator=(const wxBitmap&)’

The offending code, in file src/cpp/eljpen.cpp, is:
EWXWEXPORT(void,wxPen_GetStipple)(void* self,wxBitmap* _ref)
{
#if defined(__WXGTK__)
    *_ref = NULL;
#else
    *_ref = *(((wxPen*)self)->GetStipple());
#endif
}

To get it to compile I replaced the NULL on line 159 with wxBitmap();
Some examples in reactive-banana-wx now run so my fix didn't break everything.

So what's the problem? I'm pretty sure the wx 2.9 library it's using is the 
right one. Did no one check the __WXGTK__ case?


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=536845&aid=3576397&group_id=73133

------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
_______________________________________________
wxhaskell-devel mailing list
wxhaskell-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wxhaskell-devel

Reply via email to