pugs installation on cygwin

rurban on 2008-07-11T14:43:48

This is how I managed to install latest pugs on cygwin. This is the same as for any platform without existing packages.

Download and install ghc from Note that from ghc 6.8 on Pugs will not compile OOTB, you'd need Cabal then. This is a win32 native and goes into "c:/ghc/ghc-6.8.3"

Create symlinks in our path: $ for f in ln -s /cygdrive/c/ghc/ghc-6.8.3/bin/*; do ln -s $f /usr/local/bin/; done

Download and install Cabal required for cabal-install. Cabal-1.2.4.0, which comes with ghc-6.8.3, is not new enough. Sigh. Cabal tar.gz packages at http://hackage.haskell.org/cgi-bin/hackage-scripts/package/Cabal>
wget http://hackage.haskell.org/packages/archive/Cabal/1.4.0.1/Cabal-1.4.0.1.tar.gz tar xfz Cabal-1.4.0.1.tar.gz cd Cabal-1.4.0.1 runhaskell ./Setup.hs configure --ghc runhaskell ./Setup.hs build runhaskell ./Setup.hs install cd ..

# Get zlib and HTTP, two required deps for cabal-install:

wget http://hackage.haskell.org/packages/archive/HTTP/3001.0.4/HTTP-3001.0.4.tar.gz tar xfz HTTP-3001.0.4.tar.gz cd HTTP-3001.0.4.tar.gz runhaskell ./Setup.lhs configure --ghc runhaskell ./Setup.lhs build runhaskell ./Setup.lhs install cd ..

wget http://hackage.haskell.org/packages/archive/zlib/0.4.0.4/zlib-0.4.0.4.tar.gz tar xfz zlib-0.4.0.4.tar.gz cd zlib-0.4.0.4 runhaskell ./Setup.hs configure --ghc runhaskell ./Setup.hs build runhaskell ./Setup.hs install cd ..

# now get cabal-install, which is the haskell version of CPAN.

wget http://hackage.haskell.org/packages/archive/cabal-install/0.5.1/cabal-install-0.5.1.tar.gz tar xfz cabal-install-0.5.1.tar.gz cd cabal-install-0.5.1 runhaskell ./Setup.hs configure --ghc runhaskell ./Setup.hs build runhaskell ./Setup.hs install cd ..

# copy the installed bin\cabal.exe to /usr/local/bin/ cp /cygdrive/c/Program\ Files/Cabal/.../bin/cabal.exe /usr/local/bin/ # and now it's getting easier:

cabal update cabal install Pugs

# here I get a stupid regex-base-0.93.1 failure # ghc version >=6.4 is required but it could not be found. # The package locations are registered in C:\ghc\ghc-6.8.3\package.conf

cabal install -v regex-base # verbose. aha, the cached tar.gz is deep there cp 'C:/Doc..../regex-base-0.93.1.tar.gz' . tar xfz regex-base-0.93.1.tar.gz cd regex-base-0.93.1 runhaskell ./Setup.hs configure --ghc # => stupid error joe regex-base.cabal # add Build-Type: Simple # after Tested-With: # Ctrl-k x runhaskell ./Setup.hs configure --ghc runhaskell ./Setup.hs build runhaskell ./Setup.hs install cd ..

# and continue... cabal install Pugs

# dada! cp 'C:\Program Files\Haskell\bin\pugs.exe' /usr/local/bin/

pugs

______ /\ __ \ \ \ \/\ \ __ __ ______ ______ (P)erl 6 \ \ __//\ \/\ \/\ __ \/\ ___\ (U)ser's \ \ \/ \ \ \_\ \ \ \/\ \ \___ \ (G)olfing \ \__\ \ \____/\ \____ \/\_____\ (S)ystem \/__/ \/___/ \/___/\ \/____/ /\____/ Version: 6.2.13.7 \/___/ Copyright 2005-2008, The Pugs Contributors -------------------------------------------------------------------- Web: http://pugscode.org/ Email: perl6-compiler@perl.org

Welcome to Pugs -- Perl6 User's Golfing System Type :h for help.

Loading Prelude... done. pugs>