wxHaskell installation on windows
I stuck at installing wxHaskell on windows xp sp3
I installed MinGW, MSYS and wx-config
MinGW and MSYS with installer
wx-config with adding the directory to environment variable WXWIN
and wxWigets with installer
when I type
cabal install wx
it says
generating: src/haskell/Graphics/UI/WXCore/WxcClassTypes.hs
reading class definitions:
parsing: src/include/wxc.h
parsing: src/include/wxc_types.h
parsing: src/include/wxc_glue.h
parsing: src/include/db.h
parsing: src/include/dragimage.h
parsing: src/include/graphicscontext.h
parsing: src/include/sound.h
parsing: src/include/managed.h
parsing: src/include/mediactrl.h
parsing: src/include/previewframe.h
parsing: src/include/printout.h
parsing: src/include/textstream.h
parsing: src/include/stc.h
parsing: src/include/stc_gen.h
generated 539 class definitions.
ok.
generating: src/haskell/Graphics/UI/WXCore/WxcClassInfo.hs
reading class definitions:
parsing: src/include/wxc.h
parsing: src/include/wxc_types.h
parsing: src/include/wxc_glue.h
parsing: src/include/db.h
parsing: src/include/dragimage.h
parsing: src/include/graphicscontext.h
parsing: src/include/sound.h
parsing: src/include/managed.h
parsing: src/include/mediactrl.h
parsing: src/include/previewframe.h
parsing: src/include/printout.h
parsing: src/include/textstream.h
parsing: src/include/stc.h
parsing: src/include/stc_gen.h
generated 381 class info definitions
ok.
parsing: src/include/wxc.h
parsing: src/include/wxc_types.h
parsing: src/include/wxc_glue.h
parsing: src/include/db.h
parsing: src/include/dragimage.h
parsing: src/include/graphicscontext.h
parsing: src/include/sound.h
parsing: src/include/managed.h
parsing: src/include/mediactrl.h
parsing: src/include/previewframe.h
parsing: src/include/printout.h
parsing: src/include/textstream.h
parsing: src/include/stc.h
parsing: src/include/stc_gen.h
ignore: parse error : //WXCOLORREF wxColour_GetPixel( TSelf(wxColour) _obj );
generating: src/haskell/Graphics/UI/WXCore/WxcClassesAL.hs
reading class definitions:
parsing: src/include/wxc.h
parsing: src/include/wxc_types.h
parsing: src/include/wxc_glue.h
parsing: src/include/db.h
parsing: src/include/dragimage.h
parsing: src/include/graphicscontext.h
parsing: src/include/sound.h
parsing: src/include/managed.h
parsing: src/include/mediactrl.h
parsing: src/include/previewframe.h
parsing: src/include/printout.h
parsing: src/include/textstream.h
parsing: src/include/stc.h
parsing: src/include/stc_gen.h
generated 1560 methods for 120 classes.
generating: src/haskell/Graphics/UI/WXCore/WxcClassesMZ.hs
generated 2184 methods for 123 classes.
generating: src/haskell/Graphics/UI/WXCore/WxcClasses.hs
generated 3744 total methods for 243 total classes.
ok.
parsing: src/eiffel/wx开发者_开发知识库c_defs.e
parsing: src/eiffel/wx_defs.e
parsing: src/eiffel/stc.e
generating: src/haskell/Graphics/UI/WXCore/WxcDefs.hs
generated 2454 constant definitions
ok.
Please use the --prefix flag (as in wx-config --prefix=C:\wxWidgets)
or set the environment variable WXWIN (as in WXWIN=C:\wxWidgets)
to specify where is your installation of wxWidgets.
setup.exe: failed
cabal: Error: some packages failed to install:
wx-0.12.1.6 depends on wxcore-0.12.1.6 which failed to install.
wxcore-0.12.1.6 failed during the configure step. The exception was:
ExitFailure 1
help~
thanks!
Do you have the wx-config.exe somewhere in your PATH environmnet variable, so that cabal can find it?
Additionally you might try to define the environment variable WXCFG=gcc_dll\mswu.
And as a last try: Did you compile wxWidgets with the correct settings (like so: mingw32-make -f makefile.gcc BUILD=release MONOLITHIC=1 SHARED=1 UNICODE=1
)?
That's all I got. I had similar issues, but I simply didn't follow the installation guide exactly, so maybe you missed something.
I think what you're missing in particular is the WXWIN environment variable specified by that error message. If you know how to set environment variables in Windows (I believe it involves the System Properties, but you can look that up online), set WXWIN to the wxWidgets directory, something like C:\wxWidgets-2.8
Then try cabal install wxcore
again
It may be helpful to have a look at this guide: http://www.haskell.org/haskellwiki/WxHaskell/Building
Note: I have not yet tried to build wxHaskell on Windows, but most other wxHaskell users seem to be on Windows, so I think it must be possible!
Edit: Sorry! I notice that you mention the WXWIN environment variable in your posting, so I'm not sure what exactly the issue is. It could be useful to echo %WXWIN% in cmd.exe to make sure it's set properly. Notice also that for some reason, you need to run cabal install wx in cmd.exe and not the msys shell
I found this was a bit troublesome, and after trying several suggestions from various web posts, got it to work. This may not be the optimal path, but after many permutations and gyrations, I was just glad to get it to work.
install wx-config - http://wiki.wxwidgets.org/Wx-Config - http://sites.google.com/site/wxconfig/
Install wxPack binary - http://wxpack.sourceforge.net/ - http://sourceforge.net/projects/wxpack/
install wxWidgets (Windows Binary) (included in wxPack)
copy wxmsw28u_gcc.dll
from: ../libraries/wxWidgets/lib/gcc_dll/
to : c:/windows/system
install wxhaskell - http://haskell.org/haskellwiki/WxHaskell - http://haskell.org/haskellwiki/WxHaskell/Download - http://downloads.sourceforge.net/wxhaskell/wxhaskell-bin-msw2.8.10-ghc6.10.4-0.11.1.2-0.zip
define the environment variable WXCFG=gcc_dll\mswu (and make sure that wxwin is on PATH)
cabal install wx wxcore
If using Leksah; also rebuild system data, and reconfigure and build project(s).
精彩评论