From: Brian L. <br...@lo...> - 2009-08-09 20:29:14
|
I think it'd be good to replace the darcs wxhaskell/makefile with wxhaskell.cabal, if possible. One of the first things the makefile does is build wxdirect, so I split it off and cleaned it up a little bit: http://github.com/bsl/wxdirect/tree/master . It could be put on HDB. My intention is that later it will be in the wxhaskell.cabal build-depends. |
From: Eric Y. K. <eri...@gm...> - 2009-08-09 21:25:27
|
On Sun, Aug 09, 2009 at 15:29:29 -0500, Brian Lewis wrote: > One of the first things the makefile does is build wxdirect, so I split > it off and cleaned it up a little bit: > http://github.com/bsl/wxdirect/tree/master . It could be put on HDB. Looks good to me. And now that we have that little stub library, we can just go ahead and depend on it. It may also be useful in the long run when people start writing their own Haskell wrappers around 3rd party widgets. I've darcs sent a patch to remove the WXD building and to depend on this wxdirect package... perhaps prematurely. Apologies if this is depriving you of that popping bubble wrap satisfaction that comes with getting rid of stuff :-) -- Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow> PGP Key ID: 08AC04F9 |
From: Brian L. <br...@lo...> - 2009-08-11 00:50:13
|
I made a repo with wxcore and wxc together and tried to make a wxcore.cabal that would replace the existing makefile: http://github.com/bsl/wxcore/tree/master It doesn't build completely for me, but maybe it's a start. |
From: Eric Y. K. <eri...@gm...> - 2009-08-11 01:05:24
|
On Mon, Aug 10, 2009 at 19:50:31 -0500, Brian Lewis wrote: > I made a repo with wxcore and wxc together and tried to make a > wxcore.cabal that would replace the existing makefile: > http://github.com/bsl/wxcore/tree/master I get setup: Missing dependency on a foreign library: * Missing C library: wx_macud-2.8 This problem can usually be solved by installing the system package that provides this library (you may need the "-dev" version). If the library is already installed but in a non-standard location then you can use the flags --extra-include-dirs= and --extra-lib-dirs= to specify where it is. I guess the Setup.hs file needs to call wx-config PS: it might simplify matters for the wxHaskell team if you just used the darcs repository, for example hosting it on code.haskell.org if you have an account there or patch-tag.com otherwise, unless you're hoping that they'll just switch to Git and sacrifice log history, which isn't implausible, do-er decides. -- Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow> PGP Key ID: 08AC04F9 |
From: Brian L. <br...@lo...> - 2009-08-11 20:08:38
|
On Tuesday, 11.08.09 at 02:05, Eric Y. Kow wrote: > setup: Missing dependency on a foreign library: > * Missing C library: wx_macud-2.8 > > I guess the Setup.hs file needs to call wx-config Hmm. But it does. Does 'wx-config --cppflags --libs' show the stuff it should? Where is the build failing for you? > PS: it might simplify matters for the wxHaskell team if you just used > the darcs repository I'll definitely do whatever's most convenient for them if this stuff turns out to be useful at all. Right now the build fails for me with errors like src/cpp/eljfl.cpp:1277:0: error: conversion from ‘char*’ to ‘const wxString’ is ambiguous src/cpp/eljfl.cpp:1317:0: error: no matching function for call to ‘wxNewBitmapButton::RenderLabelImage(wxBitmap*, wxBitmap*, bool, bool)’ |
From: Eric Y. K. <eri...@gm...> - 2009-08-11 20:26:14
|
On Tue, Aug 11, 2009 at 15:08:53 -0500, Brian Lewis wrote: > On Tuesday, 11.08.09 at 02:05, Eric Y. Kow wrote: > > setup: Missing dependency on a foreign library: > > * Missing C library: wx_macud-2.8 > > > > I guess the Setup.hs file needs to call wx-config > > Hmm. But it does. Does 'wx-config --cppflags --libs' show the stuff it > should? Where is the build failing for you? Yeah, sorry for the noise there. The error (at first) was due to using the wrong version of wx-config (the one that came with my Mac). Running PATH=/usr/local/wxhaskell/bin/wx-config cabal install Then got me a similar failure, which was due to not parsing the -framework flags (hence my attempt at making up for my noise by submitting a patch) Anyway, I'm pretty excited about this! I was so fixated on splitting wxc off from wxcore that it never occurred to me to try the other way by just building the darned wxc code within Cabal. Somehow I imagined that wxc being C++ would be a problem. In the long run, wxc is going to have to go away anyway and be replaced by some autogenerated wrapper so I think you've got exactly the right idea: just make it work first. > > PS: it might simplify matters for the wxHaskell team if you just used > > the darcs repository > > I'll definitely do whatever's most convenient for them if this stuff > turns out to be useful at all. Nod. Hopefully somebody from the team will notice :-) They seem a bit busy right now. > Right now the build fails for me with errors like > > src/cpp/eljfl.cpp:1277:0: > error: conversion from ‘char*’ to ‘const wxString’ is ambiguous Perhaps your wxWidgets is not Unicode enabled? I think you have to pass that in as a flag to configure. It may be good to also make sure that you're --unicode=yes to wx-config as well, although I'm not sure what it does. Finally, this is a good chance to get a configure-time check for a Unicode-enabled wxWidgets > src/cpp/eljfl.cpp:1317:0: > error: no matching function for call to > ‘wxNewBitmapButton::RenderLabelImage(wxBitmap*, wxBitmap*, bool, bool)’ Not sure what's going on there :-( Here are my last three errors: src/cpp/eljdialup.cpp:97:0: error: ‘wxDialUpEvent’ was not declared in this scope src/cpp/eljdialup.cpp:97:0: error: ‘self’ was not declared in this scope src/cpp/eljdialup.cpp:98:0: error: expected ‘,’ or ‘;’ before ‘{’ token -- Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow> PGP Key ID: 08AC04F9 |
From: Brian L. <br...@lo...> - 2009-08-11 20:12:42
|
On Tuesday, 11.08.09 at 15:08, Brian Lewis wrote: > src/cpp/eljfl.cpp:1277:0: > error: conversion from ‘char*’ to ‘const wxString’ is ambiguous http://wiki.wxwidgets.org/WxString |
From: Brian L. <br...@lo...> - 2009-08-11 20:48:16
|
On Tuesday, 11.08.09 at 15:13, Brian Lewis wrote: > On Tuesday, 11.08.09 at 15:08, Brian Lewis wrote: > > src/cpp/eljfl.cpp:1277:0: > > error: conversion from ‘char*’ to ‘const wxString’ is ambiguous > > http://wiki.wxwidgets.org/WxString I pushed some stuff to the github repo that resolved these errors for me. |
From: Eric Y. K. <eri...@gm...> - 2009-08-11 22:28:02
|
On Tue, Aug 11, 2009 at 15:48:45 -0500, Brian Lewis wrote: > > http://wiki.wxwidgets.org/WxString > > I pushed some stuff to the github repo that resolved these errors for me. I've also pushed some stuff removing wxc modules which I think wxHaskell does not support (I based this on ls dist/wxc/*.o) Now I'm getting errors like the below. I think in the old configure script and makefile we had to pass in special flags for glcanvas, but I could be wrong. If this is the case, it might be a good idea if we just went for a barebones build in the beginning and only then thought about how to extend this. (Maybe even separate packages; it would be nice to see if a wxHaskell-extras using wxdirect could work). from src/cpp/glcanvas.cpp:2:0: /usr/lib/gcc/i686-apple-darwin9/4.0.1/include/xmmintrin.h:35:3: error: #error "SSE instruction set not enabled" /usr/include/wx-2.8/wx/fontdlg.h: In constructor ‘wxFontDialogBase::wxFontDialogBase(wxWindow*, const wxFontData*)’: /usr/include/wx-2.8/wx/fontdlg.h:67:0: warning: ‘__base_ctor ’ is deprecated (declared at /usr/include/wx-2.8/wx/fontdlg.h:66) /System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/MachineExceptions.h: At global scope: /System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/MachineExceptions.h:216:0: error: ‘__m128’ does not name a type /System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/MachineExceptions.h:217:0: error: ‘__m128i’ does not name a type /System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/MachineExceptions.h:218:0: error: ‘__m128d’ does not name a type /usr/include/wx-2.8/wx/mac/carbon/glcanvas.h:49:0: warning: ‘AGLDrawable’ is deprecated (declared at /System/Library/Frameworks/AGL.framework/Headers/agl.h:61) /usr/include/wx-2.8/wx/mac/carbon/glcanvas.h:53:0: warning: ‘AGLDrawable’ is deprecated (declared at /System/Library/Frameworks/AGL.framework/Headers/agl.h:61) -- Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow> PGP Key ID: 08AC04F9 |
From: Brian L. <br...@lo...> - 2009-08-11 22:48:09
|
On Tuesday, 11.08.09 at 23:27, Eric Y. Kow wrote: > I've also pushed some stuff removing wxc modules which I think wxHaskell > does not support (I based this on ls dist/wxc/*.o) OK, thank you. I'll check that out. I just pushed stuff that causes wxcore to actually install for me in Linux. No idea if it works yet. |
From: Brian L. <br...@lo...> - 2009-08-12 01:02:57
|
On Tuesday, 11.08.09 at 23:27, Eric Y. Kow wrote: > Now I'm getting errors like the below. I think in the old configure > script and makefile we had to pass in special flags for glcanvas, > but I could be wrong. You might try adding ["-DwxcREFUSE_OPENGL", "-DwxcREFUSE_MEDIACTRL"] to your cppOptions. |
From: Brian L. <br...@lo...> - 2009-08-12 01:25:07
|
On Tuesday, 11.08.09 at 20:03, Brian Lewis wrote: > You might try adding > ["-DwxcREFUSE_OPENGL", "-DwxcREFUSE_MEDIACTRL"] > to your cppOptions. Sorry, I meant 'ccOptions'. After I did that, I was able to do 'ghc --make BouncingBalls.hs' in samples/wx, and it ran OK. |
From: Eric K. <eri...@gm...> - 2009-08-12 09:44:49
|
On Tue, Aug 11, 2009 at 20:25:29 -0500, Brian Lewis wrote: > On Tuesday, 11.08.09 at 20:03, Brian Lewis wrote: > > You might try adding > > ["-DwxcREFUSE_OPENGL", "-DwxcREFUSE_MEDIACTRL"] > > to your cppOptions. > > Sorry, I meant 'ccOptions'. It sounds like there should be a -fopengl and -fmediactrl in the Cabal file which are off by default. > After I did that, I was able to do 'ghc --make BouncingBalls.hs' in > samples/wx, and it ran OK. Woo! That's very encouraging progress. I'll try GenI out later when I get a chance (some software I have that depends on wxHaskell for its GUI). Thanks! -- Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow> PGP Key ID: 08AC04F9 |