@@ -1,13 +1,21 @@
3# Check that a source distribution can be successfully generated, and that
3# Check that a source distribution can be successfully generated, and that
4−# the generated source distribution can be installed
4+# the generated source distribution can be installed and tested
6−if SRC_TGZ="$PWD/dist/$(cabal info . | awk '{print $2;exit}').tar.gz"
6+PKGNAME=$(cabal info . | awk '{print $2;exit}')
7+if SRC_TGZ="$PWD/dist/$PKGNAME.tar.gz"
8 mkdir -p ../install-test
9 mkdir -p ../install-test
9 cd ../install-test
10 cd ../install-test
10 mkdir -p sandboxes/$GHCVER/${STACKAGE:-none}
11 mkdir -p sandboxes/$GHCVER/${STACKAGE:-none}
11 cabal sandbox init --sandbox sandboxes/$GHCVER/${STACKAGE:-none}
12 cabal sandbox init --sandbox sandboxes/$GHCVER/${STACKAGE:-none}
12− cabal install -j2 --ghc-options='+RTS -A32m -RTS' "$SRC_TGZ"
13+
14+ if [ `echo "$STACKAGE" | sed 's/\..*$//'` = "lts-3" ]; then
15+ tar -xzf i--strip-components=1 $PKGNAME.tar.gz
19+ cabal install "$SRC_TGZ"