Difference between revisions of "WxHaskell/Installation tips"
m (WxHaskell installation tips moved to WxHaskell/Installation tips) |
BrettGiles (talk | contribs) m (Fix spelling of wxHaskell, wxWidgets) |
||
Line 3: | Line 3: | ||
# For Debian Linux systems (as long as there's no .deb package): |
# For Debian Linux systems (as long as there's no .deb package): |
||
#* Fetch the rpm package from http://wxhaskell.sourceforge.net/download.html |
#* Fetch the rpm package from http://wxhaskell.sourceforge.net/download.html |
||
− | #* make sure you have |
+ | #* make sure you have wxWidgets installed (libraries and developer files) |
#* if you haven't done this already, install the debian package "alien": apt-get install alien |
#* if you haven't done this already, install the debian package "alien": apt-get install alien |
||
#* use alien to install the rpm package: alien -i wxhaskell....rpm |
#* use alien to install the rpm package: alien -i wxhaskell....rpm |
||
Line 18: | Line 18: | ||
== MacOS X == |
== MacOS X == |
||
− | Getting |
+ | Getting wxHaskell 0.9.4 to work with wxWidgets 2.6 on Panther (10.3). |
* install wxWidgets for mac, wxmac http://www.wxwidgets.com |
* install wxWidgets for mac, wxmac http://www.wxwidgets.com |
||
** use the --disable-shared option for configure (this isn't needed in all cases?)<br><code>./configure --disable-shared</code> |
** use the --disable-shared option for configure (this isn't needed in all cases?)<br><code>./configure --disable-shared</code> |
||
* Make sure you have readline installed. The simplest way is to use fink or darwinports. http://wxhaskell.sourceforge.net/building-macosx.html |
* Make sure you have readline installed. The simplest way is to use fink or darwinports. http://wxhaskell.sourceforge.net/building-macosx.html |
||
− | * grab and install [[ |
+ | * grab and install [[wxHaskell]] |
* (unique to macosx!)<br><code>sudo ln -s /usr/local/wxhaskell/bin/macosx-app /usr/local/bin/</code> |
* (unique to macosx!)<br><code>sudo ln -s /usr/local/wxhaskell/bin/macosx-app /usr/local/bin/</code> |
||
* See below if you have any trouble |
* See below if you have any trouble |
||
Line 29: | Line 29: | ||
Unknown: |
Unknown: |
||
− | * Does the darwinports version of |
+ | * Does the darwinports version of wxWidgets work with wxHaskell? Would be nice if somebody made a portfile for it. |
== Errors == |
== Errors == |
||
− | * Problems compiling |
+ | * Problems compiling wxHaskell (something like the below)<br /><code>/tmp/ghc29861.s:4379: Unknown pseudo-op:<br />.subsections_via_symbol</code><br />Make sure you have at least Xcode 1.5 (gcc 3.3 build 1671). Xcode 1.1 (gcc build 1495) is not enough |
* If you get linker errors like it not being able to find _TextziParserCombinatorsziParsecziChar_alphaNum_closure, try editing config/config.mk and setting HC=ghc -lHSparsec. This is likely not a mac-specific problem but related to the use of GHC 6.2 over 6.0.1. (not sure if this is still valid) |
* If you get linker errors like it not being able to find _TextziParserCombinatorsziParsecziChar_alphaNum_closure, try editing config/config.mk and setting HC=ghc -lHSparsec. This is likely not a mac-specific problem but related to the use of GHC 6.2 over 6.0.1. (not sure if this is still valid) |
||
* When compiling your Haskell program:<br /><code>ld: /usr/lib/crt1.o illegal reference to symbol: __objcInit defined in indirectly referenced dynamic library /usr/lib/libobjc.A.dylib</code> |
* When compiling your Haskell program:<br /><code>ld: /usr/lib/crt1.o illegal reference to symbol: __objcInit defined in indirectly referenced dynamic library /usr/lib/libobjc.A.dylib</code> |
||
Line 39: | Line 39: | ||
* Certain buttons and widgets are not active |
* Certain buttons and widgets are not active |
||
− | The last point is possibly a |
+ | The last point is possibly a wxWidgets or a wxHaskell bug - basically, widgets in "boxed" environments do not react to user. Take out the box, and you're ok. |
== Windows == |
== Windows == |
Revision as of 16:00, 21 February 2006
Debian
- For Debian Linux systems (as long as there's no .deb package):
- Fetch the rpm package from http://wxhaskell.sourceforge.net/download.html
- make sure you have wxWidgets installed (libraries and developer files)
- if you haven't done this already, install the debian package "alien": apt-get install alien
- use alien to install the rpm package: alien -i wxhaskell....rpm
- use ghc-pkg to add the packages wxcore and wx to ghc's package configuration file:
cd /usr/lib/ghc-6.2.1/wxhaskell-0.7
ghc-pkg -D wxhlibdir=/usr/lib/ghc-6.2.1/wxhaskell-0.7 -ai wxcore.pkg
ghc-pkg -D wxhlibdir=/usr/lib/ghc-6.2.1/wxhaskell-0.7 -ai wx.pkg
- Another way for Debian systems:
use the repository "deb http://haskell-unsafe.alioth.debian.org/archive/i386 unstable ." - A way that surely works:
- Fetch the two deb packages on http://haskell-unsafe.alioth.debian.org/archive/i386/unstable/w/wxhaskell/
- apt-get install libwxgtk2.5-dev
- dpkg -i [name], where name is the name of the two packages, you should first install the normal package and then the dev-package
wxhlibdir=/usr/lib ghc-pkg -ai /usr/lib/wxcore.pkg
wxhlibdir=/usr/lib ghc-pkg -ai /usr/lib/wx.pkg
MacOS X
Getting wxHaskell 0.9.4 to work with wxWidgets 2.6 on Panther (10.3).
- install wxWidgets for mac, wxmac http://www.wxwidgets.com
- use the --disable-shared option for configure (this isn't needed in all cases?)
./configure --disable-shared
- use the --disable-shared option for configure (this isn't needed in all cases?)
- Make sure you have readline installed. The simplest way is to use fink or darwinports. http://wxhaskell.sourceforge.net/building-macosx.html
- grab and install wxHaskell
- (unique to macosx!)
sudo ln -s /usr/local/wxhaskell/bin/macosx-app /usr/local/bin/
- See below if you have any trouble
Unknown:
- Does the darwinports version of wxWidgets work with wxHaskell? Would be nice if somebody made a portfile for it.
Errors
- Problems compiling wxHaskell (something like the below)
/tmp/ghc29861.s:4379: Unknown pseudo-op:
.subsections_via_symbol
Make sure you have at least Xcode 1.5 (gcc 3.3 build 1671). Xcode 1.1 (gcc build 1495) is not enough - If you get linker errors like it not being able to find _TextziParserCombinatorsziParsecziChar_alphaNum_closure, try editing config/config.mk and setting HC=ghc -lHSparsec. This is likely not a mac-specific problem but related to the use of GHC 6.2 over 6.0.1. (not sure if this is still valid)
- When compiling your Haskell program:
ld: /usr/lib/crt1.o illegal reference to symbol: __objcInit defined in indirectly referenced dynamic library /usr/lib/libobjc.A.dylib
- Adding -framework AppKit to the compiler switches for your Haskell program seems to help
- Certain buttons and widgets are not active
The last point is possibly a wxWidgets or a wxHaskell bug - basically, widgets in "boxed" environments do not react to user. Take out the box, and you're ok.
Windows
Installing wxHaskell is easy once you realize that the batch file (wxhaskell-register.bat) only works from folders with no spaces anywhere in the address, e.g. double clicking C:\Cygwin\wxhaskell-0.9.4\bin\wxhaskell-register.bat works but if you put the files under C:\Documents and Settings\wxhaskell-0.9.4\... or C:\Program Files\wxhaskell-0.9.4\... it might not work. Just move the installer folder wxhaskell-0.9.4 to somewhere with no spaces in the address and double-click wxhaskell-register.bat. I hope this helps someone.