Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
I wrote: In the meantime, how about the following: In default non-verbose mode, silently memoize the list of packages that were not found. Then, only if something goes wrong, say something like: The package failed to build. Perhaps the reason is that one of the following packages was not found: Neil Mitchell wrote: That doesn't seem that helpful. On error, give a list of maybe 25 things that are missing, only to find out that you're running GHC 6.4.1 on Windows which no one ever tried before. It's not really narrowing the cause of the error too much anyway. Oh, I agree completely. Clearly it would be great if Cabal could process and report dependencies in a more meaningful way. However, if that will take more time before it can happen, I am just supporting what a few other people have already suggested in this thread as an easy first step. These do not require any change in the way Cabal processes things - just the way messages are printed. I am just combining a few things already said : o Verbose and non-verbose options. o Always show information if something really went wrong. o Include a message that may help people not to panic as much. -Yitz ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
On Sun, 2007-01-07 at 02:07 +, Ross Paterson wrote: On Sun, Jan 07, 2007 at 12:44:46PM +1100, Donald Bruce Stewart wrote: Those new to Cabal always seem to assume things are going badly when happy not found. We need to address the psychological aspect of Cabal's config process :) But it's not enough to just say Ignore any errors above. Some packages really do need happy (or some other tool) to build. Cabal would need to crawl over the source files to see what preprocessors are really needed. Yes, this is exactly what Cabal should do. We need to do this to make non-trivial pre-processors work properly anyway. We need to have Cabal do the import chasing and work out which tools will be necessary for the build. Duncan ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
On 07/01/07, Ross Paterson [EMAIL PROTECTED] wrote: But it's not enough to just say Ignore any errors above. Some packages really do need happy (or some other tool) to build. Cabal would need to crawl over the source files to see what preprocessors are really needed. Even if we said something like the following would be better: 'runhaskell Setup.hs build' to continue. The tools listed above as 'not found' may be required by the package; the build process will tell you if this is the case. We need _something_ there. More complex solutions will likely have their advantages, but _some_ solution is needed. -- -David House, [EMAIL PROTECTED] ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
Ross Paterson wrote: Cabal would need to crawl over the source files to see what preprocessors are really needed. Duncan Coutts wrote: Yes, this is exactly what Cabal should do. In the meantime, how about the following: In default non-verbose mode, silently memoize the list of packages that were not found. Then, only if something goes wrong, say something like: The package failed to build. Perhaps the reason is that one of the following packages was not found: In non-default verbose mode, behave as now. -Yitz ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
Hi In the meantime, how about the following: In default non-verbose mode, silently memoize the list of packages that were not found. Then, only if something goes wrong, say something like: The package failed to build. Perhaps the reason is that one of the following packages was not found: That doesn't seem that helpful. On error, give a list of maybe 25 things that are missing, only to find out that you're running GHC 6.4.1 on Windows which no one ever tried before. It's not really narrowing the cause of the error too much anyway. Something like scons does this much much better than Cabal does - it only complains if it finds something you need but don't have. For example, with Yhc you can compile the compiler with GHC, and the runtime with GCC/Visual Studio. Lacking half those dependancies won't give you an error message if you only try to do the right thing. Thanks Neil ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
Very, very helpful Chris; thanks; and thanks also to the many other helpful haskellers. They have (hopefully working) cabal files to make compiling and installing ea\ sy. Unfortunately, not so easy, for PCRE.regex. But hopefully this is just due to my ignorance and there's a simple workaround. At any rate, after darcs --getting as you suggested, I ran make, and got various complaints. I installed haddock, happy, alex, hat, c2hs, and cpphs with apt-get. But was unable to find a deb repository for greencard, the final requirement with apt-cache search. I then downloaded the latest version of greencard wget http://www.haskell.org/greencard/downloads/greencard-latest-src.tar.gz and ran sudo make install install-pkg It chugged along for a while, but finally errored out with ghc -package-name greencard -cpp -fglasgow-exts -fno-prune-tydecls -prof -c Foreign/GreenCard.hs -o Foreign/GreenCard.p_o -hisuf p_hi ghc-6.4.1: unrecognised flags: -fno-prune-tydecls I then googled, but found nothing for no-prune-tydecls or no-prune-typedecls (thinking it might be a typo) Anybody out there can help me get greencard working, so I (and all us perlers) can start using PCRE from haskell? thomas. Chris wrote: I think if you paste the subRegex code above underneath an import Text.Posix.PCRE declaration then you get what you are looking for. To install: The regex-* package hosting is via darcs and has been copied/moved to http://darcs.haskell.org/packages/ (The stable regex-* versions) http://darcs.haskell.org/packages/regex-unstable/ (The unstable regex-* vers\ ions) so darcs get --partial http://darcs.haskell.org/packages/regex-pcre; might b\ e useful. They have (hopefully working) cabal files to make compiling and installing ea\ sy. Note that regex-pcre and regex-tre need libpcre and libtre to be installed separately. regex-posix needs a posix library, but GHC already provides this package with a working libary. -- View this message in context: http://www.nabble.com/trivial-function-application-question-tf2922232.html#a8192328 Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
tphyahoo wrote: Very, very helpful Chris; thanks; and thanks also to the many other helpful haskellers. They have (hopefully working) cabal files to make compiling and installing ea\ sy. Unfortunately, not so easy, for PCRE.regex. But hopefully this is just due to my ignorance and there's a simple workaround. I think that it is simpler than you think. Cabal is confusing you. At any rate, after darcs --getting as you suggested, I ran make, and got various complaints. I installed haddock, happy, alex, hat, c2hs, and cpphs with apt-get. Well, the Makefile is just sugar for the Cabal Setup.hs file. Running --configure notices that many things are not installed, but this is just noise from Cabal. With my development directory I get this output from ./setup --configure: Configuring regex-pcre-0.80... configure: /usr/local/bin/ghc-pkg configure: Dependency base=2.0: using base-2.0 configure: Dependency regex-base-any: using regex-base-0.71 configure: Using install prefix: /usr/local configure: Binaries installed in: /usr/local/bin configure: Libraries installed in: /usr/local/lib/regex-pcre-0.80/ghc-6.6 configure: Private binaries installed in: /usr/local/libexec configure: Data files installed in: /usr/local/share/regex-pcre-0.80 configure: Using compiler: /usr/local/bin/ghc configure: Compiler flavor: GHC configure: Compiler version: 6.6 configure: Using package tool: /usr/local/bin/ghc-pkg configure: Using ar found on system at: /usr/bin/ar configure: Using haddock found on system at: /usr/local/bin/haddock configure: No pfesetup found configure: Using ranlib found on system at: /usr/bin/ranlib configure: Using runghc found on system at: /usr/local/bin/runghc configure: No runhugs found configure: No happy found configure: No alex found configure: Using hsc2hs: /usr/local/bin/hsc2hs configure: No c2hs found configure: No cpphs found configure: No greencard found This is sufficient to compile regex-pcre so long as you also have libpcre where ghc will find it. The main this is that it found ghc-6.6 and the hsc2hs and ghc-pkg that came with ghc. Specifically commands to run: make setup # this means Setup.hs is compiled once into setup for speed ./setup --configure -p --user --prefix=/where/you/want/it ./setup build ./setup install --user ./setup clean If you really want it to be global, then remove the --user and --prefix and install with sudo. Also, ./setup --help is useful. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
On 06/01/07, Chris Kuklewicz [EMAIL PROTECTED] wrote: Running --configure notices that many things are not installed, but this is just noise from Cabal. This is the second time I've seen someone get confused by these messages. I propose we add a 'Configuration successful, now type runhaskell Setup.hs build.' to the bottom of the configure output. -- -David House, [EMAIL PROTECTED] ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
dmhouse: On 06/01/07, Chris Kuklewicz [EMAIL PROTECTED] wrote: Running --configure notices that many things are not installed, but this is just noise from Cabal. This is the second time I've seen someone get confused by these messages. I propose we add a 'Configuration successful, now type runhaskell Setup.hs build.' to the bottom of the configure output. I agree. This issue is even mentioned here: www.serpentine.com/blog/2007/01/05/getting-started-with-installing-third-party-haskell-packages/ Those new to Cabal always seem to assume things are going badly when happy not found. We need to address the psychological aspect of Cabal's config process :) -- Don ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
On Sun, Jan 07, 2007 at 12:44:46PM +1100, Donald Bruce Stewart wrote: dmhouse: On 06/01/07, Chris Kuklewicz [EMAIL PROTECTED] wrote: Running --configure notices that many things are not installed, but this is just noise from Cabal. This is the second time I've seen someone get confused by these messages. I propose we add a 'Configuration successful, now type runhaskell Setup.hs build.' to the bottom of the configure output. I agree. This issue is even mentioned here: www.serpentine.com/blog/2007/01/05/getting-started-with-installing-third-party-haskell-packages/ Those new to Cabal always seem to assume things are going badly when happy not found. We need to address the psychological aspect of Cabal's config process :) But it's not enough to just say Ignore any errors above. Some packages really do need happy (or some other tool) to build. Cabal would need to crawl over the source files to see what preprocessors are really needed. (It does that in the build phase, but not configure.) If haddock is absent, you can build and install, but not build documentation. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
Donald Bruce Stewart writes: dmhouse: This is the second time I've seen someone get confused by these messages. I propose we add a 'Configuration successful, now type runhaskell Setup.hs build.' to the bottom of the configure output. I agree. This issue is even mentioned here: www.serpentine.com/blog/2007/01/05/getting-started-with-installing-third -party-haskell-packages/ Those new to Cabal always seem to assume things are going badly when happy not found. We need to address the psychological aspect of Cabal's config process :) Perhaps it would be better not to print the missing component messages by default. There could be a verbose option to turn them back on. -- David Menendez [EMAIL PROTECTED] | In this house, we obey the laws http://www.eyrie.org/~zednenem |of thermodynamics! ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] trouble installing greencard -- -fno-prune-tydecls flag ( was Re: trivial function application question )
Em Dom, 2007-01-07 às 02:07 +, Ross Paterson escreveu: On Sun, Jan 07, 2007 at 12:44:46PM +1100, Donald Bruce Stewart wrote: dmhouse: On 06/01/07, Chris Kuklewicz [EMAIL PROTECTED] wrote: Running --configure notices that many things are not installed, but this is just noise from Cabal. This is the second time I've seen someone get confused by these messages. I propose we add a 'Configuration successful, now type runhaskell Setup.hs build.' to the bottom of the configure output. I agree. This issue is even mentioned here: www.serpentine.com/blog/2007/01/05/getting-started-with-installing-third-party-haskell-packages/ Those new to Cabal always seem to assume things are going badly when happy not found. We need to address the psychological aspect of Cabal's config process :) But it's not enough to just say Ignore any errors above. Some packages really do need happy (or some other tool) to build. Cabal would need to crawl over the source files to see what preprocessors are really needed. (It does that in the build phase, but not configure.) If haddock is absent, you can build and install, but not build documentation. Maybe if in the Cabal file was specified what's needed for compiling the package, this would not happen. -- malebria Marco Túlio Gontijo e Silva Correio (MSN): [EMAIL PROTECTED] Jabber (GTalk): [EMAIL PROTECTED] Telefone: 33346720 Celular: 98116720 Endereço: Rua Paula Cândido, 257/201 Gutierrez 30430-260 Belo Horizonte/MG Brasil ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe