Re: [Haskell-cafe] Building Yi (and wider Cabal stuff)
On 18 jun 2007, at 18.31, Jaap Weel wrote: If you want to install into a nonstandard directory, do runhaskell Setup.hs configure --prefix /bla/di/bla Are you sure this works? I think it is important that there be no whitespace between flag and parameter: runhaskell Setup.hs configure --prefix=/bla/di/bla / Thomas ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Building Yi (and wider Cabal stuff)
On Sunday 17 June 2007 08:26:45 Michael T. Richter wrote: I'm trying to build Yi (from the darcs repository) to take a look at it. The README that comes with it says it's a standard Cabal project so do what you normally do (paraphrased slightly). GNU autotools comes with a standard boilerplate INSTALL file to include with your projects. There is some command you run in the process of autoconfiscation that inserts it automatically. Maybe there should be a standard boilerplate INSTALL file to be included with Cabal packages. Yesterday, I wrote and uploaded a simple Cabal package called csv (mostly as an exercise, since it's only a screenful of code, really, but it is actually a somewhat useful library because it saves you the trouble of reading an RFC). I included the following INSTALL file: To install the package, use the standard Cabal incantations: runhaskell Setup.hs configure runhaskell Setup.hs build runhaskell Setup.hs install If you want to install into a nonstandard directory, do runhaskell Setup.hs configure --prefix /bla/di/bla If you want documentation, try runhaskell Setup.hs haddock I think that simply adding those instructions would probably lower the hurdle a bit. Maybe the Cabal could look into automatically inserting an instructions file like that if it doesn't exist yet. Another idea for making things more accessible is to include a shell script called configure and a Makefile called Makefile, both of which just print the above instructions when executed. /jaap ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] Building Yi (and wider Cabal stuff)
I'm trying to build Yi (from the darcs repository) to take a look at it. The README that comes with it says it's a standard Cabal project so do what you normally do (paraphrased slightly). The problem is that I'm not a cabal user just yet and have no idea where to go from here. Just throwing caution to the wind and typing make built a setup program which was then executed and failed complaining about not having yi-lib0.3 (which I kind of thought the project should be building for me) and such. Editing the config.mk (which has some options left almost entirely undocumented) got me a step farther (specifically giving it a prefix that actually existed), but then had it choking out that it couldn't find the vty library -- even when I specifically told it to build the gtk version. Is there some painfully obvious thing I'm missing in trying to build this? And is it something that's applicable in the broader Cabal world or is it just this project? Compiling GHC (which is a lot bigger and more complex, I'd have guessed) was painless in comparison, so I'm kind of in the dark here. -- Michael T. Richter [EMAIL PROTECTED] (GoogleTalk: [EMAIL PROTECTED]) If there's one thing that computers do well, it's to make the same mistake uncountable times at inhuman speed. (Peter Coffee) signature.asc Description: This is a digitally signed message part ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Building Yi (and wider Cabal stuff)
I'm trying to build Yi (from the darcs repository) to take a look at it. The README that comes with it says it's a standard Cabal project so do what you normally do (paraphrased slightly). The problem is that I'm not a cabal user just yet and have no idea where to go from here. The standard cabal usage is: runhaskell Setup.hs configure runhaskell Setup.hs build runhaskell Setup.hs install http://www.haskell.org/haskellwiki/How_to_install_a_Cabal_package Alistair ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Building Yi (and wider Cabal stuff)
Michael T. Richter: I'm trying to build Yi (from the darcs repository) to take a look at it. I tried that, too, and it seems to me that if you use a different GHC version than the developers have, you're very likely to be struck. (Now how will I know what version they use?) The README that comes with it says it's a standard Cabal project so do what you normally do (paraphrased slightly). That seems to be a README bug. The following steps seem to be necessary: cd packages/yi-lib/ runghc Setup.hs configure runghc Setup.hs build sudo runghc Setup.hs install cd ../.. runghc Setup.hs configure runghc Setup.hs build You will need specific filepath and Vty libraries, as stated in the Readme. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Building Yi (and wider Cabal stuff)
On Sun, 2007-17-06 at 08:18 +0100, Alistair Bayley wrote: I'm trying to build Yi (from the darcs repository) to take a look at it. The README that comes with it says it's a standard Cabal project so do what you normally do (paraphrased slightly). The problem is that I'm not a cabal user just yet and have no idea where to go from here. The standard cabal usage is: runhaskell Setup.hs configure runhaskell Setup.hs build runhaskell Setup.hs install http://www.haskell.org/haskellwiki/How_to_install_a_Cabal_package Alistair I eventually hit that Wiki and still had no joy. On a clean darcs get: ---8--- $ runhaskell Setup.hs build /usr/local/share/yi-0.3 Preprocessing executables for yi-0.3... Building yi-0.3... [1 of 4] Compiling Yi.Kernel( Yi/Kernel.hs, dist/build/yi/yi-tmp/Yi/Kernel.o ) [2 of 4] Compiling Yi.Debug ( Yi/Debug.hs, dist/build/yi/yi-tmp/Yi/Debug.o ) [3 of 4] Compiling Yi.Boot ( Yi/Boot.hs, dist/build/yi/yi-tmp/Yi/Boot.o ) [4 of 4] Compiling Main ( Main.hs, dist/build/yi/yi-tmp/Main.o ) Linking dist/build/yi/yi ... Precompiling vty Yi/Vty.hs:10:7: Could not find module `Graphics.Vty': Use -v to see a list of the files searched for. Precompile of vty failed. Install the corresponding library if needed. Precompiling gtk Yi/Vty.hs:10:7: Could not find module `Graphics.Vty': Use -v to see a list of the files searched for. Precompile of gtk failed. Install the corresponding library if needed. ---8--- Now I know that gtk is installed, given that I'm able to build gtk2hs (or at least was able to -- I haven't tried it with GHC 6.6.1 yet). I have no idea what Vty is, so I don't know how to solve this problem. I am interested in why the gtk build is looking for what appears to be a console library, however. Any further guidance? -- Michael T. Richter [EMAIL PROTECTED] (GoogleTalk: [EMAIL PROTECTED]) Experts in advanced countries underestimate by a factor of two to four the ability of people in underdeveloped countries to do anything technical. (Charles P Issawi) signature.asc Description: This is a digitally signed message part ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Building Yi (and wider Cabal stuff)
OK, got the builds to work. I did, in fact, have to go two layers down to build yi-lib and install it before building yi proper. (I think this needs to be updated in the docs or repaired, whichever is appropriate.) So, I have a Yi build. I type Yi and it... dies. It complains about not having a YiConfig.hs and suggests something to read. (I like this touch, actually.) And, unlike, say, emacs, it tells you how to exit. So I copy the examples/YiConfig.hs to ~/.yi and try again. I'll let the console speak for itself: /home/michael/.yi/YiConfig.hs:15:2: Couldn't match expected type `GHC.IOBase.IORef Editor' ^I against inferred type `Yi' Expected type: Control.Monad.Reader.ReaderT (GHC.IOBase.IORef Editor) ^I^I^I^I^I^I IO ^I^I^I^I^I^I t Inferred type: Action In the expression: changeKeymapE myKeymap In a 'do' expression: changeKeymapE myKeymap This is the stock YiConfig.hs left completely untouched and boilerplate. What's the next step? (Running yi --as=whatever doesn't help either. Same errors.) -- Michael T. Richter [EMAIL PROTECTED] (GoogleTalk: [EMAIL PROTECTED]) Our outrage at China notwithstanding, we should remember that before 1891 the copyrights of foreigners were not protected in the United States. (Lawrence Lessig) signature.asc Description: This is a digitally signed message part ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe