4

gloss is a nice library for graphics. The problem, is, when I run it in ghci, it closes ghci as soon as I exit. I tried using forkIO, but it still closes ghci after closing the window. How do I get gloss to not close ghci (or at least keep the history) or is it better to just use a file?

4

1 回答 1

0

正如网站所建议的那样(http://gloss.ouroborus.net/

A2: Try installing gloss to use the GLFW window manager 
interface instead of GLUT: cabal install gloss --flags="GLFW -GLUT"

我可以让它与 ghc-7.6.3 一起工作(在窗口中按 ESC 后,我回到 ghci)

但我无法为 ghc-7.8.4 编译它(因为 cabal 抱怨)

next goal: GLFW-b (dependency of gloss-1.9.2.1:+glfw)
rejecting: GLFW-b-1.4.7.2, 1.4.7.1, 1.4.7, 1.4.6, 1.4.5, 1.4.4, 1.4.3, 1.4.2,
1.4.1, 1.4, 1.3, 1.2.1, 1.2.0, 1.1.0, 1.0.2, 1.0.1, 1.0.0, 0.1.0.5, 0.1.0.4,
0.1.0.3, 0.1.0.2, 0.1.0.1, 0.1.0.0, 0.0.2.10, 0.0.2.9, 0.0.2.8, 0.0.2.7,
0.0.2.6, 0.0.2.5, 0.0.2.4, 0.0.2.3, 0.0.2.2, 0.0.2.1, 0.0.2, 0.0.1 (conflict:
gloss-1.9.2.1:glfw => GLFW-b>=0.1.4.1 && <0.2)
于 2015-04-01T09:40:03.713 回答