Hi, Am Mittwoch, den 12.09.2012, 09:54 +0900 schrieb Kiwamu Okabe: > The reason is for my own taste. > But I agree your point that say "some people will install hoogle without ghc". > New debian/rules compiles haddock_collect.hs with command > "ghc -Wall -O haddock_collect.hs; strip haddock_collect". > And haddock_collect binary is more fast than haddock_collect.hs. good. > > Why does it depend on haskell-platform? Can’t I use it to just search > > the packages that I happen to have installed? > > Because haddock_collect.hs use Codec.Compression.GZip. > But the depend isn't needed, because haddock_collect.hs is installed > with compile now. Good. Even if you did not compile it, you should use minimal Depends. haskell-platform is a convenience package for users, but not something that should be used as a Depends or Build-Depends. > > Have you tested your update-hoogle script on a system with no > > libghc-*-doc package installed (I expect at least an ugly error). > > I think the problem is only for error message. > How about below patch. > > ----------- > diff -rN -u old-debian/files_hoogle/update-hoogle > new-debian/files_hoogle/update-hoogle > --- old-debian/files_hoogle/update-hoogle 2012-09-12 > 08:17:18.907412898 +0900 > +++ new-debian/files_hoogle/update-hoogle 2012-09-12 > 08:17:18.939413058 +0900 > @@ -16,11 +16,11 @@ > $HOOGLE data keyword > > echo "Collect txt files on ghc-doc" > -find /usr/share/doc/ghc-doc/html/libraries/*/ -name "*.txt*" | \ > +find /usr/share/doc/ghc-doc/html/libraries/*/ -name "*.txt*" 2>/dev/null | \ > /usr/share/hoogle/tool/haddock_collect.hs $URLPREFIX $DATABASE_DIR/ > > echo "Collect txt files on libghc-*-doc" > -find /usr/share/doc/libghc-*-doc/html/ -name "*.txt*" | \ > +find /usr/share/doc/libghc-*-doc/html/ -name "*.txt*" 2>/dev/null | \ > /usr/share/hoogle/tool/haddock_collect.hs $URLPREFIX $DATABASE_DIR/ > > # convert > ----------- I’d prefer something more defensive, for example $ find /usr/share/doc -wholename "/usr/share/doc/libghc-*-doc/*.txt" or even better: Change the patch to haskell-devscripts to install the .txt files to a well-known location (e.g. /usr/share/hoogle/txts) and just read the whole directory. You can keep some compatibility code to read the files from ghc-doc from their current place until ghc-doc also installs to that directory. > > Is there any point in keeping the *.txt and *.hoo files > > in /var/lib/hoogle/databases after a update_hoogle run? It seems, at a > > first glance, that /var/lib/hoogle/databases/default.hoo is enough. > > > > I did not yet test the cgi interface. I’d also welcome if other people > > from DHG would review this non-trivial package. > > I think you can use cgi interface http://localhost/cgi-bin/hoogle, > with apache2, dwww and hoogle packages. Yes, I have been too lazy to install apache on my laptop. Greetings, Joachim -- Joachim "nomeata" Breitner Debian Developer nomeata@debian.org | ICQ# 74513189 | GPG-Keyid: 4743206C JID: nomeata@joachim-breitner.de | http://people.debian.org/~nomeata
Attachment:
signature.asc
Description: This is a digitally signed message part