5

I've already downloaded the Haskell platform and I've been using ghci with no problem, but that's about it. I need to use the SOE graphics files, and I downloaded the files (I think it was tar.gz) but wherever I look, the instructions for Windows seem to skip steps or not work. I can't get cabal to work (never in scope) even after I moved it from a buried folder to the bin where ghci lives. Same for OpenGL or GLFW or whatever it's called.

I need clear step by step instructions for my desktop (Win XP SP2) and my laptop (Win 7). If you point me to an existing page, I've probably been there and tried to follow the instructions without success. See if you can clarify the process.

Please talk to me as if I am a moron. If you're telling me to type something, I need to know where I'm typing it. If I need to download a file, tell me what folder it belongs in. Please.

First: Should I uninstall everything I've already downloaded to start fresh, and if so, do I just delete the files or must I get into the registry?


I've actually made some progress. I got cabal to install GLFW. I typed -i./SOE/src and I got the right result. Then I went to :load Draw.lhs and got

Compiling SOE ( SOE.hs, interpreted )

SOE.hs:136:31: Couldn't match expected type 'Bool' with actual type '()' Expected type: GLFW.WindowCloseCallback Actual type: IO () In the return type of a call of 'closeWindow_' In the second argument of '($=)', namely 'closeWindow_ eventsChan' Failed, modules loaded: none

????? I just want to clarify, I didn't do anything to the SOE.hs file myself.

6
  • Not serious: 1. download the latest ubuntu or openSuSe release 2. burn install dvd 3. wipe and install ... serious: if the cabal coming with the Haskell platform doesn't work, that's a bad sign. I would first try to get that fixed and care about graphics libraries thereafter. Unfortunately I can't help you fixing it, since my knowledge of Windows is minuscule. Jan 31, 2012 at 19:22
  • 1
    Also not a Windows expert, but if cabal isn't in scope, that usually means you need to fix your PATH. Moving executables from where they expect to be is almost certainly a bad idea.
    – hammar
    Jan 31, 2012 at 19:31
  • The cabal.exe file was buried in a folder under lib, something like "other" and when it didn't work there, and I read somewhere it has to be in the path, I took to mean that if cabal.exe were in the same folder as ghci.exe it couldn't possibly not be in the path, so I moved it there. How do I fix my path?
    – punstress
    Jan 31, 2012 at 21:53
  • This page haskell.org/haskellwiki/Cabal-Install#Windows says to put it in C:\Program Files\Haskell\bin Jan 31, 2012 at 22:40
  • Right! So why wouldn't it be in the path? I saw elsewhere to put something like -i.\SoeGraphics to put it in the path but I got another error message.
    – punstress
    Jan 31, 2012 at 23:06

1 Answer 1

2

When you say that cabal doesn't work for you because it is "not in scope", it sounds like you are trying to run cabal from inside GHCi (because the error message there would be Not in scope: 'cabal').

Cabal is a completely separate program, which you need to run from the Windows command prompt. If it doesn't work from there, I'd suggest uninstalling and then reinstalling the Haskell platform (especially if you have moved files around manually). The Haskell Platform installer should always add the cabal command to your path (although you need to reopen any command prompt windows to use the updated path).

You absolutely do not need to move any executable files to different folders or anything like that (I've used the Haskell Platform under Windows XP, Windows Vista and Windows 7).

6
  • You are right, Shang, I was trying to use it inside GHCI. I'm not at my computer now but hopefully your advice works.
    – punstress
    Feb 2, 2012 at 15:27
  • I tried following the instructions at cs.yale.edu/homes/hudak/SOE/software1.htm.
    – punstress
    Feb 6, 2012 at 8:46
  • The screen was too large to paste here so I edited my original question.
    – punstress
    Feb 6, 2012 at 8:52
  • How do I uninstall the Haskell platform? Just delete the folder? There's no uninstall program that I can see.
    – punstress
    Feb 6, 2012 at 8:53
  • I'm not at a Windows machine at the moment, so I can't check the details, but I think there should be an uninstall options if you go to Control Panel (via the Windows Start menu) and then choose Add/Remove Programs. Look for Haskell Platform in the program list there. If Haskell Platform is not listed there, you can try manually deleting the folder and reinstalling.
    – shang
    Feb 6, 2012 at 9:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.