在Windows 7 x64上, 我试过了:
1. install gtk+ all in one bundle 2.16
2. add MinGW's bin address to PATH Environment variables
3. add GTK+'s bin address to PATH Environment variables
在命令行上执行:
cabal update
cabal install gtk2hs-buildtools
到目前为止一切顺利。但是当我执行:
时cabal install gtk
出现错误
gtk-0.12.1取决于无法安装的glib-0.12.1。
我执行下一个命令:
cabal install glib
然后我尝试了:
cabal install glib --ghc-option=-DCABAL_VERSION_MINOR=10
Relults:
Resolving dependencies...
[1 of 2] Compiling SetupWrapper ( C:\Users\User\AppData\Local\Temp\glib-0.12
.16572\glib-0.12.1\SetupWrapper.hs, C:\Users\User\AppData\Local\Temp\glib-0.12.1
6572\glib-0.12.1\dist\setup\SetupWrapper.o )
[2 of 2] Compiling Main ( C:\Users\User\AppData\Local\Temp\glib-0.12
.16572\glib-0.12.1\Setup.hs, C:\Users\User\AppData\Local\Temp\glib-0.12.16572\gl
ib-0.12.1\dist\setup\Main.o )
Linking C:\Users\User\AppData\Local\Temp\glib-0.12.16572\glib-0.12.1\dist\setup\
setup.exe ...
Warning: .drectve `-aligncomm:___gmp_junk,2' unrecognized
cabal: Error: some packages failed to install:
glib-0.12.1 failed during the configure step. The exception was:
C:\Users\User\AppData\Local\Temp\glib-0.12.16572\glib-0.12.1\dist\setup\setup.exe:
runProcess: invalid argument (Exec format error)
帮助,谢谢!