Skip to content

Commit

Permalink
[ Travis ] Replaced cabal install by cabal copy and `cabal regist…
Browse files Browse the repository at this point in the history
…er`.

`cabal install` doesn't use the options set up in `cabal configure` so
we can use:

  cabal configure <options>
  cabal build
  cabal copy
  cabal register

or

  cabal install <options>

See Section 'cabal install ≠ Setup install' from
http://www.vex.net/~trebla/haskell/cabal-cabal.xhtml.

We are using the first option due to the cabal-install issue
haskell/cabal#975.
  • Loading branch information
asr committed Jun 17, 2015
1 parent 81c7612 commit 6c3b2b4
Showing 1 changed file with 23 additions and 8 deletions.
31 changes: 23 additions & 8 deletions .travis.yml
Expand Up @@ -92,6 +92,22 @@ install:
;;
esac

##############################################################################
# Installing Agda

# We are installing Agda using
#
# cabal configure <options>
# cabal build
# cabal copy
# cabal register
#
# instead of
#
# cabal install <options>
#
# due to the cabal-install issue https://github.com/haskell/cabal/issues/975.

##############################################################################
# Running `cabal configure`

Expand Down Expand Up @@ -122,17 +138,16 @@ install:
esac

##############################################################################
# Running `cabal install`
# Running `cabal copy` and `cabal register`.

# The `enable-test` option is required only if $TEST=require-stdlib.
# We don't run `cabal install` because we are using `cabal configure` and
# `cabal build` (see Section 'cabal install ≠ Setup install' from
# http://www.vex.net/~trebla/haskell/cabal-cabal.xhtml).

- case $TEST in
"latex-test" | "non-require-stdlib")
cabal install -v2 --builddir=$BUILD_DIR
;;

"require-stdlib")
cabal install -v2 --builddir=$BUILD_DIR --enable-tests
"latex-test" | "non-require-stdlib" | "require-stdlib")
cabal copy &&
cabal register
;;
esac

Expand Down

0 comments on commit 6c3b2b4

Please sign in to comment.