[Haskell-cafe] Re: was Re: ANN: HSH 1.2.0

Thomas Hartman tphyahoo at gmail.com
Tue Apr 3 10:25:30 EDT 2007


actually, maybe I'm more okay than I thought.

I originally did this without reading the INSTALL file, and built
using the process I have gotten used to: runghc Setup.hs configure;
runghc Setup.hs build; runghc Setup.hs install.

But when I followed the directions in the INSTALL file ...

  make setup

Now:

 ./setup configure
 ./setup build
 ./setup install

... it seemed to work without that error message.

So far so good!

I was also able to do

thartman at linodehaskell:~/haskellinstalls/hsh> ghci HSH
   ___         ___ _
  / _ \ /\  /\/ __(_)
 / /_\// /_/ / /  | |      GHC Interactive, version 6.6, for Haskell 98.
/ /_\\/ __  / /___| |      http://www.haskell.org/ghc/
\____/\/ /_/\____/|_|      Type :? for help.

Loading package base ... linking ... done.
Ok, modules loaded: HSH, HSH.Command, HSH.ShellEquivs.
Prelude HSH>

however, when I tried copying a simple example from

  http://changelog.complete.org/posts/492-Announcing-HSH,-the-Haskell-Shell.html

I got errors

thartman at linodehaskell:~/haskellinstalls/hsh>ghci -fglasgow-exts HSH
   ___         ___ _
  / _ \ /\  /\/ __(_)
 / /_\// /_/ / /  | |      GHC Interactive, version 6.6, for Haskell 98.
/ /_\\/ __  / /___| |      http://www.haskell.org/ghc/
\____/\/ /_/\____/|_|      Type :? for help.

Loading package base ... linking ... done.
Ok, modules loaded: HSH, HSH.Command, HSH.ShellEquivs.
Prelude HSH> run $ ("ls", ["."])

<interactive>:1:0:
    Ambiguous type variable `a' in the constraint:
      `RunResult a' arising from use of `run' at <interactive>:1:0-2
    Probable fix: add a type signature that fixes these type variable(s)
Prelude HSH>

So, that's where I'm at now.

2007/4/3, Thomas Hartman <tphyahoo at gmail.com>:
> That was a pretty badly titled top thead, which I regret -- probably
> should have been something like "figuring out how to track down and
> install packages in haskell, using ubuntu /deb-- was Ann:: HSH".
>
> To give additional context, this started out as
>
> http://groups.google.de/group/fa.haskell/browse_thread/thread/ca37248eae7a065f/d039de2f9bf6e848?lnk=st&q=hsh+tphyahoo&rnum=1&hl=en#d039de2f9bf6e848
>
> Sorry about the bad title.
>
> Still hoping to get hsh working, though for me this has more morphed
> into learning about package and dependency chasing in a haskell/deb
> context.
>
>
> 2007/4/3, Thomas Hartman <tphyahoo at gmail.com>:
> > I'm still trying to figure out how to do this on ubuntu. If this winds
> > up being a garden path I'll try on debian next, but at least I'm
> > learning a lot about getting haskell stuff built.
> >
> > Anyway, since I'm on a virtualized linux box, I decided to get a fresh
> > start, unmounted my original OS profile and installed a fresh dapper
> > 6.
> >
> > I then changed /etc/apt/sources.list to be okay for grabbing .debs
> > from feisty. (No longer doing the build from source thing.)
> >
> > apt-get install ghc6, ok from feisty.
> >   (Is there another repo that gets all the extra libs at one go?)
> >
> > sudo apt-cache search -o APT::Cache-Limit=25165824 ghc6 | grep -i missing
> >
> > libghc6-hdbc-missingh-dev - Integration of HDBC with MissingH, GHC version
> > libghc6-missingh-dev - Library of utility functions for Haskell, GHC6 package
> > thartman at linodehaskell:~/haskellinstalls/hsh>sudo apt-cache search -o
> >
> > hoorah, my apt cache search command seems ok.
> >
> >
> > sudo apt-cache search -o APT::Cache-Limit=25165824 ghc6 | grep -i hsh
> > thartman at linodehaskell:~/haskellinstalls/hsh>
> >
> > too bad, still no hsh in ubuntu repo.
> >
> > darcs get http://darcs.complete.org/hsh/
> >   (Or should I have used something else?)
> >
> > runghc Setup.hs configure
> >   same problems as before.
> >
> > But starting afresh seems to have detangled the issues I was having
> > with packaging confusion. At least now I can apt-get install missingh
> >
> > And some other dependency following is made easier.
> >
> > Finally configure for hsh works.
> >
> > But then
> >
> > thartman at linodehaskell:~/haskellinstalls/hsh>sudo runghc Setup.lhs install
> > Setup.lhs: Warning: The field "hs-source-dir" is deprecated, please
> > use hs-source-dirs.
> > Installing: /usr/local/lib/HSH-1.2.1/ghc-6.6 & /usr/local/bin HSH-1.2.1...
> > Setup.lhs: Error: Could not find module: HSH with any suffix: ["hi"]
> >
> > So, I seem to be stuck at this point.
> >
> > 2007/4/2, Thomas Hartman <tphyahoo at gmail.com>:
> > > Well, I guess I spoke to soon. After building ghc6 from feisty as
> > > described above, I tried building missingh and have basically what I
> > > started with.
> > >
> > > Is there something I can tweak to get the above straightened out using
> > > those nice deb packages, or do I have to do all the dependency chasing
> > > involved with building from source? Or is there another way?
> > >
> > > If this is too debian oriented please yell at me and I will ask about
> > > this on a deb/ubuntu forum.
> > >
> > > thanks...
> > >
> > > Note, should have mentioned, after doing as my above post describes, I
> > > installed all the newly generated deb packages with
> > >
> > > dpkg -i *.deb
> > >
> > > ****************
> > >
> > > thartman at linodewhyou:~/haskellInstalls/missingh>runghc Setup.hs configure
> > > Configuring MissingH-0.18.3...
> > > configure: /usr/lib/ghc-6.6/bin/ghc-pkg
> > > configure: Dependency unix-any: using unix-1.0
> > > Setup.hs: cannot satisfy dependency network-any
> > >
> > > thartman at linodewhyou:~/haskellInstalls/missingh>which runghc
> > > /usr/lib/ghc-6.6/bin/runghc
> > >
> > > # note, definitely the thing I installed today:
> > > thartman at linodewhyou:~/haskellInstalls/missingh>ls -l `which runghc`
> > > -rwxr-xr-x 1 root root 300716 Apr  2 09:17 /usr/lib/ghc-6.6/bin/runghc
> > > thartman at linodewhyou:~/haskellInstalls/missingh>
> > >
> > > # and I installed it from deb ghc6, dpkg recognizes it
> > >
> > > thartman at linodewhyou:~/haskellInstalls/missingh>dpkg -S
> > > /usr/lib/ghc-6.6/bin/runghc
> > > ghc6: /usr/lib/ghc-6.6/bin/runghc
> > >
> > > # it does seem like ghc6 comes with a network package
> > > thartman at linodewhyou:~/learning/haskell>apt-cache showpkg ghc6 | grep -i network
> > > 6.4.1-2ubuntu2 - libghc6-readline-dev libghc6-stm-dev libghc6-hgl-dev
> > > libghc6-x11-dev libghc6-fgl-dev libghc6-mtl-dev libghc6-hunit-dev
> > > libghc6-quickcheck-dev libghc6-network-dev libghc6-haskell-src-dev
> > > libghc6-parsec-dev libghc6-cabal-dev libghc6-unix-dev
> > > libghc6-template-haskell-dev libghc6-haskell98-dev libghc6-base-dev
> > > libghc6-rts-dev ghc haskell-compiler
> > >
> > > # I get lost here. Do I have libghc6-network-dev, or don't I?
> > >
> > > thartman at linodewhyou:~/haskellInstalls/missingh>sudo apt-get install
> > > libghc6-network-dev
> > > Reading package lists... Done
> > > Building dependency tree... Done
> > > Note, selecting ghc6 instead of libghc6-network-dev
> > > ghc6 is already the newest version.
> > > You might want to run `apt-get -f install' to correct these:
> > > The following packages have unmet dependencies:
> > >   hat-ghc6: Depends: ghc6 (< 6.4.1+) but 6.6-3 is to be installed
> > >   libghc6-cabal-dev: Depends: ghc6 (< 6.4.2) but 6.6-3 is to be installed
> > > E: Unmet dependencies. Try 'apt-get -f install' with no packages (or
> > > specify a solution).
> > >
> > >
> > >
> > >
> > >
> > >
> > > 2007/4/2, Thomas Hartman <tphyahoo at gmail.com>:
> > > > > As you have built ghc6.6 from sources I think that you also need to build
> > > > > all haskell libs from sources. So, do
> > > >
> > > > I did this, and got the feeling this would probably work, but is a
> > > > real sad world of dependency chasing with no (clear) end in sight.
> > > >
> > > > So I investigated your second suggestion
> > > >
> > > > > Another way is to take ghc6 and all haskell libs from fiesty.
> > > >
> > > > which to me seems much preferrable.
> > > >
> > > > http://old.pupeno.com/blog/unstable-packages-on-ubuntu/
> > > >
> > > > Was indispensible in helping me figure out how to do this.
> > > >
> > > > To give some details on this (which is really more apt packaging know
> > > > how than haskell but whatever), I did something like
> > > >
> > > > 1) change /etc/apt/sources.list to add
> > > >
> > > > deb-src http://archive.ubuntu.com/ubuntu/ feisty main restricted
> > > > universe multiverse
> > > >
> > > > note, only add deb-src line here, not deb line, see article above for why.
> > > >
> > > > sudo aptitude install fakeroot (needed utility)
> > > > fakeroot apt-get source --build ghc6
> > > >   -- complains, some dependencies are missing
> > > >
> > > > sudo aptitude install .....
> > > >  install packages with above command, not from source. it's my first
> > > > time using the aptitude command, I wonder if this does the same thing
> > > > as apt-get install, which is what I usually do. Whatever the case...
> > > >
> > > > fakeroot apt-get source --build ghc6
> > > >
> > > > works :)
> > > >
> > > > 2007/3/21, Max Vasin <max.vasin at gmail.com>:
> > > > > >>>>> "Thomas" == Thomas Hartman <tphyahoo at gmail.com> writes:
> > > > >
> > > > > Thomas> Furthermore (as the above messages suggest and locate confirms), I
> > > > > Thomas> seem to have mtl already
> > > > >
> > > > > Thomas> I took a wild guess and tried specifying this with ghc -i
> > > > >
> > > > > Thomas> like
> > > > >
> > > > > Thomas> sudo runghc -i/usr/lib/ghc6-mtl-dev Setup.lhs configure
> > > > > Thomas> and sudo runghc -i/usr/lib/ Setup.lhs configure
> > > > >
> > > > > Thomas> but no dice.
> > > > >
> > > > > Thomas> ***************
> > > > >
> > > > > Thomas> thartman at linodewhyou:~/haskellInstalls/hsh$ locate libghc6-mtl-dev
> > > > > Thomas> /home/thartman/libghc6-mtl-dev_1.0-3_i386.deb
> > > > > Thomas> /usr/lib/libghc6-mtl-dev
> > > > > Thomas> /usr/lib/libghc6-mtl-dev/register.sh
> > > > > Thomas> /usr/lib/libghc6-mtl-dev/unregister.sh
> > > > > Thomas> /usr/share/doc/libghc6-mtl-dev
> > > > > Thomas> /usr/share/doc/libghc6-mtl-dev/changelog.Debian.gz
> > > > > Thomas> /usr/share/doc/libghc6-mtl-dev/copyright
> > > > > Thomas> /var/lib/dpkg/info/libghc6-mtl-dev.list
> > > > > Thomas> /var/lib/dpkg/info/libghc6-mtl-dev.md5sums
> > > > > Thomas> /var/lib/dpkg/info/libghc6-mtl-dev.postinst
> > > > > Thomas> /var/lib/dpkg/info/libghc6-mtl-dev.prerm
> > > > >
> > > > > As you have built ghc6.6 from sources I think that you also need to build
> > > > > all haskell libs from sources. So, do
> > > > >
> > > > > $ apt-get source libghc6-mtl-dev
> > > > > $ cd <haskell-mtl-or-whatever-dir-is-named>
> > > > > $ runhaskell Setup.lhs configure
> > > > > $ runhaskell Setup.lhs build
> > > > > $ sudo runhaskell Setup.lhs install
> > > > >
> > > > > Another way is to take ghc6 and all haskell libs from fiesty.
> > > > >
> > > > > --
> > > > > WBR,
> > > > > Max Vasin.
> > > > >
> > > > > _______________________________________________
> > > > > Haskell-Cafe mailing list
> > > > > Haskell-Cafe at haskell.org
> > > > > http://www.haskell.org/mailman/listinfo/haskell-cafe
> > > > >
> > > >
> > >
> >
>


More information about the Haskell-Cafe mailing list