[Agda] making Agda on Lenny Debian

Serge D. Mechveliani mechvel at botik.ru
Tue Jul 24 19:58:18 CEST 2012


People,
I have a certain problem with  making Agda-2.3.0.1.

I have made and installed Agda-2.3.0.1 from source on my machine under 
Debian Linux of the Sqeeze distribution. 
It works, somehow.

But this machine has only 512 Mb RAM, which leads to rather a slow 
compilation of the library modules imported by an user Agda program.
(By the way, how to restrict the memory usage in compilation, in making?
similar as  `ghc --make Foo +RTS -M400m -RTS'   in GHC). 

For this reason, and for certain others, I need to also install Agda 
to certain other machine, of 1 Gb RAM -- under  Lenny Debian Linux.
But the `make' process reveals a certain difference, which I do not 
understand, so far.
I need to install all these things into my user home.
On both machines, I have  ghc-7.4.1  made and installed from source in
                                     /home/mechvel/ghc/7.4.1/inst/,

and it shows that it also has  Cabal  installed automatically in this  
ghc  directory (do not know about  cabal-install).

Further, making  Agda  needs calling `cabal'.
And the `cabal' command is not accessible for me at this stage.
So, I have additionally made from source and installed  Cabal-1.14.0  in
/home/mechvel/.cabal,
and then, also made and installed  cabal-install-0.14.0 :  
-- ...
-- Linking dist/build/cabal/cabal ...
-- Installing executable(s) in  /home/mechvel/.cabal/bin

So, the `cabal' command is now possible for me (on both machines):  
 > which cabal
 /home/mechvel/.cabal/bin/cabal

Then, I try installing Agda on Lenny by using the newly installed Cabal:

  > cd ~/haskell/agda/Agda-2.3.0.1
  > cabal update
  > cabal install Agda-executable
  ...

On the  Sqeeze machine,  all this succeedes. 
But on the  Lenny machine,  the third command fails in the middle, at 
the package of  haskeline-0.6.4.7,  with the report

----------------------------------------------------------
...
[7 of 7] Compiling Data.ByteString.Lazy.UTF8 
  ( Data/ByteString/Lazy/UTF8.hs, dist/build/Data/ByteString/Lazy/UTF8.o )
Registering utf8-string-0.3.7...
Installing library in /home/mechvel/.cabal/lib/utf8-string-0.3.7/ghc-7.4.1
Registering utf8-string-0.3.7...
Downloading haskeline-0.6.4.7...

<command line>: cannot satisfy -package Cabal-1.14.0:       *******

    Cabal-1.14.0-0a7fed83b9ae97d1d588690cc2a4821d is shadowed by package 
    Cabal-1.14.0-044aebb162a56e9e7e74b79bfb3b5e56
    Cabal-1.14.0-044aebb162a56e9e7e74b79bfb3b5e56 is unusable due to 
      missing or recursive dependencies:
      containers-0.4.2.1-7c54595400348f577b3b4a45691c5afd 
      process-1.1.0.1-91185c964ab744c1f3cbca1863d2ba45 
      unix-2.5.1.0-b1af78df0de7dbfdaa792b0295afdb70
    (use -v for more information)
Downloading vector-0.9.1...
...
...
Installing library in /home/mechvel/.cabal/lib/xhtml-3000.2.1/ghc-7.4.1
Registering xhtml-3000.2.1...
cabal: Error: some packages failed to install:
Agda-2.3.0.1 depends on haskeline-0.6.4.7 which failed to install.
...
------------------------------------------------------------------

 > ghc-pkg list 
shows
--------------------------------
/home/mechvel/ghc/7.4.1/inst/lib/ghc-7.4.1/package.conf.d:
    {Cabal-1.14.0}
    array-0.4.0.0
...
...
/home/mechvel/.ghc/i386-linux-7.4.1/package.conf.d:
    {Cabal-1.14.0}
    {HTTP-4000.2.3}
    QuickCheck-2.4.2
...
--------------------------------

On the  Squeeze machine, the Cabal-1.14.0 package is also shown in the 
files  package.conf.d  residing in similar two places, but there the Agda 
installation is successful.

I tried to install Haskell Platform, but failed, on both machines.
It is too difficult. I think that the easiest way to install Agda on 
Lenny is to follow this successful proceess on Squeeze. 

1) Could you advice, please, how to fix the installation?
2) As  ghc-7.4.1  is installed from source, do I really need to 
   additionally install Cabal and cabal-install in order to install 
   Agda ?

Thanks,

------
Sergei
mechvel at botik.ru


More information about the Agda mailing list