2017-05-29 73 views
1

我一直在試圖安裝與陰謀gtk3安裝gtk3,在https://wiki.haskell.org/Gtk2Hs/Installation下面的說明,只是我有更換gtk3 GTK安裝在Windows上巧舌如簧,我下載了GTK 3.6的都在同一個包1.4(來源:http://www.tarnyko.net/dl/gtk.htm)將它解壓縮,並添加location_of_files/bin添加到我的路徑,運行pkg配置--cflags GTK + -3.0工作正常,小集團安裝gtk2hs,編譯工具安裝正確,但小集團安裝gtk3與停止:廣東話當試圖用陰謀

Resolving dependencies... 
Configuring glib-0.13.4.1... 
Failed to install glib-0.13.4.1 
Build log (C:\Users\User\AppData\Roaming\cabal\logs\glib-0.13.4.1.log): 
cabal: Entering directory 'C:\Users\User\AppData\Local\Temp\cabal-tmp-6472\glib-0.13.4.1' 
[1 of 1] Compiling Main    (C:\Users\User\AppData\Local\Temp\cabal-tmp-6472\glib-0.13.4.1\dist\setup\setup.hs, C:\Users\User\AppData\Local\Temp\cabal-tmp-6472\glib-0.13.4.1\dist\setup\Main.o) 
Linking C:\Users\User\AppData\Local\Temp\cabal-tmp-6472\glib-0.13.4.1\dist\setup\setup.exe ... 
Configuring glib-0.13.4.1... 
setup.exe: Missing dependency on a foreign library: 
* Missing C library: intl 
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. 
cabal: Leaving directory 'C:\Users\User\AppData\Local\Temp\cabal-tmp-6472\glib-0.13.4.1' 

我下載的gtk包在include文件夾中有一個libintl.h文件,在bin文件夾中有一個dll,我試着將文件放在幾乎所有我能想到的位置,但無濟於事,ic別想別的了。

更多細節:我使用haskell-platform 8.0.2 x64運行windows 7 x64,而且我真的需要這個在Windows下爲我正在工作的項目工作。

+0

該庫是gettext的一部分(https://www.gnu.org/software/gettext/gettext.html),您可以嘗試安裝gettext以確保它可以正常工作,並滿足其所有依賴關係。 – Davislor

+0

另請參閱:https://stackoverflow.com/questions/32662215/how-do-you-install-gtk-3-0-on-windows – Davislor

回答

1

我按照https://www.gtk.org/download/windows.php中的說明安裝gtk,安裝MSYS2並使用pacman安裝gtk庫,忽略了第4步。我安裝了添加到我的路徑C:\ msys64 \ mingw64 \ bin的庫後, cabal終於編譯了gtk3。 我不喜歡這個解決方案,因爲它是我的電腦上安裝的另一個mingw。

+0

我認爲你可以重新使用現有的MSYS2安裝,並安裝丟失包。 – liberforce