From 60c467bfeece7b10f05811aa2acf460bb9c7c994 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 10:25:42 +1000 Subject: [PATCH 001/217] fiddling with bin/detect --- bin/detect | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/detect b/bin/detect index 014359c..71bf985 100755 --- a/bin/detect +++ b/bin/detect @@ -1,6 +1,6 @@ -#!/usr/bin/env bash +#!/bin/bash if test -n "$(find "$1" -maxdepth 1 -name '*.cabal' -print -quit)" -then echo Haskell -else echo no; exit 1 +then echo Haskell; exit 0 +else exit 1 fi From f5a7750b7b9319892e142f7e70acf4c916904ff2 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 10:28:46 +1000 Subject: [PATCH 002/217] some logging --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 60b549a..3ffbf03 100755 --- a/bin/compile +++ b/bin/compile @@ -25,7 +25,7 @@ if [ ! -e .cabal ]; then echo "-----> Bundling Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz fi - +pwd mkdir -p bin ln -s ghc/bin/ghc bin/ghc ln -s .cabal/bin/cabal bin/cabal From 0eda76c8bcb1473b566c987f7c89fff64727cc88 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 10:32:50 +1000 Subject: [PATCH 003/217] be noisier --- bin/compile | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 3ffbf03..973be06 100755 --- a/bin/compile +++ b/bin/compile @@ -7,12 +7,18 @@ set -eo pipefail BUILD_DIR=$1 CACHE_DIR=$2 +mkdir -p $CACHE_DIR + cd $BUILD_DIR +echo "build dir:" +ls -alR $BUILD_DIR + +echo "cache dir:" +ls -alR $CACHE_DIR -mkdir -p $CACHE_DIR -cp -R $CACHE_DIR/ghc ghc &> /dev/null || true -cp -R $CACHE_DIR/cabal .cabal &> /dev/null || true +cp -R $CACHE_DIR/ghc ghc || true +cp -R $CACHE_DIR/cabal .cabal || true if [ ! -e ghc ]; then GHC_URL="http://s3.amazonaws.com/heroku-buildpack-haskell/ghc.tar.gz" From 38904923638a3bea67feee7af9be45d9d8fb66d1 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 10:37:10 +1000 Subject: [PATCH 004/217] be noisierer --- bin/compile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bin/compile b/bin/compile index 973be06..f27d2e2 100755 --- a/bin/compile +++ b/bin/compile @@ -33,6 +33,10 @@ if [ ! -e .cabal ]; then fi pwd mkdir -p bin +echo "what do we have?" +ls -R ghc +ls -R .cabal + ln -s ghc/bin/ghc bin/ghc ln -s .cabal/bin/cabal bin/cabal From 3f3fc0f85f53fdfe39d9bcfd20654f0205d6aea3 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 11:02:01 +1000 Subject: [PATCH 005/217] copy ghc dir to /app/ghc --- bin/compile | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index f27d2e2..0c5a6ba 100755 --- a/bin/compile +++ b/bin/compile @@ -34,15 +34,22 @@ fi pwd mkdir -p bin echo "what do we have?" -ls -R ghc +pwd +ls -R ghc/bin ls -R .cabal ln -s ghc/bin/ghc bin/ghc ln -s .cabal/bin/cabal bin/cabal +cp -R ghc $CACHE_DIR/ghc +cp -R ghc /app + mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so +# this is actually a shell script with a bunch of hardcoded +# references to /app/ghc/* + ghc/bin/ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" ghc/bin/ghc-pkg update base.conf @@ -52,7 +59,10 @@ rm base.conf .cabal/bin/cabal install rm -rf $CACHE_DIR/ghc -cp -R ghc $CACHE_DIR/ghc + + + + rm -rf $CACHE_DIR/cabal cp -R .cabal $CACHE_DIR/cabal From 1665aea646e233d200e22236bd80c3031c2de699 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 11:08:36 +1000 Subject: [PATCH 006/217] need to specify file to edit in place --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 0c5a6ba..aa87b1c 100755 --- a/bin/compile +++ b/bin/compile @@ -51,7 +51,7 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so # references to /app/ghc/* ghc/bin/ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" +sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf ghc/bin/ghc-pkg update base.conf rm base.conf From f3c39080a47837182c43bd2c755d8ad99b19d5ce Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 11:17:22 +1000 Subject: [PATCH 007/217] some more logging --- bin/compile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/compile b/bin/compile index aa87b1c..7d53e4a 100755 --- a/bin/compile +++ b/bin/compile @@ -50,12 +50,15 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so # this is actually a shell script with a bunch of hardcoded # references to /app/ghc/* +echo "setting up ghc-pkg" ghc/bin/ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf ghc/bin/ghc-pkg update base.conf rm base.conf +echo "updating cabal" .cabal/bin/cabal update +echo "release the hounds! Installing the app" .cabal/bin/cabal install rm -rf $CACHE_DIR/ghc From 07062f2d371578f9a3bd2a9a871f6e0b38fc6a83 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 17 Jun 2012 11:24:02 +1000 Subject: [PATCH 008/217] add ghc to PATH --- bin/compile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/bin/compile b/bin/compile index 7d53e4a..45c04a5 100755 --- a/bin/compile +++ b/bin/compile @@ -56,16 +56,12 @@ sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf ghc/bin/ghc-pkg update base.conf rm base.conf +export PATH=/app/ghc/bin:$PATH echo "updating cabal" .cabal/bin/cabal update echo "release the hounds! Installing the app" .cabal/bin/cabal install -rm -rf $CACHE_DIR/ghc - - - - rm -rf $CACHE_DIR/cabal cp -R .cabal $CACHE_DIR/cabal From 772ae9f0a6663dbad9ef338eb949c0c39e8daa50 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Thu, 21 Jun 2012 09:55:44 +1000 Subject: [PATCH 009/217] logging &hax --- bin/compile | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/bin/compile b/bin/compile index 45c04a5..c1eba3d 100755 --- a/bin/compile +++ b/bin/compile @@ -65,3 +65,15 @@ echo "release the hounds! Installing the app" rm -rf $CACHE_DIR/cabal cp -R .cabal $CACHE_DIR/cabal + + +echo "Cachedir:" +du -ms $CACHE_DIR + +echo "builddir:" +du -m $BUILD_DIR + +echo "home" +du -m /app + +rm -rf $CACHE_DIR $BUILD_DIR From 3e066d71cc7d57a0250ff2f5f95a4e37d127519f Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Thu, 21 Jun 2012 10:17:36 +1000 Subject: [PATCH 010/217] logs & deletions --- bin/compile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/bin/compile b/bin/compile index c1eba3d..9c61129 100755 --- a/bin/compile +++ b/bin/compile @@ -68,12 +68,11 @@ cp -R .cabal $CACHE_DIR/cabal echo "Cachedir:" -du -ms $CACHE_DIR +du -ms $CACHE_DIR | sort -n | tail -50 echo "builddir:" -du -m $BUILD_DIR +du -m $BUILD_DIR | sort -n |tail -50 echo "home" -du -m /app - -rm -rf $CACHE_DIR $BUILD_DIR +du -m /app |sort -n |tail -50 +rm -rf $CACHE_DIR $BUILD_DIR /app/ghc From 978867f1aafc53fb632c82bb13c5587c8fa0afdf Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Thu, 21 Jun 2012 10:34:18 +1000 Subject: [PATCH 011/217] more hacknslash --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index 9c61129..223672d 100755 --- a/bin/compile +++ b/bin/compile @@ -76,3 +76,4 @@ du -m $BUILD_DIR | sort -n |tail -50 echo "home" du -m /app |sort -n |tail -50 rm -rf $CACHE_DIR $BUILD_DIR /app/ghc +du -ms $CACHE_DIR $BUILD_DIR . From 0769e8f58b266fb41cf42e1f2535a2201d44fd2c Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 11:04:17 +1000 Subject: [PATCH 012/217] return 0 for a successful compile --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index 223672d..6db8dad 100755 --- a/bin/compile +++ b/bin/compile @@ -77,3 +77,4 @@ echo "home" du -m /app |sort -n |tail -50 rm -rf $CACHE_DIR $BUILD_DIR /app/ghc du -ms $CACHE_DIR $BUILD_DIR . +return 0 From 64c33a3fce050d5e1f94d42444d027e12c800878 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 14:35:20 +1000 Subject: [PATCH 013/217] logging --- bin/compile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/compile b/bin/compile index 6db8dad..eed78ae 100755 --- a/bin/compile +++ b/bin/compile @@ -76,5 +76,7 @@ du -m $BUILD_DIR | sort -n |tail -50 echo "home" du -m /app |sort -n |tail -50 rm -rf $CACHE_DIR $BUILD_DIR /app/ghc +ls -al /app/cabal du -ms $CACHE_DIR $BUILD_DIR . +du -ms /app return 0 From 7d1c0cd71faaed7b7dd0f97e092b78babe5c2e32 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 14:53:04 +1000 Subject: [PATCH 014/217] probably should not delete the build dir --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index eed78ae..2af0cd5 100755 --- a/bin/compile +++ b/bin/compile @@ -75,7 +75,7 @@ du -m $BUILD_DIR | sort -n |tail -50 echo "home" du -m /app |sort -n |tail -50 -rm -rf $CACHE_DIR $BUILD_DIR /app/ghc +rm -rf $CACHE_DIR /app/ghc ls -al /app/cabal du -ms $CACHE_DIR $BUILD_DIR . du -ms /app From ccfa3dc3fe5081bc960665985bee815978b72ca2 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 15:07:46 +1000 Subject: [PATCH 015/217] copy binaries to build dir --- bin/compile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 2af0cd5..28046f1 100755 --- a/bin/compile +++ b/bin/compile @@ -76,7 +76,8 @@ du -m $BUILD_DIR | sort -n |tail -50 echo "home" du -m /app |sort -n |tail -50 rm -rf $CACHE_DIR /app/ghc -ls -al /app/cabal -du -ms $CACHE_DIR $BUILD_DIR . -du -ms /app +ls -al /app/.cabal +cp /app/.cabal/bin/* $BUILD_DIR +ls $BUILD_DIR +du -ms $CACHE_DIR $BUILD_DIR . return 0 From 381a3182418003b9a372b9b8aa45f4e940c0b53f Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 15:16:41 +1000 Subject: [PATCH 016/217] clean up build dir --- bin/compile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 28046f1..4826523 100755 --- a/bin/compile +++ b/bin/compile @@ -61,12 +61,16 @@ echo "updating cabal" .cabal/bin/cabal update echo "release the hounds! Installing the app" .cabal/bin/cabal install +cp /app/.cabal/bin/* $BUILD_DIR rm -rf $CACHE_DIR/cabal cp -R .cabal $CACHE_DIR/cabal +# need to delete everything we don't need +rm -rf $BUILD_DIR/.cabal $BUILD_DIR/.ghc + echo "Cachedir:" du -ms $CACHE_DIR | sort -n | tail -50 @@ -77,7 +81,6 @@ echo "home" du -m /app |sort -n |tail -50 rm -rf $CACHE_DIR /app/ghc ls -al /app/.cabal -cp /app/.cabal/bin/* $BUILD_DIR ls $BUILD_DIR du -ms $CACHE_DIR $BUILD_DIR . return 0 From 6a9d581fafb212c3ebf9752efae95e573ff02360 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 15:28:12 +1000 Subject: [PATCH 017/217] ghc, not .ghc. --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 4826523..3ddf04d 100755 --- a/bin/compile +++ b/bin/compile @@ -69,7 +69,7 @@ cp -R .cabal $CACHE_DIR/cabal # need to delete everything we don't need -rm -rf $BUILD_DIR/.cabal $BUILD_DIR/.ghc +rm -rf $BUILD_DIR/.cabal $BUILD_DIR/ghc echo "Cachedir:" du -ms $CACHE_DIR | sort -n | tail -50 From cf0c1cf511e5e1a8c7445ae4922dad77d72e8332 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 15:39:31 +1000 Subject: [PATCH 018/217] stop caching, try to run code at end of compile --- bin/compile | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/bin/compile b/bin/compile index 3ddf04d..2b301a5 100755 --- a/bin/compile +++ b/bin/compile @@ -17,8 +17,8 @@ echo "cache dir:" ls -alR $CACHE_DIR -cp -R $CACHE_DIR/ghc ghc || true -cp -R $CACHE_DIR/cabal .cabal || true +#cp -R $CACHE_DIR/ghc ghc || true +#cp -R $CACHE_DIR/cabal .cabal || true if [ ! -e ghc ]; then GHC_URL="http://s3.amazonaws.com/heroku-buildpack-haskell/ghc.tar.gz" @@ -33,16 +33,12 @@ if [ ! -e .cabal ]; then fi pwd mkdir -p bin -echo "what do we have?" -pwd -ls -R ghc/bin -ls -R .cabal ln -s ghc/bin/ghc bin/ghc ln -s .cabal/bin/cabal bin/cabal -cp -R ghc $CACHE_DIR/ghc -cp -R ghc /app +# cp -R ghc $CACHE_DIR/ghc +# cp -R ghc /app mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so @@ -56,31 +52,36 @@ sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf ghc/bin/ghc-pkg update base.conf rm base.conf -export PATH=/app/ghc/bin:$PATH +# export PATH=/app/ghc/bin:$PATH +export PATH=`pwd`/ghc/bin:$PATH echo "updating cabal" .cabal/bin/cabal update echo "release the hounds! Installing the app" .cabal/bin/cabal install -cp /app/.cabal/bin/* $BUILD_DIR +cp .cabal/bin/* $BUILD_DIR -rm -rf $CACHE_DIR/cabal -cp -R .cabal $CACHE_DIR/cabal +# rm -rf $CACHE_DIR/cabal +# cp -R .cabal $CACHE_DIR/cabal # need to delete everything we don't need rm -rf $BUILD_DIR/.cabal $BUILD_DIR/ghc echo "Cachedir:" -du -ms $CACHE_DIR | sort -n | tail -50 +du -ms $CACHE_DIR | sort -n | tail -10 echo "builddir:" -du -m $BUILD_DIR | sort -n |tail -50 +du -m $BUILD_DIR | sort -n |tail -10 echo "home" -du -m /app |sort -n |tail -50 -rm -rf $CACHE_DIR /app/ghc -ls -al /app/.cabal +du -m /app |sort -n |tail -10 +# rm -rf $CACHE_DIR /app/ghc +# ls -al /app/.cabal ls $BUILD_DIR du -ms $CACHE_DIR $BUILD_DIR . + +# quick hack +./bc_twitter return 0 + From 26b561e55741d9ddeabc1822c80a42498cfe0b8f Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 15:48:08 +1000 Subject: [PATCH 019/217] symbolic link for ghc --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 2b301a5..df14b81 100755 --- a/bin/compile +++ b/bin/compile @@ -38,7 +38,7 @@ ln -s ghc/bin/ghc bin/ghc ln -s .cabal/bin/cabal bin/cabal # cp -R ghc $CACHE_DIR/ghc -# cp -R ghc /app +ln -s ghc /app/ghc mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so From 3b59c78f492a97f4c956ce27c1831cab65048105 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 16:26:56 +1000 Subject: [PATCH 020/217] global replace for build dir --- bin/compile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index df14b81..6f44362 100755 --- a/bin/compile +++ b/bin/compile @@ -38,13 +38,20 @@ ln -s ghc/bin/ghc bin/ghc ln -s .cabal/bin/cabal bin/cabal # cp -R ghc $CACHE_DIR/ghc -ln -s ghc /app/ghc +# ln -s ghc /app/ghc mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so # this is actually a shell script with a bunch of hardcoded # references to /app/ghc/* +# +# let's murder it to death. + +find ghc/bin -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR}g" + +sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf + echo "setting up ghc-pkg" ghc/bin/ghc-pkg describe base > base.conf From f39a6bd3f4cb9dd30e4ac6648842c7095e2ff7e3 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 16:34:08 +1000 Subject: [PATCH 021/217] delete stray sed invocation with extreme prejudice --- bin/compile | 2 -- 1 file changed, 2 deletions(-) diff --git a/bin/compile b/bin/compile index 6f44362..934cb0b 100755 --- a/bin/compile +++ b/bin/compile @@ -50,8 +50,6 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so find ghc/bin -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR}g" -sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf - echo "setting up ghc-pkg" ghc/bin/ghc-pkg describe base > base.conf From 0d59251264263b13e7d2445268b45b99e9c25d1a Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 16:38:06 +1000 Subject: [PATCH 022/217] fix path --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 934cb0b..9c6de32 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so # # let's murder it to death. -find ghc/bin -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR}g" +find ghc/bin -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" echo "setting up ghc-pkg" From d892029e949b5899824777e274b02cfad7dcfe6c Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 16:41:58 +1000 Subject: [PATCH 023/217] logging of base.conf --- bin/compile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/bin/compile b/bin/compile index 9c6de32..056c92c 100755 --- a/bin/compile +++ b/bin/compile @@ -51,9 +51,16 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so find ghc/bin -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" +ls -alR ghc + echo "setting up ghc-pkg" ghc/bin/ghc-pkg describe base > base.conf +echo "before" +cat base.conf + sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf +echo "after" +cat base.conf ghc/bin/ghc-pkg update base.conf rm base.conf From 7d17cd062ca11667a3ca10921e2fea975755fa8e Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 16:45:56 +1000 Subject: [PATCH 024/217] more config munging --- bin/compile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bin/compile b/bin/compile index 056c92c..e65b744 100755 --- a/bin/compile +++ b/bin/compile @@ -59,6 +59,10 @@ echo "before" cat base.conf sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf +echo "mid-surgery" +cat base.conf + +perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" base.conf echo "after" cat base.conf ghc/bin/ghc-pkg update base.conf From e5bff7b743b700ed1b1e568fb64c28b950c5868c Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 16:52:19 +1000 Subject: [PATCH 025/217] ghc-pkg check to work out why ghc is barfing --- bin/compile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index e65b744..b8e5bda 100755 --- a/bin/compile +++ b/bin/compile @@ -66,6 +66,7 @@ perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" base.conf echo "after" cat base.conf ghc/bin/ghc-pkg update base.conf +ghc-pkg check rm base.conf # export PATH=/app/ghc/bin:$PATH @@ -73,7 +74,7 @@ export PATH=`pwd`/ghc/bin:$PATH echo "updating cabal" .cabal/bin/cabal update echo "release the hounds! Installing the app" -.cabal/bin/cabal install +.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared cp .cabal/bin/* $BUILD_DIR From ec28d2593cc7e3d8d9f37fe97e8354b655c162aa Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 16:55:54 +1000 Subject: [PATCH 026/217] full path to ghc-pkg --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index b8e5bda..1a9dc3b 100755 --- a/bin/compile +++ b/bin/compile @@ -66,7 +66,7 @@ perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" base.conf echo "after" cat base.conf ghc/bin/ghc-pkg update base.conf -ghc-pkg check +ghc/bin/ghc-pkg check rm base.conf # export PATH=/app/ghc/bin:$PATH From 7d033a15c8f82bd83d0a70e2ac03348da25427c7 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 17:02:23 +1000 Subject: [PATCH 027/217] global ghc path change --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 1a9dc3b..cb0b7f1 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so # # let's murder it to death. -find ghc/bin -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" +find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" ls -alR ghc From 3b89a28272cd3ff9d150dc0e8d80d8b6be39300a Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 17:26:34 +1000 Subject: [PATCH 028/217] rejig ghc-pkg dance, try setting LD_LIBRARY_PATH when running cabal --- bin/compile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index cb0b7f1..cd945a8 100755 --- a/bin/compile +++ b/bin/compile @@ -51,8 +51,6 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" -ls -alR ghc - echo "setting up ghc-pkg" ghc/bin/ghc-pkg describe base > base.conf echo "before" @@ -66,15 +64,19 @@ perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" base.conf echo "after" cat base.conf ghc/bin/ghc-pkg update base.conf -ghc/bin/ghc-pkg check rm base.conf +ghc/bin/ghc-pkg recache +ghc/bin/ghc-pkg check + # export PATH=/app/ghc/bin:$PATH export PATH=`pwd`/ghc/bin:$PATH echo "updating cabal" .cabal/bin/cabal update echo "release the hounds! Installing the app" -.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared +# the ld library path hack is horrible, but let's see if it helps + +LD_LIBRARY_PATH=`pwd`/lib .cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared cp .cabal/bin/* $BUILD_DIR @@ -98,7 +100,5 @@ du -m /app |sort -n |tail -10 ls $BUILD_DIR du -ms $CACHE_DIR $BUILD_DIR . -# quick hack -./bc_twitter return 0 From eb3dda28eb044e7f58e6813786113a080698f95f Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 17:39:50 +1000 Subject: [PATCH 029/217] voodoo recache --- bin/compile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/compile b/bin/compile index cd945a8..63f994a 100755 --- a/bin/compile +++ b/bin/compile @@ -52,6 +52,8 @@ find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g echo "setting up ghc-pkg" +ghc/bin/ghc-pkg recache +echo "recached" ghc/bin/ghc-pkg describe base > base.conf echo "before" cat base.conf From d338431a1bafb29780fdd48094638c3e7d49f1a7 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 17:58:35 +1000 Subject: [PATCH 030/217] cannot return 0 in bash --- bin/compile | 2 -- 1 file changed, 2 deletions(-) diff --git a/bin/compile b/bin/compile index 63f994a..8b6db88 100755 --- a/bin/compile +++ b/bin/compile @@ -102,5 +102,3 @@ du -m /app |sort -n |tail -10 ls $BUILD_DIR du -ms $CACHE_DIR $BUILD_DIR . -return 0 - From 6e5ad7c5f88231d335588e555c4d73a3ef4de23a Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sat, 21 Jul 2012 18:40:26 +1000 Subject: [PATCH 031/217] shouldn't need to specify PATH --- bin/release | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/release b/bin/release index 7c14edd..0bac582 100755 --- a/bin/release +++ b/bin/release @@ -5,5 +5,5 @@ $BUILD_DIR=$1 cat < Date: Sun, 22 Jul 2012 12:11:44 +1000 Subject: [PATCH 032/217] healthcheck --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index 8b6db88..fed5220 100755 --- a/bin/compile +++ b/bin/compile @@ -102,3 +102,4 @@ du -m /app |sort -n |tail -10 ls $BUILD_DIR du -ms $CACHE_DIR $BUILD_DIR . +./bc_twitter healthcheck From c93eb9c9f0429a11c14080bb2510e68383872ad1 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 22 Jul 2012 12:22:58 +1000 Subject: [PATCH 033/217] correct source location for binaries --- bin/compile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index fed5220..8833cc3 100755 --- a/bin/compile +++ b/bin/compile @@ -79,7 +79,9 @@ echo "release the hounds! Installing the app" # the ld library path hack is horrible, but let's see if it helps LD_LIBRARY_PATH=`pwd`/lib .cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared -cp .cabal/bin/* $BUILD_DIR +echo "copying to build directory" +ls /app/.cabal +cp /app/.cabal/bin/* $BUILD_DIR # rm -rf $CACHE_DIR/cabal @@ -102,4 +104,4 @@ du -m /app |sort -n |tail -10 ls $BUILD_DIR du -ms $CACHE_DIR $BUILD_DIR . -./bc_twitter healthcheck +$BUILD_DIR/bc_twitter healthcheck From 2e39caad9926f80de7b6de30357b0799913f2f74 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Sun, 22 Jul 2012 12:48:06 +1000 Subject: [PATCH 034/217] extend path --- bin/release | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/release b/bin/release index 0bac582..13348c1 100755 --- a/bin/release +++ b/bin/release @@ -5,5 +5,5 @@ $BUILD_DIR=$1 cat < Date: Wed, 29 Aug 2012 11:12:06 +1000 Subject: [PATCH 035/217] wip notice --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9184154..8397ea5 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,9 @@ -# Heroku buildpack: Haskell +# Heroku buildpack: Haskell (WIP) + +This is a work in progress, it does not currently work: size restrictions on heroku are making it difficult. This is a [Heroku buildpack](http://devcenter.heroku.com/articles/buildpacks) -for Haskell apps. It uses cabal-1.14.0. +for Haskell apps. It uses cabal-1.14.0. ## Usage From 3be2e2486384b1ad6f765e0ca93d81da18cc309a Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 13:25:02 -0700 Subject: [PATCH 036/217] Add deletion of hopefully unneeded parts of GHC --- precompile-binaries.sh | 43 +++++++++++++++++++++++++++++------------- 1 file changed, 30 insertions(+), 13 deletions(-) diff --git a/precompile-binaries.sh b/precompile-binaries.sh index bd63baa..a9295e9 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -11,24 +11,41 @@ cd ghc-7.4.1/ make install cd .. +# GHC space trimming (risky business) + +# Remove haddock and hpc - no docs or coverage +rm $HOME/ghc/bin/haddock* +rm $HOME/ghc/lib/ghc-7.4.1/haddock +rm -r $HOME/ghc/lib/ghc-7.4.1/html +rm -r $HOME/ghc/lib/ghc-7.4.1/latex +rm $HOME/ghc/bin/hp* +rm -r $HOME/ghc/lib/ghc-7.4.1/hp* +rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-* +rm -r $HOME/ghc/lib/ghc-7.4.1/ghc-7.4.1 +rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/ghc-7.4.1-* +rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package.cache +echo "" > $HOME/ghc/lib/ghc-7.4.1/ghc-usage.txt +echo "" > $HOME/ghc/lib/ghc-7.4.1/ghci-usage.txt + +# Remove duplicate libs +find $HOME/ghc/lib -name "*_p.a" -delete +find $HOME/ghc/lib -name "*.p_hi" -delete +find $HOME/ghc/lib -name "*.dyn_hi" -delete +find $HOME/ghc/lib -name "*HS*.so" -delete +find $HOME/ghc/lib -name "*HS*.o" -delete +find $HOME/ghc/lib -name "*_debug.a" -delete + +# Don't need man or doc +rm -rf $HOME/ghc/share + +# Strip binaries +strip --strip-unneeded $HOME/ghc/lib/ghc-7.4.1/{run,}ghc + # ldconfig for linker hack $HOME/ghc/bin/ghc-pkg describe base > base.package.conf sed -i "s/ld-options:/ld-options:\ -L\/app\/usr\/lib/" base.package.conf $HOME/ghc/bin/ghc-pkg update base.package.conf -# haskell-platform (disabled because it requires opengl) -#curl --silent http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz|tar xz -#cd haskell-platform-2011.4.0.0/ - -# cabal -curl --silent http://www.haskell.org/cabal/release/cabal-1.14.0/Cabal-1.14.0.tar.gz|tar xz -cd Cabal-1.14.0/ -$HOME/ghc/bin/ghc --make Setup -./Setup configure --user --with-ghc=$HOME/ghc/bin/ghc -./Setup build -./Setup install -cd .. - # cabal-install curl --silent http://www.haskell.org/cabal/release/cabal-install-0.14.0/cabal-install-0.14.0.tar.gz|tar xz cd cabal-install-0.14.0/ From 5e24e0f2d7f7705d221f30edf3dfb58f85b472da Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 13:48:01 -0700 Subject: [PATCH 037/217] Use reduced GHC install --- bin/compile | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/bin/compile b/bin/compile index 8833cc3..698c78e 100755 --- a/bin/compile +++ b/bin/compile @@ -16,18 +16,14 @@ ls -alR $BUILD_DIR echo "cache dir:" ls -alR $CACHE_DIR - -#cp -R $CACHE_DIR/ghc ghc || true -#cp -R $CACHE_DIR/cabal .cabal || true - if [ ! -e ghc ]; then - GHC_URL="http://s3.amazonaws.com/heroku-buildpack-haskell/ghc.tar.gz" + GHC_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz fi if [ ! -e .cabal ]; then - CABAL_URL="http://s3.amazonaws.com/heroku-buildpack-haskell/cabal.tar.gz" + CABAL_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/cabal.tar.gz" echo "-----> Bundling Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz fi @@ -83,11 +79,6 @@ echo "copying to build directory" ls /app/.cabal cp /app/.cabal/bin/* $BUILD_DIR - -# rm -rf $CACHE_DIR/cabal -# cp -R .cabal $CACHE_DIR/cabal - - # need to delete everything we don't need rm -rf $BUILD_DIR/.cabal $BUILD_DIR/ghc @@ -99,9 +90,5 @@ du -m $BUILD_DIR | sort -n |tail -10 echo "home" du -m /app |sort -n |tail -10 -# rm -rf $CACHE_DIR /app/ghc -# ls -al /app/.cabal ls $BUILD_DIR du -ms $CACHE_DIR $BUILD_DIR . - -$BUILD_DIR/bc_twitter healthcheck From 2588e6a8a7d4fba84b0e827be7e5f173d78d6a8b Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 13:58:39 -0700 Subject: [PATCH 038/217] List GHC directory --- bin/compile | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/bin/compile b/bin/compile index 698c78e..65788eb 100755 --- a/bin/compile +++ b/bin/compile @@ -27,25 +27,15 @@ if [ ! -e .cabal ]; then echo "-----> Bundling Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz fi -pwd mkdir -p bin ln -s ghc/bin/ghc bin/ghc ln -s .cabal/bin/cabal bin/cabal -# cp -R ghc $CACHE_DIR/ghc -# ln -s ghc /app/ghc - mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so -# this is actually a shell script with a bunch of hardcoded -# references to /app/ghc/* -# -# let's murder it to death. - -find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" - +ls -lR ghc echo "setting up ghc-pkg" ghc/bin/ghc-pkg recache From 212d84bc0a198a475730f95b39b7c28a5174f0a6 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 14:01:36 -0700 Subject: [PATCH 039/217] Fix ghc script directory --- bin/compile | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/bin/compile b/bin/compile index 65788eb..960bf56 100755 --- a/bin/compile +++ b/bin/compile @@ -35,29 +35,27 @@ ln -s .cabal/bin/cabal bin/cabal mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so -ls -lR ghc +# this is actually a shell script with a bunch of hardcoded +# references to /home/vagrant/ghc/* +# +# let's murder it to death. + +find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" + echo "setting up ghc-pkg" ghc/bin/ghc-pkg recache echo "recached" ghc/bin/ghc-pkg describe base > base.conf -echo "before" -cat base.conf sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf -echo "mid-surgery" -cat base.conf - -perl -i -p -e "s{/app/ghc}{$BUILD_DIR/ghc}g" base.conf -echo "after" -cat base.conf +perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" base.conf ghc/bin/ghc-pkg update base.conf rm base.conf ghc/bin/ghc-pkg recache ghc/bin/ghc-pkg check -# export PATH=/app/ghc/bin:$PATH export PATH=`pwd`/ghc/bin:$PATH echo "updating cabal" .cabal/bin/cabal update From cb49c7062971f9cf60c28e4556ce25aacd842240 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 16:02:21 -0700 Subject: [PATCH 040/217] Extract .cabal to HOME --- bin/compile | 10 +++++----- precompile-binaries.sh | 14 +++++++++++++- 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index 960bf56..e68333f 100755 --- a/bin/compile +++ b/bin/compile @@ -25,12 +25,12 @@ fi if [ ! -e .cabal ]; then CABAL_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/cabal.tar.gz" echo "-----> Bundling Cabal" - curl -# --max-time 120 -L "$CABAL_URL" | tar xz + curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi mkdir -p bin ln -s ghc/bin/ghc bin/ghc -ln -s .cabal/bin/cabal bin/cabal +ln -s ~/.cabal/bin/cabal bin/cabal mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so @@ -58,17 +58,17 @@ ghc/bin/ghc-pkg check export PATH=`pwd`/ghc/bin:$PATH echo "updating cabal" -.cabal/bin/cabal update +~/.cabal/bin/cabal update echo "release the hounds! Installing the app" # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=`pwd`/lib .cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=`pwd`/lib ~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared echo "copying to build directory" ls /app/.cabal cp /app/.cabal/bin/* $BUILD_DIR # need to delete everything we don't need -rm -rf $BUILD_DIR/.cabal $BUILD_DIR/ghc +rm -rf ~/.cabal $BUILD_DIR/ghc echo "Cachedir:" du -ms $CACHE_DIR | sort -n | tail -10 diff --git a/precompile-binaries.sh b/precompile-binaries.sh index a9295e9..2fd5021 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -46,11 +46,23 @@ $HOME/ghc/bin/ghc-pkg describe base > base.package.conf sed -i "s/ld-options:/ld-options:\ -L\/app\/usr\/lib/" base.package.conf $HOME/ghc/bin/ghc-pkg update base.package.conf +export PATH=$PATH:$HOME/ghc/bin + # cabal-install curl --silent http://www.haskell.org/cabal/release/cabal-install-0.14.0/cabal-install-0.14.0.tar.gz|tar xz cd cabal-install-0.14.0/ -PATH=$PATH:$HOME/ghc/bin sh bootstrap.sh +sh bootstrap.sh cd .. +# Precompile some Yesod libs that take a while on Heroku +~/.cabal/bin/cabal update +~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared text-0.11.2.3 +~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared parsec-3.1.3 +~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared network-2.4.0.1 +~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared vector-0.10.0.1 +~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared aeson-0.6.0.2 +find ~/.cabal -name "*HS*.o" -delete +rm -rf ~/.cabal/{config,share,packages,logs} + tar cvzf ghc.tar.gz ghc tar cvzf cabal.tar.gz .cabal From 1ab9cfd5171bee75f1ef051d41bef21ef8d6601f Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 16:12:50 -0700 Subject: [PATCH 041/217] Add .cabal/bin to PATH --- bin/compile | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index e68333f..2296d8a 100755 --- a/bin/compile +++ b/bin/compile @@ -27,10 +27,6 @@ if [ ! -e .cabal ]; then echo "-----> Bundling Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -mkdir -p bin - -ln -s ghc/bin/ghc bin/ghc -ln -s ~/.cabal/bin/cabal bin/cabal mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so @@ -56,16 +52,17 @@ rm base.conf ghc/bin/ghc-pkg recache ghc/bin/ghc-pkg check -export PATH=`pwd`/ghc/bin:$PATH +export PATH=`pwd`/ghc/bin:~/.cabal/bin:$PATH + echo "updating cabal" ~/.cabal/bin/cabal update + echo "release the hounds! Installing the app" # the ld library path hack is horrible, but let's see if it helps +LD_LIBRARY_PATH=`pwd`/lib cabal install --disable-library-profiling --disable-executable-profiling --disable-shared -LD_LIBRARY_PATH=`pwd`/lib ~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared echo "copying to build directory" -ls /app/.cabal -cp /app/.cabal/bin/* $BUILD_DIR +cp ~/.cabal/bin/* $BUILD_DIR # need to delete everything we don't need rm -rf ~/.cabal $BUILD_DIR/ghc From b4b636fabfbd4854032aa801cf0d77092408f92c Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 16:20:04 -0700 Subject: [PATCH 042/217] Run 5 concurrent jobs --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 2296d8a..8f35c1f 100755 --- a/bin/compile +++ b/bin/compile @@ -55,11 +55,11 @@ ghc/bin/ghc-pkg check export PATH=`pwd`/ghc/bin:~/.cabal/bin:$PATH echo "updating cabal" -~/.cabal/bin/cabal update +cabal update echo "release the hounds! Installing the app" # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=`pwd`/lib cabal install --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=`pwd`/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "copying to build directory" cp ~/.cabal/bin/* $BUILD_DIR From 8648348abd4875957ad3f432a87fd67abe084db1 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 16:56:37 -0700 Subject: [PATCH 043/217] Use PATH to remove prefixes from scripts --- bin/compile | 19 ++++++------------- precompile-binaries.sh | 30 ++++++++++++++++-------------- 2 files changed, 22 insertions(+), 27 deletions(-) diff --git a/bin/compile b/bin/compile index 8f35c1f..4c8b210 100755 --- a/bin/compile +++ b/bin/compile @@ -8,13 +8,7 @@ BUILD_DIR=$1 CACHE_DIR=$2 mkdir -p $CACHE_DIR - cd $BUILD_DIR -echo "build dir:" -ls -alR $BUILD_DIR - -echo "cache dir:" -ls -alR $CACHE_DIR if [ ! -e ghc ]; then GHC_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/ghc.tar.gz" @@ -38,21 +32,20 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" +export PATH=`pwd`/ghc/bin:~/.cabal/bin:$PATH echo "setting up ghc-pkg" -ghc/bin/ghc-pkg recache +ghc-pkg recache echo "recached" -ghc/bin/ghc-pkg describe base > base.conf +ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" base.conf -ghc/bin/ghc-pkg update base.conf +ghc-pkg update base.conf rm base.conf -ghc/bin/ghc-pkg recache -ghc/bin/ghc-pkg check - -export PATH=`pwd`/ghc/bin:~/.cabal/bin:$PATH +ghc-pkg recache +ghc-pkg check echo "updating cabal" cabal update diff --git a/precompile-binaries.sh b/precompile-binaries.sh index 2fd5021..37092fe 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -41,28 +41,30 @@ rm -rf $HOME/ghc/share # Strip binaries strip --strip-unneeded $HOME/ghc/lib/ghc-7.4.1/{run,}ghc +export PATH=$PATH:$HOME/ghc/bin + # ldconfig for linker hack -$HOME/ghc/bin/ghc-pkg describe base > base.package.conf +ghc-pkg describe base > base.package.conf sed -i "s/ld-options:/ld-options:\ -L\/app\/usr\/lib/" base.package.conf -$HOME/ghc/bin/ghc-pkg update base.package.conf - -export PATH=$PATH:$HOME/ghc/bin +ghc-pkg update base.package.conf # cabal-install -curl --silent http://www.haskell.org/cabal/release/cabal-install-0.14.0/cabal-install-0.14.0.tar.gz|tar xz -cd cabal-install-0.14.0/ +curl --silent http://hackage.haskell.org/packages/archive/cabal-install/1.16.0.1/cabal-install-1.16.0.1.tar.gz|tar xz +cd cabal-install-1.16.0.1/ sh bootstrap.sh cd .. +export PATH=$PATH:$HOME/.cabal + # Precompile some Yesod libs that take a while on Heroku -~/.cabal/bin/cabal update -~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared text-0.11.2.3 -~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared parsec-3.1.3 -~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared network-2.4.0.1 -~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared vector-0.10.0.1 -~/.cabal/bin/cabal install --disable-library-profiling --disable-executable-profiling --disable-shared aeson-0.6.0.2 -find ~/.cabal -name "*HS*.o" -delete -rm -rf ~/.cabal/{config,share,packages,logs} +cabal update +cabal install --disable-library-profiling --disable-executable-profiling --disable-shared text-0.11.2.3 +cabal install --disable-library-profiling --disable-executable-profiling --disable-shared parsec-3.1.3 +cabal install --disable-library-profiling --disable-executable-profiling --disable-shared network-2.4.0.1 +cabal install --disable-library-profiling --disable-executable-profiling --disable-shared vector-0.10.0.1 +cabal install --disable-library-profiling --disable-executable-profiling --disable-shared aeson-0.6.0.2 +find $HOME/.cabal -name "*HS*.o" -delete +rm -rf $HOME/.cabal/{config,share,packages,logs} tar cvzf ghc.tar.gz ghc tar cvzf cabal.tar.gz .cabal From 298728f7b9df1a4d8113aecbc1070e0885bf1894 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 17:00:54 -0700 Subject: [PATCH 044/217] Can't use ghc-pkg in PATH --- bin/compile | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index 4c8b210..1a5838a 100755 --- a/bin/compile +++ b/bin/compile @@ -32,20 +32,23 @@ ln -s /usr/lib/libgmp.so.3 lib/libgmp.so find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" -export PATH=`pwd`/ghc/bin:~/.cabal/bin:$PATH +# Can't use ghc-pkg in that PATH echo "setting up ghc-pkg" -ghc-pkg recache +ghc/bin/ghc-pkg recache echo "recached" -ghc-pkg describe base > base.conf +ghc/bin/ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" base.conf -ghc-pkg update base.conf +ghc/bin/ghc-pkg update base.conf rm base.conf -ghc-pkg recache -ghc-pkg check +ghc/bin/ghc-pkg recache +ghc/bin/ghc-pkg recache --user +ghc/bin/ghc-pkg check + +export PATH=`pwd`/ghc/bin:~/.cabal/bin:$PATH echo "updating cabal" cabal update From 2f3d34d8208bd6bec07dd1ccc69e6464cdd95dd7 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 17:56:03 -0700 Subject: [PATCH 045/217] Cache Cabal packages --- bin/compile | 64 ++++++++++++++++++------------------------ bin/release | 2 +- precompile-binaries.sh | 8 ++---- 3 files changed, 30 insertions(+), 44 deletions(-) diff --git a/bin/compile b/bin/compile index 1a5838a..3672647 100755 --- a/bin/compile +++ b/bin/compile @@ -7,7 +7,6 @@ set -eo pipefail BUILD_DIR=$1 CACHE_DIR=$2 -mkdir -p $CACHE_DIR cd $BUILD_DIR if [ ! -e ghc ]; then @@ -16,60 +15,51 @@ if [ ! -e ghc ]; then curl -# --max-time 120 -L "$GHC_URL" | tar xz fi -if [ ! -e .cabal ]; then +# Restore Cabal cache or download an empty environemt +if [ -e $CACHE_DIR/cabal ]; then + rm -rf $HOME/.cabal + mv $CACHE_DIR/cabal $HOME/.cabal +elif [ ! -e .cabal ]; then CABAL_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/cabal.tar.gz" - echo "-----> Bundling Cabal" + echo "-----> Downloading Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi mkdir -p lib ln -s /usr/lib/libgmp.so.3 lib/libgmp.so -# this is actually a shell script with a bunch of hardcoded -# references to /home/vagrant/ghc/* +# GHC has shell scripts with a bunch of hardcoded references to +# /home/vagrant/ghc/* # -# let's murder it to death. - +# Let's murder it to death. find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" -# Can't use ghc-pkg in that PATH +PATH=$BUILD_DIR/ghc/bin:$PATH -echo "setting up ghc-pkg" -ghc/bin/ghc-pkg recache -echo "recached" -ghc/bin/ghc-pkg describe base > base.conf +echo "-----> Setting up ghc-pkg" +ghc-pkg recache +ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" base.conf +sed -i "s#ld-options:#ld-options: -L$BUILD_DIR/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" base.conf -ghc/bin/ghc-pkg update base.conf +ghc-pkg update base.conf rm base.conf -ghc/bin/ghc-pkg recache -ghc/bin/ghc-pkg recache --user -ghc/bin/ghc-pkg check +ghc-pkg recache +ghc-pkg recache --user +ghc-pkg check -export PATH=`pwd`/ghc/bin:~/.cabal/bin:$PATH +export PATH=$HOME/.cabal/bin:$PATH -echo "updating cabal" +echo "-----> Updating Cabal" cabal update -echo "release the hounds! Installing the app" +echo "-----> Release the hounds! Installing application" # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=`pwd`/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared - -echo "copying to build directory" -cp ~/.cabal/bin/* $BUILD_DIR - -# need to delete everything we don't need -rm -rf ~/.cabal $BUILD_DIR/ghc +LD_LIBRARY_PATH=$BUILD_DIR/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared -echo "Cachedir:" -du -ms $CACHE_DIR | sort -n | tail -10 - -echo "builddir:" -du -m $BUILD_DIR | sort -n |tail -10 - -echo "home" -du -m /app |sort -n |tail -10 -ls $BUILD_DIR -du -ms $CACHE_DIR $BUILD_DIR . +echo "-----> Caching Cabal packages" +shopt -s extglob +rm $HOME/.cabal/bin/!(cabal|happy) +mkdir -p $CACHE_DIR +mv $HOME/.cabal $CACHE_DIR/cabal diff --git a/bin/release b/bin/release index 13348c1..1ee871a 100755 --- a/bin/release +++ b/bin/release @@ -5,5 +5,5 @@ $BUILD_DIR=$1 cat < Date: Tue, 6 Nov 2012 19:03:15 -0700 Subject: [PATCH 046/217] Put ghc under CACHE_DIR --- bin/compile | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/bin/compile b/bin/compile index 3672647..af4eca1 100755 --- a/bin/compile +++ b/bin/compile @@ -7,41 +7,41 @@ set -eo pipefail BUILD_DIR=$1 CACHE_DIR=$2 -cd $BUILD_DIR +mkdir -p $CACHE_DIR -if [ ! -e ghc ]; then +if [ ! -e $CACHE_DIR/ghc ]; then GHC_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/ghc.tar.gz" echo "-----> Downloading GHC" - curl -# --max-time 120 -L "$GHC_URL" | tar xz + curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal mv $CACHE_DIR/cabal $HOME/.cabal -elif [ ! -e .cabal ]; then +elif [ ! -e $HOME/.cabal ]; then CABAL_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/cabal.tar.gz" echo "-----> Downloading Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -mkdir -p lib -ln -s /usr/lib/libgmp.so.3 lib/libgmp.so +mkdir -p $CACHE_DIR/lib +ln -s /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # GHC has shell scripts with a bunch of hardcoded references to # /home/vagrant/ghc/* # # Let's murder it to death. -find ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" +find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" -PATH=$BUILD_DIR/ghc/bin:$PATH +PATH=$CACHE_DIR/ghc/bin:$PATH echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L$BUILD_DIR/lib#" base.conf -perl -i -p -e "s{/home/vagrant/ghc}{$BUILD_DIR/ghc}g" base.conf +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf ghc-pkg update base.conf rm base.conf @@ -55,11 +55,11 @@ echo "-----> Updating Cabal" cabal update echo "-----> Release the hounds! Installing application" +cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=$BUILD_DIR/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob rm $HOME/.cabal/bin/!(cabal|happy) -mkdir -p $CACHE_DIR mv $HOME/.cabal $CACHE_DIR/cabal From bdbd54c2b1355c4ea50f513f721028671569ec53 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 19:31:24 -0700 Subject: [PATCH 047/217] Print sizes of CACHE_DIR and BUILD_DIR --- bin/compile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bin/compile b/bin/compile index af4eca1..ba838a3 100755 --- a/bin/compile +++ b/bin/compile @@ -63,3 +63,8 @@ echo "-----> Caching Cabal packages" shopt -s extglob rm $HOME/.cabal/bin/!(cabal|happy) mv $HOME/.cabal $CACHE_DIR/cabal + +echo "Cache dir size:" +du -ms $CACHE_DIR +echo "Build dir size:" +du -ms $BUILD_DIR From 60e45f5293789021b390fabe3177d8e75b0e6b4a Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 19:59:01 -0700 Subject: [PATCH 048/217] Remove PATH updating from release script --- bin/release | 6 ------ 1 file changed, 6 deletions(-) diff --git a/bin/release b/bin/release index 1ee871a..b967ab9 100755 --- a/bin/release +++ b/bin/release @@ -1,9 +1,3 @@ #!/bin/sh $BUILD_DIR=$1 - -cat < Date: Tue, 6 Nov 2012 22:41:56 -0700 Subject: [PATCH 049/217] Fix bug in release --- bin/release | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/release b/bin/release index f0961d8..e9ebc1d 100755 --- a/bin/release +++ b/bin/release @@ -1,5 +1,5 @@ #!/bin/sh -$BUILD_DIR=$1 +BUILD_DIR=$1 echo "--- {}" From 2b532dbed170835c679f9e0d223ad7bcfe72a19c Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 20:23:21 -0700 Subject: [PATCH 050/217] Make release output empty YAML --- bin/release | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/release b/bin/release index b967ab9..f0961d8 100755 --- a/bin/release +++ b/bin/release @@ -1,3 +1,5 @@ #!/bin/sh $BUILD_DIR=$1 + +echo "--- {}" From 7ded5780d1c04f87748d709813985f46094b9cf8 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Wed, 7 Nov 2012 17:23:34 +1100 Subject: [PATCH 051/217] ignore if libgmp.so has already been linked to correct spot --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index ba838a3..89f1e96 100755 --- a/bin/compile +++ b/bin/compile @@ -26,7 +26,7 @@ elif [ ! -e $HOME/.cabal ]; then fi mkdir -p $CACHE_DIR/lib -ln -s /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so +ln -s /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so || true # GHC has shell scripts with a bunch of hardcoded references to # /home/vagrant/ghc/* From d12f7d248847f2fbfca76a8c34a910e858549968 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 22:41:56 -0700 Subject: [PATCH 052/217] Fix bug in release --- bin/release | 2 -- 1 file changed, 2 deletions(-) diff --git a/bin/release b/bin/release index f0961d8..0d130af 100755 --- a/bin/release +++ b/bin/release @@ -1,5 +1,3 @@ #!/bin/sh -$BUILD_DIR=$1 - echo "--- {}" From 202e229a8f901610782ac61b040a81bfdc38739d Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 23:43:55 -0700 Subject: [PATCH 053/217] Update README --- README.md | 29 +++++++++++++++++++++-------- 1 file changed, 21 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 8397ea5..ddeedb2 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,34 @@ -# Heroku buildpack: Haskell (WIP) - -This is a work in progress, it does not currently work: size restrictions on heroku are making it difficult. +# Heroku Buildpack: Haskell This is a [Heroku buildpack](http://devcenter.heroku.com/articles/buildpacks) -for Haskell apps. It uses cabal-1.14.0. +for Haskell apps. It uses cabal-1.16.0.1. + +## Demo + +A demo is online here: + +http://haskell-buildpack-demo.herokuapp.com/ + +The demo repo is here: + +https://github.com/pufuwozu/haskell-buildpack-demo ## Usage $ ls Procfile app.cabal src - $ heroku create --stack=cedar --buildpack https://github.com/luciferous/heroku-buildpack-haskell.git + $ heroku create --stack=cedar --buildpack https://github.com/pufuwozu/heroku-buildpack-haskell.git $ git push heroku master ... + -----> Heroku receiving push + -----> Fetching custom git buildpack... done -----> Haskell app detected - -----> Building app with cabal - -----> Running: cabal install - + -----> Downloading GHC + ######################################################################## 100.0% + -----> Downloading Cabal + ######################################################################## 100.0% + -----> Setting up ghc-pkg + ... From 3897985f4a84a7e0c2d3ededb666eb59fd04685b Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 23:45:14 -0700 Subject: [PATCH 054/217] Force libgmp link --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index ba838a3..d6364f7 100755 --- a/bin/compile +++ b/bin/compile @@ -26,7 +26,7 @@ elif [ ! -e $HOME/.cabal ]; then fi mkdir -p $CACHE_DIR/lib -ln -s /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so +ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # GHC has shell scripts with a bunch of hardcoded references to # /home/vagrant/ghc/* From 40c5418fa299ca6b24de1b1a05e6076a0560ed65 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 23:47:55 -0700 Subject: [PATCH 055/217] Remove tmp directory --- tmp/README.md | 0 tmp/index.php | 0 2 files changed, 0 insertions(+), 0 deletions(-) delete mode 100644 tmp/README.md delete mode 100755 tmp/index.php diff --git a/tmp/README.md b/tmp/README.md deleted file mode 100644 index e69de29..0000000 diff --git a/tmp/index.php b/tmp/index.php deleted file mode 100755 index e69de29..0000000 From ed4324e4824138fc98171c8e12f19242a95308ed Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Tue, 6 Nov 2012 23:50:52 -0700 Subject: [PATCH 056/217] Mention GHC version in README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ddeedb2..e54d2d0 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Heroku Buildpack: Haskell This is a [Heroku buildpack](http://devcenter.heroku.com/articles/buildpacks) -for Haskell apps. It uses cabal-1.16.0.1. +for Haskell apps. It uses GHC 7.4.1 and cabal-1.16.0.1. ## Demo From 0595ef6de3e3b1b23fdb6dddf5f76bbe78c9dbb7 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Wed, 7 Nov 2012 00:08:04 -0700 Subject: [PATCH 057/217] Manually cache and restore .ghc directory --- bin/compile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index d6364f7..82c7429 100755 --- a/bin/compile +++ b/bin/compile @@ -15,6 +15,12 @@ if [ ! -e $CACHE_DIR/ghc ]; then curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi +# Restore GHC registry if available +if [ -e $CACHE_DIR/dotghc ]; then + rm -rf $HOME/.ghc + mv $CACHE_DIR/dotghc $HOME/.ghc +fi + # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal @@ -46,7 +52,6 @@ ghc-pkg update base.conf rm base.conf ghc-pkg recache -ghc-pkg recache --user ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH @@ -63,6 +68,7 @@ echo "-----> Caching Cabal packages" shopt -s extglob rm $HOME/.cabal/bin/!(cabal|happy) mv $HOME/.cabal $CACHE_DIR/cabal +mv $HOME/.ghc $CACHE_DIR/dotghc echo "Cache dir size:" du -ms $CACHE_DIR From 69d3c7050c590e220d49e9ebc2a77888d21daacc Mon Sep 17 00:00:00 2001 From: Tim Baumann Date: Mon, 12 Nov 2012 15:44:25 +0100 Subject: [PATCH 058/217] call heroku-pre-install script in directory before installing (if it exists) can be used to install c dependencies etc. --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index 89f1e96..6c40310 100755 --- a/bin/compile +++ b/bin/compile @@ -56,6 +56,7 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR +test -x heroku-pre-install && ./heroku-pre-install "$BUILD_DIR" "$CACHE_DIR" # the ld library path hack is horrible, but let's see if it helps LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared From 14b75ca9d01df7cf2f1e169187931b0746113c71 Mon Sep 17 00:00:00 2001 From: Tom Crayford Date: Tue, 1 Jan 2013 22:56:01 +0000 Subject: [PATCH 059/217] host on s3 --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 82c7429..5adebcd 100755 --- a/bin/compile +++ b/bin/compile @@ -10,7 +10,7 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/ghc.tar.gz" + GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi @@ -26,7 +26,7 @@ if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal mv $CACHE_DIR/cabal $HOME/.cabal elif [ ! -e $HOME/.cabal ]; then - CABAL_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/cabal.tar.gz" + CABAL_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/cabal.tar.gz" echo "-----> Downloading Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi From 75780b53ccf70a58cc4b01a6acee59aaa6f681c6 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Sun, 24 Feb 2013 18:04:02 +0100 Subject: [PATCH 060/217] Add verbose mode for cabal install --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 5adebcd..e1f46dd 100755 --- a/bin/compile +++ b/bin/compile @@ -62,7 +62,7 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -v2 -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob From dc3c09f5eb39a8984819a3ce62ffaa8d6c51bdd1 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Sun, 24 Feb 2013 18:20:22 +0100 Subject: [PATCH 061/217] Add verbose mode for cabal install --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index e1f46dd..c072ed3 100755 --- a/bin/compile +++ b/bin/compile @@ -62,7 +62,7 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -v2 -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install --verbose -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob From 001aeb993d3e1190bddb1d934f5936934d218208 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Sun, 24 Feb 2013 18:23:30 +0100 Subject: [PATCH 062/217] Add verbose mode for cabal install --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index c072ed3..a8c0cda 100755 --- a/bin/compile +++ b/bin/compile @@ -62,7 +62,7 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install --verbose -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -v3 -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob From c86736f7a7040fa8aaad92b1c3310bb4bc9ce064 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 25 Feb 2013 15:37:45 +0100 Subject: [PATCH 063/217] Add ghc-pkg list command --- bin/compile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/compile b/bin/compile index a8c0cda..2d02984 100755 --- a/bin/compile +++ b/bin/compile @@ -59,6 +59,9 @@ export PATH=$HOME/.cabal/bin:$PATH echo "-----> Updating Cabal" cabal update +echo "-----> Check pkg-list" +ghc-pkg list + echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps From 0df8802b20d42b21f4c8a9a464a7e0414785f983 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 26 Feb 2013 13:24:25 +0100 Subject: [PATCH 064/217] Add ghc-pkg list ghc command --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 2d02984..28b9def 100755 --- a/bin/compile +++ b/bin/compile @@ -60,7 +60,7 @@ echo "-----> Updating Cabal" cabal update echo "-----> Check pkg-list" -ghc-pkg list +ghc-pkg list ghc echo "-----> Release the hounds! Installing application" cd $BUILD_DIR From 13e18f1e777f670489c7dc3775ba517f64e60747 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 26 Feb 2013 13:30:10 +0100 Subject: [PATCH 065/217] Add OS-check --- bin/compile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/compile b/bin/compile index 28b9def..952fe13 100755 --- a/bin/compile +++ b/bin/compile @@ -59,6 +59,9 @@ export PATH=$HOME/.cabal/bin:$PATH echo "-----> Updating Cabal" cabal update +echo "-----> Check OS:" +lsb_release -a + echo "-----> Check pkg-list" ghc-pkg list ghc From 27adaf7b48fecc4927878aa01f045f13a2b9dcd6 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 26 Feb 2013 13:37:00 +0100 Subject: [PATCH 066/217] Add OS-check --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 952fe13..5a0a07b 100755 --- a/bin/compile +++ b/bin/compile @@ -60,7 +60,7 @@ echo "-----> Updating Cabal" cabal update echo "-----> Check OS:" -lsb_release -a +uname -a echo "-----> Check pkg-list" ghc-pkg list ghc From caf09f3b058a8734da63c1887854d41b7ff67eb1 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 26 Feb 2013 13:39:04 +0100 Subject: [PATCH 067/217] Add OS-check --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 5a0a07b..dca8e8e 100755 --- a/bin/compile +++ b/bin/compile @@ -60,7 +60,7 @@ echo "-----> Updating Cabal" cabal update echo "-----> Check OS:" -uname -a +cat /proc/version echo "-----> Check pkg-list" ghc-pkg list ghc From 3567095eb1ebcc7c445ee976938f21b0e501be04 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 26 Feb 2013 13:41:52 +0100 Subject: [PATCH 068/217] Add OS-check --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index dca8e8e..ba5a5fc 100755 --- a/bin/compile +++ b/bin/compile @@ -61,6 +61,7 @@ cabal update echo "-----> Check OS:" cat /proc/version +cat /etc/*-release echo "-----> Check pkg-list" ghc-pkg list ghc From 00e130ae19edc39ced5497a43e5fe4ee2110481f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:20:01 +0100 Subject: [PATCH 069/217] Edit precompile and compile files --- bin/compile | 6 +----- precompile-binaries.sh | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index ba5a5fc..f209e39 100755 --- a/bin/compile +++ b/bin/compile @@ -59,17 +59,13 @@ export PATH=$HOME/.cabal/bin:$PATH echo "-----> Updating Cabal" cabal update -echo "-----> Check OS:" -cat /proc/version -cat /etc/*-release - echo "-----> Check pkg-list" ghc-pkg list ghc echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -v3 -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob diff --git a/precompile-binaries.sh b/precompile-binaries.sh index ae5b010..ef75eb9 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -21,7 +21,7 @@ rm -r $HOME/ghc/lib/ghc-7.4.1/latex rm $HOME/ghc/bin/hp* rm -r $HOME/ghc/lib/ghc-7.4.1/hp* rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-* -rm -r $HOME/ghc/lib/ghc-7.4.1/ghc-7.4.1 +# rm -r $HOME/ghc/lib/ghc-7.4.1/ghc-7.4.1 rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/ghc-7.4.1-* rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package.cache echo "" > $HOME/ghc/lib/ghc-7.4.1/ghc-usage.txt From ebd4ab1c28c063b100b8fdb816e39074f2fde6c8 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:25:43 +0100 Subject: [PATCH 070/217] Check ghc-pkg list --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index f209e39..f49cdab 100755 --- a/bin/compile +++ b/bin/compile @@ -60,7 +60,7 @@ echo "-----> Updating Cabal" cabal update echo "-----> Check pkg-list" -ghc-pkg list ghc +ghc-pkg list echo "-----> Release the hounds! Installing application" cd $BUILD_DIR From 2c9e334e966f815615df3cb42b6a0635f624a613 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:32:26 +0100 Subject: [PATCH 071/217] Add Haskell-Platform download --- precompile-binaries.sh | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/precompile-binaries.sh b/precompile-binaries.sh index ef75eb9..87b1755 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -22,8 +22,8 @@ rm $HOME/ghc/bin/hp* rm -r $HOME/ghc/lib/ghc-7.4.1/hp* rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-* # rm -r $HOME/ghc/lib/ghc-7.4.1/ghc-7.4.1 -rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/ghc-7.4.1-* -rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package.cache +# rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/ghc-7.4.1-* +# rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package.cache echo "" > $HOME/ghc/lib/ghc-7.4.1/ghc-usage.txt echo "" > $HOME/ghc/lib/ghc-7.4.1/ghci-usage.txt @@ -48,6 +48,14 @@ ghc-pkg describe base > base.package.conf sed -i "s/ld-options:/ld-options:\ -L\/app\/usr\/lib/" base.package.conf ghc-pkg update base.package.conf +# haskell-platform +curl --silent http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz|tar xz +cd haskell-platform-2011.4.0.0 +./configure +make +make install +cd .. + # cabal-install curl --silent http://hackage.haskell.org/packages/archive/cabal-install/1.16.0.1/cabal-install-1.16.0.1.tar.gz|tar xz cd cabal-install-1.16.0.1/ From abaaadc047d16f8bb00f79f494f2d54718591156 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:40:33 +0100 Subject: [PATCH 072/217] Add Haskell-Platform download --- bin/compile | 7 +++++++ precompile-binaries.sh | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index f49cdab..4a9ffa8 100755 --- a/bin/compile +++ b/bin/compile @@ -21,6 +21,13 @@ if [ -e $CACHE_DIR/dotghc ]; then mv $CACHE_DIR/dotghc $HOME/.ghc fi +# Download Haskell Platform +if [ ! -e $HOME/.cabal ]; then + HP_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/platform.tar.gz" + echo "-----> Downloading Haskell Platfrom" + curl -# --max-time 120 -L "$HP_URL" | tar xz -C $HOME +fi + # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal diff --git a/precompile-binaries.sh b/precompile-binaries.sh index 87b1755..cf831c1 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -51,7 +51,7 @@ ghc-pkg update base.package.conf # haskell-platform curl --silent http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz|tar xz cd haskell-platform-2011.4.0.0 -./configure +./configure --prefix=$HOME/platform make make install cd .. From 2922e835ec5ae9e500f4a741d7ecdb04acf6f9a7 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:46:30 +0100 Subject: [PATCH 073/217] Add Haskell-Platform download --- bin/compile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index 4a9ffa8..d8b05e4 100755 --- a/bin/compile +++ b/bin/compile @@ -21,12 +21,12 @@ if [ -e $CACHE_DIR/dotghc ]; then mv $CACHE_DIR/dotghc $HOME/.ghc fi -# Download Haskell Platform -if [ ! -e $HOME/.cabal ]; then - HP_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/platform.tar.gz" - echo "-----> Downloading Haskell Platfrom" - curl -# --max-time 120 -L "$HP_URL" | tar xz -C $HOME -fi +# # Download Haskell Platform +# if [ ! -e $HOME/platform ]; then +# HP_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/platform.tar.gz" +# echo "-----> Downloading Haskell Platfrom" +# curl -# --max-time 120 -L "$HP_URL" | tar xz -C $HOME +# fi # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then From dfb68c7dde05dfa32e8f0dba84c4e3e95ca187bc Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:55:54 +0100 Subject: [PATCH 074/217] Add Haskell-Platform download --- bin/compile | 17 ++++++++++------- precompile-binaries.sh | 8 -------- 2 files changed, 10 insertions(+), 15 deletions(-) diff --git a/bin/compile b/bin/compile index d8b05e4..020b4c7 100755 --- a/bin/compile +++ b/bin/compile @@ -10,7 +10,7 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" + GHC_URL="http://s3.amazonaws.com/comuniotest/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi @@ -21,12 +21,15 @@ if [ -e $CACHE_DIR/dotghc ]; then mv $CACHE_DIR/dotghc $HOME/.ghc fi -# # Download Haskell Platform -# if [ ! -e $HOME/platform ]; then -# HP_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/platform.tar.gz" -# echo "-----> Downloading Haskell Platfrom" -# curl -# --max-time 120 -L "$HP_URL" | tar xz -C $HOME -# fi +# haskell-platform +echo "-----> Download and install Haskell Platform" +curl --silent http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz|tar xz +cd haskell-platform-2011.4.0.0 +./configure +make +make install +cd .. + # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then diff --git a/precompile-binaries.sh b/precompile-binaries.sh index cf831c1..ba3234a 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -48,14 +48,6 @@ ghc-pkg describe base > base.package.conf sed -i "s/ld-options:/ld-options:\ -L\/app\/usr\/lib/" base.package.conf ghc-pkg update base.package.conf -# haskell-platform -curl --silent http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz|tar xz -cd haskell-platform-2011.4.0.0 -./configure --prefix=$HOME/platform -make -make install -cd .. - # cabal-install curl --silent http://hackage.haskell.org/packages/archive/cabal-install/1.16.0.1/cabal-install-1.16.0.1.tar.gz|tar xz cd cabal-install-1.16.0.1/ From 48b77031be66299edb9c6d492679f99d8b3b3d30 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:58:35 +0100 Subject: [PATCH 075/217] Add Haskell-Platform download --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 020b4c7..bd65db6 100755 --- a/bin/compile +++ b/bin/compile @@ -23,7 +23,7 @@ fi # haskell-platform echo "-----> Download and install Haskell Platform" -curl --silent http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz|tar xz +curl -# http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz cd haskell-platform-2011.4.0.0 ./configure make From 2349d8cb1bd6c8ede536e225015c2e6cf4b3d4c9 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 16:59:11 +0100 Subject: [PATCH 076/217] Add Haskell-Platform download --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index bd65db6..5ef860f 100755 --- a/bin/compile +++ b/bin/compile @@ -10,7 +10,7 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://s3.amazonaws.com/comuniotest/ghc.tar.gz" + GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi From 762f87d99ce3ae4f2d77c5b1d28d9184130978b0 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:02:18 +0100 Subject: [PATCH 077/217] Add -with-ghc option --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 5ef860f..72f24dc 100755 --- a/bin/compile +++ b/bin/compile @@ -25,7 +25,7 @@ fi echo "-----> Download and install Haskell Platform" curl -# http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz cd haskell-platform-2011.4.0.0 -./configure +./configure -with-ghc=$HOME/ghc/bin/ghc make make install cd .. From b986e80bb1f42758e6712cfc8d4fb4d8e1a7c38e Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:02:56 +0100 Subject: [PATCH 078/217] Add -with-ghc option --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 72f24dc..61a7d26 100755 --- a/bin/compile +++ b/bin/compile @@ -25,7 +25,7 @@ fi echo "-----> Download and install Haskell Platform" curl -# http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz cd haskell-platform-2011.4.0.0 -./configure -with-ghc=$HOME/ghc/bin/ghc +./configure --with-ghc=$HOME/ghc/bin/ghc make make install cd .. From cb1089d887e122541a6d6d515edd0a64ea894c0e Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:09:44 +0100 Subject: [PATCH 079/217] Edit --with-ghc option --- bin/compile | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/bin/compile b/bin/compile index 61a7d26..c9a95ca 100755 --- a/bin/compile +++ b/bin/compile @@ -21,16 +21,6 @@ if [ -e $CACHE_DIR/dotghc ]; then mv $CACHE_DIR/dotghc $HOME/.ghc fi -# haskell-platform -echo "-----> Download and install Haskell Platform" -curl -# http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz -cd haskell-platform-2011.4.0.0 -./configure --with-ghc=$HOME/ghc/bin/ghc -make -make install -cd .. - - # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal @@ -52,6 +42,15 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH +# haskell-platform +echo "-----> Download and install Haskell Platform" +curl -# http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz +cd haskell-platform-2011.4.0.0 +./configure --with-ghc=$CACHE_DIR/ghc/bin/ghc +make +make install +cd .. + echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf From 9c0e10875abfe8b611d6a2f9b136782f3dc389fc Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:12:06 +0100 Subject: [PATCH 080/217] Change Haskell Platform version to 2012 --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index c9a95ca..d1c86b8 100755 --- a/bin/compile +++ b/bin/compile @@ -44,8 +44,8 @@ PATH=$CACHE_DIR/ghc/bin:$PATH # haskell-platform echo "-----> Download and install Haskell Platform" -curl -# http://lambda.haskell.org/platform/download/2011.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz -cd haskell-platform-2011.4.0.0 +curl -# http://lambda.haskell.org/platform/download/2012.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz +cd haskell-platform-2012.4.0.0 ./configure --with-ghc=$CACHE_DIR/ghc/bin/ghc make make install From b9b5a9203719ab0ab4dd65532ef1132b71d4cd0d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:19:41 +0100 Subject: [PATCH 081/217] Change Haskell Platform version to 2012 --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index d1c86b8..073bbd0 100755 --- a/bin/compile +++ b/bin/compile @@ -44,9 +44,9 @@ PATH=$CACHE_DIR/ghc/bin:$PATH # haskell-platform echo "-----> Download and install Haskell Platform" -curl -# http://lambda.haskell.org/platform/download/2012.4.0.0/haskell-platform-2011.4.0.0.tar.gz | tar xz +curl -# http://lambda.haskell.org/platform/download/2012.4.0.0/haskell-platform-2012.4.0.0.tar.gz | tar xz cd haskell-platform-2012.4.0.0 -./configure --with-ghc=$CACHE_DIR/ghc/bin/ghc +./configure make make install cd .. From 873820696c209415416124b46ab7b87a0f7ad5ff Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:21:36 +0100 Subject: [PATCH 082/217] Change Haskell Platform version to 2012.2.0.0 --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 073bbd0..62881ef 100755 --- a/bin/compile +++ b/bin/compile @@ -44,8 +44,8 @@ PATH=$CACHE_DIR/ghc/bin:$PATH # haskell-platform echo "-----> Download and install Haskell Platform" -curl -# http://lambda.haskell.org/platform/download/2012.4.0.0/haskell-platform-2012.4.0.0.tar.gz | tar xz -cd haskell-platform-2012.4.0.0 +curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz +cd haskell-platform-2012.2.0.0 ./configure make make install From 1c6dbacd359ded85c94414ef31837b8fd6d01f2f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:31:28 +0100 Subject: [PATCH 083/217] Change Haskell Platform version to 2012.2.0.0 --- bin/compile | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/bin/compile b/bin/compile index 62881ef..7627abc 100755 --- a/bin/compile +++ b/bin/compile @@ -42,15 +42,6 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -# haskell-platform -echo "-----> Download and install Haskell Platform" -curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz -cd haskell-platform-2012.2.0.0 -./configure -make -make install -cd .. - echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf @@ -63,6 +54,15 @@ rm base.conf ghc-pkg recache ghc-pkg check +# haskell-platform +echo "-----> Download and install Haskell Platform" +curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz +cd haskell-platform-2012.2.0.0 +./configure +make +make install +cd .. + export PATH=$HOME/.cabal/bin:$PATH echo "-----> Updating Cabal" From ca9dcb09dc44e539bee8336960ff5a54f1a96946 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:32:59 +0100 Subject: [PATCH 084/217] Keep hpc-package --- precompile-binaries.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/precompile-binaries.sh b/precompile-binaries.sh index ba3234a..bd4f554 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -18,9 +18,9 @@ rm $HOME/ghc/bin/haddock* rm $HOME/ghc/lib/ghc-7.4.1/haddock rm -r $HOME/ghc/lib/ghc-7.4.1/html rm -r $HOME/ghc/lib/ghc-7.4.1/latex -rm $HOME/ghc/bin/hp* -rm -r $HOME/ghc/lib/ghc-7.4.1/hp* -rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-* +# rm $HOME/ghc/bin/hp* +# rm -r $HOME/ghc/lib/ghc-7.4.1/hp* +# rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-* # rm -r $HOME/ghc/lib/ghc-7.4.1/ghc-7.4.1 # rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/ghc-7.4.1-* # rm -r $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package.cache From c99e0c35217de2e14510207fe061341060199015 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:42:52 +0100 Subject: [PATCH 085/217] Restructure compile --- bin/compile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 7627abc..03e4dbc 100755 --- a/bin/compile +++ b/bin/compile @@ -54,6 +54,9 @@ rm base.conf ghc-pkg recache ghc-pkg check +echo "-----> Check pkg-list" +ghc-pkg list + # haskell-platform echo "-----> Download and install Haskell Platform" curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz @@ -68,9 +71,6 @@ export PATH=$HOME/.cabal/bin:$PATH echo "-----> Updating Cabal" cabal update -echo "-----> Check pkg-list" -ghc-pkg list - echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps From d3c9cbb89fbfba5e5ce828723be049572de1f007 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:44:11 +0100 Subject: [PATCH 086/217] Keep redundant files of ghc installation --- precompile-binaries.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/precompile-binaries.sh b/precompile-binaries.sh index bd4f554..cb72f2e 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -28,12 +28,12 @@ echo "" > $HOME/ghc/lib/ghc-7.4.1/ghc-usage.txt echo "" > $HOME/ghc/lib/ghc-7.4.1/ghci-usage.txt # Remove duplicate libs -find $HOME/ghc/lib -name "*_p.a" -delete -find $HOME/ghc/lib -name "*.p_hi" -delete -find $HOME/ghc/lib -name "*.dyn_hi" -delete -find $HOME/ghc/lib -name "*HS*.so" -delete -find $HOME/ghc/lib -name "*HS*.o" -delete -find $HOME/ghc/lib -name "*_debug.a" -delete +# find $HOME/ghc/lib -name "*_p.a" -delete +# find $HOME/ghc/lib -name "*.p_hi" -delete +# find $HOME/ghc/lib -name "*.dyn_hi" -delete +# find $HOME/ghc/lib -name "*HS*.so" -delete +# find $HOME/ghc/lib -name "*HS*.o" -delete +# find $HOME/ghc/lib -name "*_debug.a" -delete # Don't need man or doc rm -rf $HOME/ghc/share From a29f4d868355aeae490f4667f3ef077ee1bb5c0c Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 17:50:03 +0100 Subject: [PATCH 087/217] Install ghc manually --- bin/compile | 28 +++++++++++++++++----------- precompile-binaries.sh | 12 ++++++------ 2 files changed, 23 insertions(+), 17 deletions(-) diff --git a/bin/compile b/bin/compile index 03e4dbc..bba51b0 100755 --- a/bin/compile +++ b/bin/compile @@ -9,17 +9,23 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR -if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" - echo "-----> Downloading GHC" - curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR -fi - -# Restore GHC registry if available -if [ -e $CACHE_DIR/dotghc ]; then - rm -rf $HOME/.ghc - mv $CACHE_DIR/dotghc $HOME/.ghc -fi +# if [ ! -e $CACHE_DIR/ghc ]; then +# GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" +# echo "-----> Downloading GHC" +# curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR +# fi + +# # Restore GHC registry if available +# if [ -e $CACHE_DIR/dotghc ]; then +# rm -rf $HOME/.ghc +# mv $CACHE_DIR/dotghc $HOME/.ghc +# fi + +curl --silent http://www.haskell.org/ghc/dist/7.4.1/ghc-7.4.1-x86_64-unknown-linux.tar.bz2|tar xj +cd ghc-7.4.1/ +./configure --prefix=$HOME/ghc --with-gmp-libraries=$HOME/usr/lib +make install +cd .. # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then diff --git a/precompile-binaries.sh b/precompile-binaries.sh index cb72f2e..bd4f554 100644 --- a/precompile-binaries.sh +++ b/precompile-binaries.sh @@ -28,12 +28,12 @@ echo "" > $HOME/ghc/lib/ghc-7.4.1/ghc-usage.txt echo "" > $HOME/ghc/lib/ghc-7.4.1/ghci-usage.txt # Remove duplicate libs -# find $HOME/ghc/lib -name "*_p.a" -delete -# find $HOME/ghc/lib -name "*.p_hi" -delete -# find $HOME/ghc/lib -name "*.dyn_hi" -delete -# find $HOME/ghc/lib -name "*HS*.so" -delete -# find $HOME/ghc/lib -name "*HS*.o" -delete -# find $HOME/ghc/lib -name "*_debug.a" -delete +find $HOME/ghc/lib -name "*_p.a" -delete +find $HOME/ghc/lib -name "*.p_hi" -delete +find $HOME/ghc/lib -name "*.dyn_hi" -delete +find $HOME/ghc/lib -name "*HS*.so" -delete +find $HOME/ghc/lib -name "*HS*.o" -delete +find $HOME/ghc/lib -name "*_debug.a" -delete # Don't need man or doc rm -rf $HOME/ghc/share From 154da6093e5be4fd0f93e8a763e88538dc0c78b9 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:15:29 +0100 Subject: [PATCH 088/217] Readd hpc-conf.d --- bin/compile | 30 +++++++--------- ....1.1-aded85d3c95c51273fc3dedd3c91e956.conf | 36 +++++++++++++++++++ 2 files changed, 49 insertions(+), 17 deletions(-) create mode 100644 bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf diff --git a/bin/compile b/bin/compile index bba51b0..178c423 100755 --- a/bin/compile +++ b/bin/compile @@ -9,23 +9,17 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR -# if [ ! -e $CACHE_DIR/ghc ]; then -# GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" -# echo "-----> Downloading GHC" -# curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR -# fi - -# # Restore GHC registry if available -# if [ -e $CACHE_DIR/dotghc ]; then -# rm -rf $HOME/.ghc -# mv $CACHE_DIR/dotghc $HOME/.ghc -# fi - -curl --silent http://www.haskell.org/ghc/dist/7.4.1/ghc-7.4.1-x86_64-unknown-linux.tar.bz2|tar xj -cd ghc-7.4.1/ -./configure --prefix=$HOME/ghc --with-gmp-libraries=$HOME/usr/lib -make install -cd .. +if [ ! -e $CACHE_DIR/ghc ]; then + GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" + echo "-----> Downloading GHC" + curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR +fi + +# Restore GHC registry if available +if [ -e $CACHE_DIR/dotghc ]; then + rm -rf $HOME/.ghc + mv $CACHE_DIR/dotghc $HOME/.ghc +fi # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then @@ -48,6 +42,8 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH +mv hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf $HOME/ghc/lib/ghc-7.4.1/package.conf.d/ + echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf diff --git a/bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf b/bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf new file mode 100644 index 0000000..4a28a68 --- /dev/null +++ b/bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf @@ -0,0 +1,36 @@ +name: hpc +version: 0.5.1.1 +id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956 +license: BSD3 +copyright: +maintainer: libraries@haskell.org +stability: +homepage: +package-url: +synopsis: Code Coverage Library for Haskell +description: +category: Control +author: Andy Gill +exposed: True +exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix + Trace.Hpc.Reflect +hidden-modules: +trusted: False +import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 +library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 +hs-libraries: HShpc-0.5.1.1 +extra-libraries: +extra-ghci-libraries: +include-dirs: +includes: +depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd + containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce + directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 + old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d +hugs-options: +cc-options: +ld-options: +framework-dirs: +frameworks: +haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock +haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1 \ No newline at end of file From 1abf18ef84decd932b0d5a5704978a034aa36863 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:20:12 +0100 Subject: [PATCH 089/217] Readd hpc-conf.d --- .#precompile-binaries.sh | 1 + bin/compile | 39 ++++++++++++++++++++++++++++++++++++++- 2 files changed, 39 insertions(+), 1 deletion(-) create mode 120000 .#precompile-binaries.sh diff --git a/.#precompile-binaries.sh b/.#precompile-binaries.sh new file mode 120000 index 0000000..838a229 --- /dev/null +++ b/.#precompile-binaries.sh @@ -0,0 +1 @@ +ichistmeinname@protheus.localdomain.21456 \ No newline at end of file diff --git a/bin/compile b/bin/compile index 178c423..39ebb3c 100755 --- a/bin/compile +++ b/bin/compile @@ -42,7 +42,44 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -mv hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf $HOME/ghc/lib/ghc-7.4.1/package.conf.d/ +CONF = "name: hpc\n +version: 0.5.1.1\n +id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956\n +license: BSD3\n +copyright:\n +maintainer: libraries@haskell.org\n +stability:\n +homepage:\n +package-url:\n +synopsis: Code Coverage Library for Haskell\n +description:\n +category: Control\n +author: Andy Gill\n +exposed: True\n +exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix + Trace.Hpc.Reflect\n +hidden-modules:\n +trusted: False\n +import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1\n +library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1\n +hs-libraries: HShpc-0.5.1.1\n +extra-libraries:\n +extra-ghci-libraries:\n +include-dirs:\n +includes:\n +depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd + containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce + directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 + old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d\n +hugs-options:\n +cc-options:\n +ld-options:\n +framework-dirs:\n +frameworks:\n +haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock\n +haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" + +mv $CONF > $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf echo "-----> Setting up ghc-pkg" ghc-pkg recache From f9aa8642986783db3ae8f8493644f4ae318db8c1 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:21:57 +0100 Subject: [PATCH 090/217] Readd hpc-conf.d --- .#precompile-binaries.sh | 1 - bin/compile | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) delete mode 120000 .#precompile-binaries.sh diff --git a/.#precompile-binaries.sh b/.#precompile-binaries.sh deleted file mode 120000 index 838a229..0000000 --- a/.#precompile-binaries.sh +++ /dev/null @@ -1 +0,0 @@ -ichistmeinname@protheus.localdomain.21456 \ No newline at end of file diff --git a/bin/compile b/bin/compile index 39ebb3c..45e0edd 100755 --- a/bin/compile +++ b/bin/compile @@ -42,7 +42,7 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -CONF = "name: hpc\n +CONF = $"name: hpc\n version: 0.5.1.1\n id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956\n license: BSD3\n From 3f9b09e93ce7910e51034b4607e61b1d1f36ab7d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:23:48 +0100 Subject: [PATCH 091/217] Readd hpc-conf.d --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 45e0edd..29474f1 100755 --- a/bin/compile +++ b/bin/compile @@ -42,7 +42,7 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -CONF = $"name: hpc\n +CONF="name: hpc\n version: 0.5.1.1\n id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956\n license: BSD3\n From c500c6d6555cc3335139e9ae3e2f6c3be1243c80 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:29:16 +0100 Subject: [PATCH 092/217] Readd hpc-conf.d --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 29474f1..ff9d855 100755 --- a/bin/compile +++ b/bin/compile @@ -79,7 +79,7 @@ frameworks:\n haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock\n haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" -mv $CONF > $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo $CONF > $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf echo "-----> Setting up ghc-pkg" ghc-pkg recache From e481455a9072d3b8b681a2e894e58cc923e91f99 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:31:45 +0100 Subject: [PATCH 093/217] Readd hpc-conf.d --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index ff9d855..5af0caf 100755 --- a/bin/compile +++ b/bin/compile @@ -79,7 +79,7 @@ frameworks:\n haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock\n haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" -echo $CONF > $HOME/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo $CONF > $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf echo "-----> Setting up ghc-pkg" ghc-pkg recache From 06bb7bfcd4e869c3b2d56ee9e300ae0e17c7a0b3 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:33:30 +0100 Subject: [PATCH 094/217] Readd hpc-conf.d --- bin/compile | 62 ++++++++++++++++++++++++++--------------------------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/bin/compile b/bin/compile index 5af0caf..1c54755 100755 --- a/bin/compile +++ b/bin/compile @@ -42,41 +42,41 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -CONF="name: hpc\n -version: 0.5.1.1\n -id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956\n -license: BSD3\n -copyright:\n -maintainer: libraries@haskell.org\n -stability:\n -homepage:\n -package-url:\n -synopsis: Code Coverage Library for Haskell\n -description:\n -category: Control\n -author: Andy Gill\n -exposed: True\n +CONF="name: hpc +version: 0.5.1.1 +id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956 +license: BSD3 +copyright: +maintainer: libraries@haskell.org +stability: +homepage: +package-url: +synopsis: Code Coverage Library for Haskell +description: +category: Control +author: Andy Gill +exposed: True exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix - Trace.Hpc.Reflect\n -hidden-modules:\n -trusted: False\n -import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1\n -library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1\n -hs-libraries: HShpc-0.5.1.1\n -extra-libraries:\n -extra-ghci-libraries:\n -include-dirs:\n -includes:\n + Trace.Hpc.Reflect +hidden-modules: +trusted: False +import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 +library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 +hs-libraries: HShpc-0.5.1.1 +extra-libraries: +extra-ghci-libraries: +include-dirs: +includes: depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 - old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d\n -hugs-options:\n -cc-options:\n -ld-options:\n -framework-dirs:\n -frameworks:\n -haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock\n + old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d +hugs-options: +cc-options: +ld-options: +framework-dirs: +frameworks: +haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" echo $CONF > $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf From 08b183a4ff6385fa9988c5210407b61c5848e1c3 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:34:56 +0100 Subject: [PATCH 095/217] Readd hpc-conf.d --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 1c54755..4773621 100755 --- a/bin/compile +++ b/bin/compile @@ -42,7 +42,7 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -CONF="name: hpc +CONF="name: hpc \n version: 0.5.1.1 id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956 license: BSD3 From 8eb6e2b85abf29349264059995da77fabc151a1b Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:36:52 +0100 Subject: [PATCH 096/217] Readd hpc-conf.d --- bin/compile | 72 ++++++++++++++++++++++++++--------------------------- 1 file changed, 36 insertions(+), 36 deletions(-) diff --git a/bin/compile b/bin/compile index 4773621..95d3aa4 100755 --- a/bin/compile +++ b/bin/compile @@ -42,42 +42,42 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -CONF="name: hpc \n -version: 0.5.1.1 -id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956 -license: BSD3 -copyright: -maintainer: libraries@haskell.org -stability: -homepage: -package-url: -synopsis: Code Coverage Library for Haskell -description: -category: Control -author: Andy Gill -exposed: True -exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix - Trace.Hpc.Reflect -hidden-modules: -trusted: False -import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 -library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 -hs-libraries: HShpc-0.5.1.1 -extra-libraries: -extra-ghci-libraries: -include-dirs: -includes: -depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd - containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce - directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 - old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d -hugs-options: -cc-options: -ld-options: -framework-dirs: -frameworks: -haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock -haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" +CONF="name: hpc" +# version: 0.5.1.1 +# id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956 +# license: BSD3 +# copyright: +# maintainer: libraries@haskell.org +# stability: +# homepage: +# package-url: +# synopsis: Code Coverage Library for Haskell +# description: +# category: Control +# author: Andy Gill +# exposed: True +# exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix +# Trace.Hpc.Reflect +# hidden-modules: +# trusted: False +# import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 +# library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 +# hs-libraries: HShpc-0.5.1.1 +# extra-libraries: +# extra-ghci-libraries: +# include-dirs: +# includes: +# depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd +# containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce +# directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 +# old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d +# hugs-options: +# cc-options: +# ld-options: +# framework-dirs: +# frameworks: +# haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock +# haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" echo $CONF > $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf From f4b2e8b08572a2177e52edf18dc3f2ec35db879c Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:44:22 +0100 Subject: [PATCH 097/217] Readd hpc-conf.d --- bin/compile | 73 +++++++++++++++++++++++++---------------------------- 1 file changed, 35 insertions(+), 38 deletions(-) diff --git a/bin/compile b/bin/compile index 95d3aa4..865e016 100755 --- a/bin/compile +++ b/bin/compile @@ -42,44 +42,41 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -CONF="name: hpc" -# version: 0.5.1.1 -# id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956 -# license: BSD3 -# copyright: -# maintainer: libraries@haskell.org -# stability: -# homepage: -# package-url: -# synopsis: Code Coverage Library for Haskell -# description: -# category: Control -# author: Andy Gill -# exposed: True -# exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix -# Trace.Hpc.Reflect -# hidden-modules: -# trusted: False -# import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 -# library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 -# hs-libraries: HShpc-0.5.1.1 -# extra-libraries: -# extra-ghci-libraries: -# include-dirs: -# includes: -# depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd -# containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce -# directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 -# old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d -# hugs-options: -# cc-options: -# ld-options: -# framework-dirs: -# frameworks: -# haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock -# haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" - -echo $CONF > $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "name: hpc" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +eco "version: 0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "license: BSD3" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "copyright:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "maintainer: libraries@haskell.org" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "stability:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "homepage:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "package-url:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "synopsis: Code Coverage Library for Haskell" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "description:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "category: Control" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "author: Andy Gill" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "exposed: True" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix Trace.Hpc.Reflect" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "hidden-modules:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "trusted: False" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "hs-libraries: HShpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "extra-libraries:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "extra-ghci-libraries:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "include-dirs:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "includes:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd + containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce + directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 + old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "hugs-options:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "cc-options:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "ld-options:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "framework-dirs:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "frameworks:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf echo "-----> Setting up ghc-pkg" ghc-pkg recache From 575c7e7870a0ae8bff24bb3b58a8490adf6f12ea Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Mon, 11 Mar 2013 18:46:45 +0100 Subject: [PATCH 098/217] Readd hpc-conf.d --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 865e016..f7d947a 100755 --- a/bin/compile +++ b/bin/compile @@ -43,7 +43,7 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH echo "name: hpc" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -eco "version: 0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +echo "version: 0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf echo "id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf echo "license: BSD3" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf echo "copyright:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf From 340caa7ec7c71c7636cb05dd1ab8ba93dd2db3c5 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 08:33:04 +0100 Subject: [PATCH 099/217] Use other ghc-precompile --- bin/compile | 38 +------------------------------------- 1 file changed, 1 insertion(+), 37 deletions(-) diff --git a/bin/compile b/bin/compile index f7d947a..6d03019 100755 --- a/bin/compile +++ b/bin/compile @@ -10,7 +10,7 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" + GHC_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi @@ -42,42 +42,6 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -echo "name: hpc" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "version: 0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "license: BSD3" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "copyright:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "maintainer: libraries@haskell.org" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "stability:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "homepage:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "package-url:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "synopsis: Code Coverage Library for Haskell" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "description:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "category: Control" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "author: Andy Gill" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "exposed: True" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix Trace.Hpc.Reflect" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "hidden-modules:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "trusted: False" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "hs-libraries: HShpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "extra-libraries:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "extra-ghci-libraries:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "include-dirs:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "includes:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd - containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce - directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 - old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "hugs-options:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "cc-options:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "ld-options:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "framework-dirs:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "frameworks:" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf -echo "haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1" >> $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf - echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf From 323ffd83949d883f15e9e7688b88a9ba5bec288f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 08:40:03 +0100 Subject: [PATCH 100/217] Restructure compilation --- bin/compile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 6d03019..8e8a46b 100755 --- a/bin/compile +++ b/bin/compile @@ -42,6 +42,9 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH +echo "-----> Check pkg-list" +ghc-pkg list + echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf @@ -54,9 +57,6 @@ rm base.conf ghc-pkg recache ghc-pkg check -echo "-----> Check pkg-list" -ghc-pkg list - # haskell-platform echo "-----> Download and install Haskell Platform" curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz From ca5b7652bdfafd2e1d88679a1495a078f561df6b Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 08:41:42 +0100 Subject: [PATCH 101/217] Restructure compilation --- bin/compile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 8e8a46b..ae538bc 100755 --- a/bin/compile +++ b/bin/compile @@ -42,13 +42,13 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -echo "-----> Check pkg-list" -ghc-pkg list - echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf +echo "-----> Check pkg-list" +ghc-pkg list + sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf ghc-pkg update base.conf From d6b8ac9d78e3f4322addbd86467b8f14abe8c3a6 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 11:47:46 +0100 Subject: [PATCH 102/217] Change download URL --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index ae538bc..cdd676b 100755 --- a/bin/compile +++ b/bin/compile @@ -10,7 +10,7 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://brianmckenna.org/files/heroku-buildpack-haskell/ghc.tar.gz" + GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi @@ -26,7 +26,7 @@ if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal mv $CACHE_DIR/cabal $HOME/.cabal elif [ ! -e $HOME/.cabal ]; then - CABAL_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/cabal.tar.gz" + CABAL_URL="http://informatik.uni-kiel.de/~sad/cabal.tar.gz" echo "-----> Downloading Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi From 2b5819036f0a5b2ab02e05a1f080de05c5388fff Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 11:48:31 +0100 Subject: [PATCH 103/217] Change download URL --- bin/compile | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/bin/compile b/bin/compile index cdd676b..dbd2d90 100755 --- a/bin/compile +++ b/bin/compile @@ -46,9 +46,6 @@ echo "-----> Setting up ghc-pkg" ghc-pkg recache ghc-pkg describe base > base.conf -echo "-----> Check pkg-list" -ghc-pkg list - sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf ghc-pkg update base.conf @@ -57,14 +54,17 @@ rm base.conf ghc-pkg recache ghc-pkg check -# haskell-platform -echo "-----> Download and install Haskell Platform" -curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz -cd haskell-platform-2012.2.0.0 -./configure -make -make install -cd .. +echo "-----> Check pkg-list" +ghc-pkg list + +# # haskell-platform +# echo "-----> Download and install Haskell Platform" +# curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz +# cd haskell-platform-2012.2.0.0 +# ./configure +# make +# make install +# cd .. export PATH=$HOME/.cabal/bin:$PATH From fb20e821d2a7fae323fe07356f4dcf493484fb22 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 11:57:42 +0100 Subject: [PATCH 104/217] Change download URL --- bin/compile | 65 +++++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 56 insertions(+), 9 deletions(-) diff --git a/bin/compile b/bin/compile index dbd2d90..51e2393 100755 --- a/bin/compile +++ b/bin/compile @@ -57,14 +57,61 @@ ghc-pkg check echo "-----> Check pkg-list" ghc-pkg list -# # haskell-platform -# echo "-----> Download and install Haskell Platform" -# curl -# http://lambda.haskell.org/platform/download/2012.2.0.0/haskell-platform-2012.2.0.0.tar.gz | tar xz -# cd haskell-platform-2012.2.0.0 -# ./configure -# make -# make install -# cd .. +#!/usr/bin/env bash +# bin/compile + +# Fail fast and fail hard. +set -eo pipefail + +BUILD_DIR=$1 +CACHE_DIR=$2 + +mkdir -p $CACHE_DIR + +if [ ! -e $CACHE_DIR/ghc ]; then + GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" + echo "-----> Downloading GHC" + curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR +fi + +# Restore GHC registry if available +if [ -e $CACHE_DIR/dotghc ]; then + rm -rf $HOME/.ghc + mv $CACHE_DIR/dotghc $HOME/.ghc +fi + +# Restore Cabal cache or download an empty environemt +if [ -e $CACHE_DIR/cabal ]; then + rm -rf $HOME/.cabal + mv $CACHE_DIR/cabal $HOME/.cabal +elif [ ! -e $HOME/.cabal ]; then + CABAL_URL="http://informatik.uni-kiel.de/~sad/cabal.tar.gz" + echo "-----> Downloading Cabal" + curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME +fi + +mkdir -p $CACHE_DIR/lib +ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so + +# GHC has shell scripts with a bunch of hardcoded references to +# /home/vagrant/ghc/* +# +# Let's murder it to death. +find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" + +PATH=$CACHE_DIR/ghc/bin:$PATH + +echo "-----> Setting up ghc-pkg" +ghc-pkg recache +ghc-pkg describe base > base.conf + +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +ghc-pkg update base.conf +rm base.conf + +ghc-pkg recache +ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH @@ -85,4 +132,4 @@ mv $HOME/.ghc $CACHE_DIR/dotghc echo "Cache dir size:" du -ms $CACHE_DIR echo "Build dir size:" -du -ms $BUILD_DIR +du -ms $BUILD_DIR \ No newline at end of file From e77a86f96b3fe64559842ba8742859dd5ac80cfe Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:05:06 +0100 Subject: [PATCH 105/217] Test ghc-pkg --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index 51e2393..08f6b7b 100755 --- a/bin/compile +++ b/bin/compile @@ -102,6 +102,7 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH echo "-----> Setting up ghc-pkg" +which ghc-pkg ghc-pkg recache ghc-pkg describe base > base.conf From d8ccecae58ad1cdafb5deef64a74b8e69c041311 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:06:39 +0100 Subject: [PATCH 106/217] Test ghc and /usr/local/heroku/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:/Users/ichistmeinname/Library/Haskell/bin:/Users/ichistmeinname/Documents/programming/pakcs/bin/ --- bin/compile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/compile b/bin/compile index 08f6b7b..74d346d 100755 --- a/bin/compile +++ b/bin/compile @@ -101,6 +101,8 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH +echo $PATH +which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg ghc-pkg recache From e7657c77972aac6b9ae5e9c731208d5d1ce04f32 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:08:10 +0100 Subject: [PATCH 107/217] Test ghc and PATH --- bin/compile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/compile b/bin/compile index 74d346d..6dd3a20 100755 --- a/bin/compile +++ b/bin/compile @@ -101,8 +101,10 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH +echo "-----> Checking ghc" echo $PATH which ghc + echo "-----> Setting up ghc-pkg" which ghc-pkg ghc-pkg recache From e31b2fa9e064a19d384f45281cae7b86b4152486 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:13:42 +0100 Subject: [PATCH 108/217] Fix compile --- bin/compile | 59 ----------------------------------------------------- 1 file changed, 59 deletions(-) diff --git a/bin/compile b/bin/compile index 6dd3a20..94771cb 100755 --- a/bin/compile +++ b/bin/compile @@ -42,65 +42,6 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g PATH=$CACHE_DIR/ghc/bin:$PATH -echo "-----> Setting up ghc-pkg" -ghc-pkg recache -ghc-pkg describe base > base.conf - -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -ghc-pkg update base.conf -rm base.conf - -ghc-pkg recache -ghc-pkg check - -echo "-----> Check pkg-list" -ghc-pkg list - -#!/usr/bin/env bash -# bin/compile - -# Fail fast and fail hard. -set -eo pipefail - -BUILD_DIR=$1 -CACHE_DIR=$2 - -mkdir -p $CACHE_DIR - -if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" - echo "-----> Downloading GHC" - curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR -fi - -# Restore GHC registry if available -if [ -e $CACHE_DIR/dotghc ]; then - rm -rf $HOME/.ghc - mv $CACHE_DIR/dotghc $HOME/.ghc -fi - -# Restore Cabal cache or download an empty environemt -if [ -e $CACHE_DIR/cabal ]; then - rm -rf $HOME/.cabal - mv $CACHE_DIR/cabal $HOME/.cabal -elif [ ! -e $HOME/.cabal ]; then - CABAL_URL="http://informatik.uni-kiel.de/~sad/cabal.tar.gz" - echo "-----> Downloading Cabal" - curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME -fi - -mkdir -p $CACHE_DIR/lib -ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so - -# GHC has shell scripts with a bunch of hardcoded references to -# /home/vagrant/ghc/* -# -# Let's murder it to death. -find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" - -PATH=$CACHE_DIR/ghc/bin:$PATH - echo "-----> Checking ghc" echo $PATH which ghc From 0883c07f05166572bf6c9b31e33b35cb61b37740 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:17:41 +0100 Subject: [PATCH 109/217] Fix compile --- bin/compile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/bin/compile b/bin/compile index 94771cb..ec9df25 100755 --- a/bin/compile +++ b/bin/compile @@ -49,15 +49,15 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg ghc-pkg recache -ghc-pkg describe base > base.conf +# ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -ghc-pkg update base.conf -rm base.conf +# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +# ghc-pkg update base.conf +# rm base.conf -ghc-pkg recache -ghc-pkg check +# ghc-pkg recache +# ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From 5c8e779e43306ddf2895de4a3dd8d81920dc6b2e Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:19:33 +0100 Subject: [PATCH 110/217] Fix compile --- bin/compile | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index ec9df25..af651d0 100755 --- a/bin/compile +++ b/bin/compile @@ -48,16 +48,16 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg -ghc-pkg recache -# ghc-pkg describe base > base.conf +# ghc-pkg recache +ghc-pkg describe base > base.conf -# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -# ghc-pkg update base.conf -# rm base.conf +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +ghc-pkg update base.conf +rm base.conf -# ghc-pkg recache -# ghc-pkg check +ghc-pkg recache +ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From d710ab3e6e3f892466c365fd50904461bca10f87 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:22:36 +0100 Subject: [PATCH 111/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index af651d0..d769e99 100755 --- a/bin/compile +++ b/bin/compile @@ -40,7 +40,7 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # Let's murder it to death. find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" -PATH=$CACHE_DIR/ghc/bin:$PATH +export PATH=$CACHE_DIR/ghc/bin echo "-----> Checking ghc" echo $PATH From 3527dd42ada4a3109ba78f8adab09d0fcaef3e6b Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:27:47 +0100 Subject: [PATCH 112/217] Fix compile --- bin/compile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index d769e99..c52f04f 100755 --- a/bin/compile +++ b/bin/compile @@ -40,7 +40,7 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # Let's murder it to death. find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" -export PATH=$CACHE_DIR/ghc/bin +export PATH=$CACHE_DIR/ghc/bin:$PATH echo "-----> Checking ghc" echo $PATH @@ -48,6 +48,7 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg +/app/tmp/repo.git/.cache/ghc/bin/ghc-pkg recache # ghc-pkg recache ghc-pkg describe base > base.conf From 46076235478581d1e35325087e27de74f796d765 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:32:40 +0100 Subject: [PATCH 113/217] Fix compile --- bin/compile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index c52f04f..9e82819 100755 --- a/bin/compile +++ b/bin/compile @@ -40,7 +40,7 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # Let's murder it to death. find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" -export PATH=$CACHE_DIR/ghc/bin:$PATH +export PATH=$CACHE_DIR/ghc/bin$PATH echo "-----> Checking ghc" echo $PATH @@ -48,17 +48,17 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg -/app/tmp/repo.git/.cache/ghc/bin/ghc-pkg recache +$CACHE_DIR/ghc-pkg recache # ghc-pkg recache -ghc-pkg describe base > base.conf +$CACHE_DIR/ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -ghc-pkg update base.conf +$CACHE_DIR/ghc-pkg update base.conf rm base.conf -ghc-pkg recache -ghc-pkg check +$CACHE_DIR/ghc-pkg recache +$CACHE_DIR/ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From bcdff9dfc727ab055d32728f9ed606e01c358627 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:34:05 +0100 Subject: [PATCH 114/217] Fix compile --- bin/compile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bin/compile b/bin/compile index 9e82819..ebe98e5 100755 --- a/bin/compile +++ b/bin/compile @@ -48,17 +48,17 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg -$CACHE_DIR/ghc-pkg recache +$CACHE_DIR/ghc/bin/ghc-pkg recache # ghc-pkg recache -$CACHE_DIR/ghc-pkg describe base > base.conf +$CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf $CACHE_DIR/ghc-pkg update base.conf rm base.conf -$CACHE_DIR/ghc-pkg recache -$CACHE_DIR/ghc-pkg check +$CACHE_DIR/ghc/bin/ghc-pkg recache +$CACHE_DIR/ghc/bin/ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From 8d830bd4884913cc487e6a2c35fd8c68fd83fd87 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:35:13 +0100 Subject: [PATCH 115/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index ebe98e5..efcfbe6 100755 --- a/bin/compile +++ b/bin/compile @@ -54,7 +54,7 @@ $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -$CACHE_DIR/ghc-pkg update base.conf +$CACHE_DIR/ghc/bin/ghc-pkg update base.conf rm base.conf $CACHE_DIR/ghc/bin/ghc-pkg recache From f8a3b9538932dd17c67eb6d8b3f1aad9d7bbe02d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:38:48 +0100 Subject: [PATCH 116/217] Fix compile --- bin/compile | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index efcfbe6..f248273 100755 --- a/bin/compile +++ b/bin/compile @@ -49,16 +49,15 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg $CACHE_DIR/ghc/bin/ghc-pkg recache -# ghc-pkg recache -$CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf +# $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -$CACHE_DIR/ghc/bin/ghc-pkg update base.conf -rm base.conf +# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +# $CACHE_DIR/ghc/bin/ghc-pkg update base.conf +# rm base.conf -$CACHE_DIR/ghc/bin/ghc-pkg recache -$CACHE_DIR/ghc/bin/ghc-pkg check +# $CACHE_DIR/ghc/bin/ghc-pkg recache +# $CACHE_DIR/ghc/bin/ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From 67eba667960456578daf6ce550ae8d70507dcc4f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:40:50 +0100 Subject: [PATCH 117/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index f248273..894bfce 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg -$CACHE_DIR/ghc/bin/ghc-pkg recache +app/tmp/repo.git/.cache/ghc/bin/ghc-pkg recache # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From 5e9936485c9422dfda448a78ee27c78b02b4df4e Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:41:48 +0100 Subject: [PATCH 118/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 894bfce..baa47d7 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg -app/tmp/repo.git/.cache/ghc/bin/ghc-pkg recache +/app/tmp/repo.git/.cache/ghc/bin/ghc-pkg recache # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From c11a8811486199c22f3627515540183815fa4d0c Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:43:34 +0100 Subject: [PATCH 119/217] Fix compile --- bin/compile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/compile b/bin/compile index baa47d7..f7d30d4 100755 --- a/bin/compile +++ b/bin/compile @@ -15,6 +15,8 @@ if [ ! -e $CACHE_DIR/ghc ]; then curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi +find ghc + # Restore GHC registry if available if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc From ae8b1b8019c01bb1de60730c10f22f2f5ae8c446 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:49:37 +0100 Subject: [PATCH 120/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index f7d30d4..afe1d36 100755 --- a/bin/compile +++ b/bin/compile @@ -40,7 +40,7 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # /home/vagrant/ghc/* # # Let's murder it to death. -find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" +# find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" export PATH=$CACHE_DIR/ghc/bin$PATH From 4bdb4bb1c712173a87624dd43c043bb7693d522b Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:50:21 +0100 Subject: [PATCH 121/217] Fix compile --- bin/compile | 2 -- 1 file changed, 2 deletions(-) diff --git a/bin/compile b/bin/compile index afe1d36..2a598be 100755 --- a/bin/compile +++ b/bin/compile @@ -15,8 +15,6 @@ if [ ! -e $CACHE_DIR/ghc ]; then curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi -find ghc - # Restore GHC registry if available if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc From 105262e6d38a013fe01db3b17ec0072dd6f003b0 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:53:07 +0100 Subject: [PATCH 122/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 2a598be..d1f1107 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ which ghc echo "-----> Setting up ghc-pkg" which ghc-pkg -/app/tmp/repo.git/.cache/ghc/bin/ghc-pkg recache +/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg recache # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From f5528aad3bb9e22bf32310d1bd3599a75f5d40f0 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 12:55:37 +0100 Subject: [PATCH 123/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index d1f1107..fcf5034 100755 --- a/bin/compile +++ b/bin/compile @@ -38,7 +38,7 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # /home/vagrant/ghc/* # # Let's murder it to death. -# find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" +find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" export PATH=$CACHE_DIR/ghc/bin$PATH From a184934a86ef1cf70053fcdf6e3f5247a33adc23 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:02:15 +0100 Subject: [PATCH 124/217] Fix compile --- bin/compile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index fcf5034..dbde8e7 100755 --- a/bin/compile +++ b/bin/compile @@ -42,9 +42,10 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g export PATH=$CACHE_DIR/ghc/bin$PATH -echo "-----> Checking ghc" -echo $PATH -which ghc +echo "-----> Checking ghc-path" +echo $GHC_PACKAGE_PATH +export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: +ghc-pkg list echo "-----> Setting up ghc-pkg" which ghc-pkg From fe9294eecab97eb8fc3d6c234de565d62c41da6f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:05:48 +0100 Subject: [PATCH 125/217] Fix compile --- bin/compile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index dbde8e7..042a932 100755 --- a/bin/compile +++ b/bin/compile @@ -43,9 +43,8 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g export PATH=$CACHE_DIR/ghc/bin$PATH echo "-----> Checking ghc-path" -echo $GHC_PACKAGE_PATH export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: -ghc-pkg list +echo $GHC_PACKAGE_PATH echo "-----> Setting up ghc-pkg" which ghc-pkg From 9b1ee374a71cb393d17083218e8b8cf2c3734d05 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:09:48 +0100 Subject: [PATCH 126/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 042a932..9a619bd 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ echo $GHC_PACKAGE_PATH echo "-----> Setting up ghc-pkg" which ghc-pkg -/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg recache +/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg package --global-conf=$GHC_PACKAGE_PATH recache # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From 4f5cb3b995790fdeb968d2ff960a0fbb70b8170a Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:12:47 +0100 Subject: [PATCH 127/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 9a619bd..842d89a 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ echo $GHC_PACKAGE_PATH echo "-----> Setting up ghc-pkg" which ghc-pkg -/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg package --global-conf=$GHC_PACKAGE_PATH recache +/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg package recache --global-conf=$GHC_PACKAGE_PATH # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From 15ccc05acf0ef6f3fb3a952f178344c5104f63ac Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:14:46 +0100 Subject: [PATCH 128/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 842d89a..28a46a2 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ echo $GHC_PACKAGE_PATH echo "-----> Setting up ghc-pkg" which ghc-pkg -/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg package recache --global-conf=$GHC_PACKAGE_PATH +/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg package recache --global # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From 8cb5a621e2d07ad30e39273ff47038ceb9099772 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:15:40 +0100 Subject: [PATCH 129/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 28a46a2..025e5b7 100755 --- a/bin/compile +++ b/bin/compile @@ -48,7 +48,7 @@ echo $GHC_PACKAGE_PATH echo "-----> Setting up ghc-pkg" which ghc-pkg -/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg package recache --global +/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From d894d5d4ff7cef4cf1d11384e017298edf2a3c6d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:22:18 +0100 Subject: [PATCH 130/217] Fix compile --- bin/compile | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/bin/compile b/bin/compile index 025e5b7..ac1a66a 100755 --- a/bin/compile +++ b/bin/compile @@ -10,7 +10,7 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" + GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi @@ -42,13 +42,15 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g export PATH=$CACHE_DIR/ghc/bin$PATH -echo "-----> Checking ghc-path" -export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: +echo "-----> Checking ghc-paths" +# export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: echo $GHC_PACKAGE_PATH +echo $PATH +which ghc +which ghc-pkg echo "-----> Setting up ghc-pkg" -which ghc-pkg -/app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +# /app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH # $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From 5815e2e62d2f3fd27ebd7192fed72104bc8d84c0 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:27:08 +0100 Subject: [PATCH 131/217] Fix compile --- bin/compile | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index ac1a66a..5297697 100755 --- a/bin/compile +++ b/bin/compile @@ -50,16 +50,16 @@ which ghc which ghc-pkg echo "-----> Setting up ghc-pkg" -# /app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -# $CACHE_DIR/ghc/bin/ghc-pkg describe base > base.conf +/ghc-pkg recache +ghc-pkg describe base > base.conf -# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -# $CACHE_DIR/ghc/bin/ghc-pkg update base.conf -# rm base.conf +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +ghc-pkg update base.conf +rm base.conf -# $CACHE_DIR/ghc/bin/ghc-pkg recache -# $CACHE_DIR/ghc/bin/ghc-pkg check +$CACHE_DIR/ghc/bin/ghc-pkg recache +$CACHE_DIR/ghc/bin/ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From d14489ccf58ea39c1569bdadc99e04b58f577b89 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 13:28:45 +0100 Subject: [PATCH 132/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 5297697..b103224 100755 --- a/bin/compile +++ b/bin/compile @@ -50,7 +50,7 @@ which ghc which ghc-pkg echo "-----> Setting up ghc-pkg" -/ghc-pkg recache +ghc-pkg recache ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From dce4cfdb4959e82ce4532c42344cfca6f4b539c4 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:05:11 +0100 Subject: [PATCH 133/217] Fix compile --- bin/compile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index b103224..8d995d2 100755 --- a/bin/compile +++ b/bin/compile @@ -10,11 +10,14 @@ CACHE_DIR=$2 mkdir -p $CACHE_DIR if [ ! -e $CACHE_DIR/ghc ]; then - GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" + # GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" + GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi +rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache + # Restore GHC registry if available if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc @@ -58,8 +61,8 @@ perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf ghc-pkg update base.conf rm base.conf -$CACHE_DIR/ghc/bin/ghc-pkg recache -$CACHE_DIR/ghc/bin/ghc-pkg check +ghc-pkg recache +ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From b6a4e12ef9f5c73ecea06770176d0496288691d7 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:07:33 +0100 Subject: [PATCH 134/217] Fix compile --- bin/compile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 8d995d2..91f66fa 100755 --- a/bin/compile +++ b/bin/compile @@ -16,14 +16,15 @@ if [ ! -e $CACHE_DIR/ghc ]; then curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR fi -rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache - # Restore GHC registry if available if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc mv $CACHE_DIR/dotghc $HOME/.ghc fi +rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache + + # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal From 1c05f64f980833060e25afdbd1c6c1a56fa9c67f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:09:40 +0100 Subject: [PATCH 135/217] Fix compile --- bin/compile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 91f66fa..4b1723a 100755 --- a/bin/compile +++ b/bin/compile @@ -22,7 +22,9 @@ if [ -e $CACHE_DIR/dotghc ]; then mv $CACHE_DIR/dotghc $HOME/.ghc fi -rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache +echo $HOME +ls $HOME/.ghc +rm $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package_cache # Restore Cabal cache or download an empty environemt From c44019a7f4408e4a7a6d00e3b99412fd05be0205 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:11:07 +0100 Subject: [PATCH 136/217] Fix compile --- bin/compile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 4b1723a..4c1cc5c 100755 --- a/bin/compile +++ b/bin/compile @@ -20,10 +20,11 @@ fi if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc mv $CACHE_DIR/dotghc $HOME/.ghc + ls $HOME/.ghc fi echo $HOME -ls $HOME/.ghc +ls $HOME rm $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package_cache From 417e7c8560183e2e419f74e90a146e118ee20918 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:13:45 +0100 Subject: [PATCH 137/217] Fix compile --- bin/compile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 4c1cc5c..e870bf2 100755 --- a/bin/compile +++ b/bin/compile @@ -24,7 +24,10 @@ if [ -e $CACHE_DIR/dotghc ]; then fi echo $HOME -ls $HOME +pwd +ls bin +ls tmp +ls lib rm $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package_cache From b11d2b97ab2aa35323ff8beba74f395c7b12c8f9 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:14:54 +0100 Subject: [PATCH 138/217] Fix compile --- bin/compile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/bin/compile b/bin/compile index e870bf2..cef860c 100755 --- a/bin/compile +++ b/bin/compile @@ -24,10 +24,8 @@ if [ -e $CACHE_DIR/dotghc ]; then fi echo $HOME -pwd -ls bin -ls tmp -ls lib +ls +bash rm $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package_cache From c487ddc7305372eaf0262a733e3b87bb2a21d611 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:17:11 +0100 Subject: [PATCH 139/217] Fix compile --- bin/compile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index cef860c..4f1f9f0 100755 --- a/bin/compile +++ b/bin/compile @@ -24,9 +24,11 @@ if [ -e $CACHE_DIR/dotghc ]; then fi echo $HOME -ls -bash -rm $HOME/ghc/lib/ghc-7.4.1/package.conf.d/package_cache +ls /app/bin +ls /app/lib +ls /app/tmp +ls $CACHE_DIR +rm /app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/package.conf.d/package_cache # Restore Cabal cache or download an empty environemt From bfb75f00f2fe5588e5a96de6916631464f44f163 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:18:48 +0100 Subject: [PATCH 140/217] Fix compile --- bin/compile | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index 4f1f9f0..ecb89dd 100755 --- a/bin/compile +++ b/bin/compile @@ -23,12 +23,8 @@ if [ -e $CACHE_DIR/dotghc ]; then ls $HOME/.ghc fi -echo $HOME -ls /app/bin -ls /app/lib -ls /app/tmp -ls $CACHE_DIR -rm /app/tmp/repo.git/.cache/ghc/lib/ghc-7.4.1/package.conf.d/package_cache +ls $CACHE_DIR/ghc +rm /app/tmp/repo.git/ghc/lib/ghc-7.4.1/package.conf.d/package_cache # Restore Cabal cache or download an empty environemt From 9cbf3e78abc365a5180bf25528d945bbb811b618 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:20:07 +0100 Subject: [PATCH 141/217] Fix compile --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index ecb89dd..2e30215 100755 --- a/bin/compile +++ b/bin/compile @@ -23,8 +23,8 @@ if [ -e $CACHE_DIR/dotghc ]; then ls $HOME/.ghc fi -ls $CACHE_DIR/ghc -rm /app/tmp/repo.git/ghc/lib/ghc-7.4.1/package.conf.d/package_cache +ls $CACHE_DIR/ghc/lib +rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache # Restore Cabal cache or download an empty environemt From 48715ff02f77de0b7e5284cae432fc02404ff038 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:21:54 +0100 Subject: [PATCH 142/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 2e30215..9a24765 100755 --- a/bin/compile +++ b/bin/compile @@ -23,7 +23,7 @@ if [ -e $CACHE_DIR/dotghc ]; then ls $HOME/.ghc fi -ls $CACHE_DIR/ghc/lib +ls $CACHE_DIR/ghc/lib/ghc-7.4.1 rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache From 0f03c3a5d4ef19285f8fa9fe2a3391b580e187d3 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:23:09 +0100 Subject: [PATCH 143/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 9a24765..a0d77ff 100755 --- a/bin/compile +++ b/bin/compile @@ -23,7 +23,7 @@ if [ -e $CACHE_DIR/dotghc ]; then ls $HOME/.ghc fi -ls $CACHE_DIR/ghc/lib/ghc-7.4.1 +ls $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache From 3ae4c771869f87d35c56c56c5c944a097448ee4a Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:23:59 +0100 Subject: [PATCH 144/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index a0d77ff..ef188fe 100755 --- a/bin/compile +++ b/bin/compile @@ -24,7 +24,7 @@ if [ -e $CACHE_DIR/dotghc ]; then fi ls $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d -rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package_cache +rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package.cache # Restore Cabal cache or download an empty environemt From f1a508623feedc8ea00f6fabe0dcfb9793d0c7c0 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:26:30 +0100 Subject: [PATCH 145/217] Fix compile --- bin/compile | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/bin/compile b/bin/compile index ef188fe..736c6be 100755 --- a/bin/compile +++ b/bin/compile @@ -23,10 +23,6 @@ if [ -e $CACHE_DIR/dotghc ]; then ls $HOME/.ghc fi -ls $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d -rm $CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d/package.cache - - # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal @@ -49,14 +45,14 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g export PATH=$CACHE_DIR/ghc/bin$PATH echo "-----> Checking ghc-paths" -# export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: +export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: echo $GHC_PACKAGE_PATH echo $PATH which ghc which ghc-pkg echo "-----> Setting up ghc-pkg" -ghc-pkg recache +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From 4015ebf84f9ed75122dc64df5dd023832ae7007e Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:29:15 +0100 Subject: [PATCH 146/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 736c6be..3e2c9a7 100755 --- a/bin/compile +++ b/bin/compile @@ -52,7 +52,7 @@ which ghc which ghc-pkg echo "-----> Setting up ghc-pkg" -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf From 693527c65dec6e35f8ded47460cd8c96cd5d9af1 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:37:15 +0100 Subject: [PATCH 147/217] Fix compile --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index 3e2c9a7..73e2b99 100755 --- a/bin/compile +++ b/bin/compile @@ -45,6 +45,7 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g export PATH=$CACHE_DIR/ghc/bin$PATH echo "-----> Checking ghc-paths" +ls /home/vagrant export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: echo $GHC_PACKAGE_PATH echo $PATH From ce2cb362baab2f2b8b7db6d64669f3c170faed8c Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:41:16 +0100 Subject: [PATCH 148/217] Fix compile --- bin/compile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 73e2b99..47001f0 100755 --- a/bin/compile +++ b/bin/compile @@ -36,6 +36,10 @@ fi mkdir -p $CACHE_DIR/lib ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so + +ls /home/vagrant +find $CACHE_DIR/ghc -type + # GHC has shell scripts with a bunch of hardcoded references to # /home/vagrant/ghc/* # @@ -45,7 +49,6 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g export PATH=$CACHE_DIR/ghc/bin$PATH echo "-----> Checking ghc-paths" -ls /home/vagrant export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: echo $GHC_PACKAGE_PATH echo $PATH From 0a927d6154052cfb4003394431044f3f6474d539 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:43:39 +0100 Subject: [PATCH 149/217] Fix compile --- bin/compile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 47001f0..84a7bb3 100755 --- a/bin/compile +++ b/bin/compile @@ -36,9 +36,7 @@ fi mkdir -p $CACHE_DIR/lib ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so - -ls /home/vagrant -find $CACHE_DIR/ghc -type +find $CACHE_DIR/ghc -type f -print0 # GHC has shell scripts with a bunch of hardcoded references to # /home/vagrant/ghc/* From d0bd6fa24c68cff577ffed49154c236512493b59 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:51:30 +0100 Subject: [PATCH 150/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 84a7bb3..d66d766 100755 --- a/bin/compile +++ b/bin/compile @@ -47,7 +47,7 @@ find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/g export PATH=$CACHE_DIR/ghc/bin$PATH echo "-----> Checking ghc-paths" -export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d: +export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d echo $GHC_PACKAGE_PATH echo $PATH which ghc From ae8e9c7f7871a2fed1d7c120a85e018e1bbd634d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:54:41 +0100 Subject: [PATCH 151/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index d66d766..6ff6cab 100755 --- a/bin/compile +++ b/bin/compile @@ -42,7 +42,7 @@ find $CACHE_DIR/ghc -type f -print0 # /home/vagrant/ghc/* # # Let's murder it to death. -find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" +find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" export PATH=$CACHE_DIR/ghc/bin$PATH From 0ac864d9a5283f4aa6db796bbd613f2277d077cb Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 14:55:56 +0100 Subject: [PATCH 152/217] Fix compile --- bin/compile | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index 6ff6cab..52a1b2c 100755 --- a/bin/compile +++ b/bin/compile @@ -42,7 +42,7 @@ find $CACHE_DIR/ghc -type f -print0 # /home/vagrant/ghc/* # # Let's murder it to death. -find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" +# find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" export PATH=$CACHE_DIR/ghc/bin$PATH @@ -55,15 +55,15 @@ which ghc-pkg echo "-----> Setting up ghc-pkg" $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -ghc-pkg describe base > base.conf +# ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -ghc-pkg update base.conf -rm base.conf +# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +# ghc-pkg update base.conf +# rm base.conf -ghc-pkg recache -ghc-pkg check +# ghc-pkg recache +# ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From 0114c0946ed8743e2f946b88f5f0a4e75250a868 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:05:04 +0100 Subject: [PATCH 153/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 52a1b2c..71e9633 100755 --- a/bin/compile +++ b/bin/compile @@ -36,7 +36,7 @@ fi mkdir -p $CACHE_DIR/lib ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so -find $CACHE_DIR/ghc -type f -print0 +# find $CACHE_DIR/ghc -type f -print0 # GHC has shell scripts with a bunch of hardcoded references to # /home/vagrant/ghc/* From a54085bbc8aadff7ff7b7d25d185f87157893c50 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:06:28 +0100 Subject: [PATCH 154/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 71e9633..9007aee 100755 --- a/bin/compile +++ b/bin/compile @@ -55,7 +55,7 @@ which ghc-pkg echo "-----> Setting up ghc-pkg" $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -# ghc-pkg describe base > base.conf +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf # perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf From 5b14b3c0121250b70685e32988945a3a2139cfde Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:09:36 +0100 Subject: [PATCH 155/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 9007aee..b9e539a 100755 --- a/bin/compile +++ b/bin/compile @@ -55,7 +55,7 @@ which ghc-pkg echo "-----> Setting up ghc-pkg" $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base > base.conf +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf # perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf From ed73654957575a868609a8da0e6e27ce8c520f87 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:13:57 +0100 Subject: [PATCH 156/217] Fix compile --- bin/compile | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index b9e539a..1024abe 100755 --- a/bin/compile +++ b/bin/compile @@ -21,6 +21,8 @@ if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc mv $CACHE_DIR/dotghc $HOME/.ghc ls $HOME/.ghc +# else +# mv $CACHE_DIR $HOME fi # Restore Cabal cache or download an empty environemt @@ -53,17 +55,19 @@ echo $PATH which ghc which ghc-pkg +alias ghc-pkg=$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg + echo "-----> Setting up ghc-pkg" -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf +ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf -# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -# ghc-pkg update base.conf -# rm base.conf +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH +rm base.conf -# ghc-pkg recache -# ghc-pkg check +ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +ghc-pkg check --global-conf=$GHC_PACKAGE_PATH export PATH=$HOME/.cabal/bin:$PATH From a83ed3c0bf6d9c929b6fb06222c3edb867fd20ac Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:15:06 +0100 Subject: [PATCH 157/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 1024abe..26044d0 100755 --- a/bin/compile +++ b/bin/compile @@ -55,7 +55,7 @@ echo $PATH which ghc which ghc-pkg -alias ghc-pkg=$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg +alias ghc-pkg='$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg' echo "-----> Setting up ghc-pkg" ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH From a22ab375a9f866903fb4cc28fe81d5f631cad140 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:17:11 +0100 Subject: [PATCH 158/217] Fix compile --- bin/compile | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/bin/compile b/bin/compile index 26044d0..904ae6e 100755 --- a/bin/compile +++ b/bin/compile @@ -55,19 +55,17 @@ echo $PATH which ghc which ghc-pkg -alias ghc-pkg='$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg' - echo "-----> Setting up ghc-pkg" -ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH rm base.conf -ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -ghc-pkg check --global-conf=$GHC_PACKAGE_PATH +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH export PATH=$HOME/.cabal/bin:$PATH From 87e991e1ce7036a606b9758f34c2e5d1fb04bd1d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:21:52 +0100 Subject: [PATCH 159/217] Fix compile --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 904ae6e..a6fb4f4 100755 --- a/bin/compile +++ b/bin/compile @@ -59,8 +59,8 @@ echo "-----> Setting up ghc-pkg" $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH rm base.conf From d6c1a3c325d5bbcf73be035f0ba3a7299fc6e29b Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:23:22 +0100 Subject: [PATCH 160/217] Fix compile --- bin/compile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index a6fb4f4..7fd70c8 100755 --- a/bin/compile +++ b/bin/compile @@ -61,11 +61,11 @@ $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PA # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf # perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf rm base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From 334d8fa8f68ae4f08cf39ec5de5829b67f3f3c40 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:26:16 +0100 Subject: [PATCH 161/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 7fd70c8..e43a2a6 100755 --- a/bin/compile +++ b/bin/compile @@ -61,7 +61,7 @@ $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PA # sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf # perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH rm base.conf $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache From d471597745317af866af3b8f40b91a7bbbb8d3a2 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:28:27 +0100 Subject: [PATCH 162/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index e43a2a6..27fa559 100755 --- a/bin/compile +++ b/bin/compile @@ -59,7 +59,7 @@ echo "-----> Setting up ghc-pkg" $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf -# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf # perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH rm base.conf From f95271e4e8a701259c471c6f0b5de6e1e3fdb6a6 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:30:13 +0100 Subject: [PATCH 163/217] Fix compile --- bin/compile | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index 27fa559..a5cffcd 100755 --- a/bin/compile +++ b/bin/compile @@ -56,16 +56,16 @@ which ghc which ghc-pkg echo "-----> Setting up ghc-pkg" -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf +# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -# perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH -rm base.conf +# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +# # perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH +# rm base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH export PATH=$HOME/.cabal/bin:$PATH From fc67513d8f00eebc12af2de456cb0b19ff1fd169 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:31:42 +0100 Subject: [PATCH 164/217] Fix compile --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index a5cffcd..9c88976 100755 --- a/bin/compile +++ b/bin/compile @@ -59,8 +59,8 @@ echo "-----> Setting up ghc-pkg" # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf -# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -# # perl -i -p -e "s{/home/vagrant/ghc}{$CACHE_DIR/ghc}g" base.conf +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH # rm base.conf From 521f09fc003b453a105bb146528b7ce7d6dc6e77 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:32:33 +0100 Subject: [PATCH 165/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 9c88976..0bea979 100755 --- a/bin/compile +++ b/bin/compile @@ -57,7 +57,7 @@ which ghc-pkg echo "-----> Setting up ghc-pkg" # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf From 7fc4f16986370a0cb0db058deab21eb8fe983ab6 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:33:31 +0100 Subject: [PATCH 166/217] Fix compile --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 0bea979..dcc6e61 100755 --- a/bin/compile +++ b/bin/compile @@ -61,8 +61,8 @@ $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PA sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf -# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH -# rm base.conf +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf +rm base.conf $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH From 8338f31c39dd7b434493f15be8b709da801ab269 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:35:33 +0100 Subject: [PATCH 167/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index dcc6e61..2d0588a 100755 --- a/bin/compile +++ b/bin/compile @@ -61,7 +61,7 @@ $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PA sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf +$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH rm base.conf $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH From 548b0a38d1d6d3eeb804ce884cdda60ade5bc9a2 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:39:31 +0100 Subject: [PATCH 168/217] Fix compile --- bin/compile | 46 +++++++++++++++++++++++++++++----------------- 1 file changed, 29 insertions(+), 17 deletions(-) diff --git a/bin/compile b/bin/compile index 2d0588a..b5a6dab 100755 --- a/bin/compile +++ b/bin/compile @@ -21,8 +21,8 @@ if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc mv $CACHE_DIR/dotghc $HOME/.ghc ls $HOME/.ghc -# else -# mv $CACHE_DIR $HOME +else + mv $CACHE_DIR $HOME fi # Restore Cabal cache or download an empty environemt @@ -46,26 +46,38 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # Let's murder it to death. # find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" -export PATH=$CACHE_DIR/ghc/bin$PATH +export PATH=$CACHE_DIR/ghc/bin:$HOME/ghc/bin$PATH -echo "-----> Checking ghc-paths" -export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d -echo $GHC_PACKAGE_PATH -echo $PATH -which ghc -which ghc-pkg +# echo "-----> Checking ghc-paths" +# export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d +# echo $GHC_PACKAGE_PATH +# echo $PATH +# which ghc +# which ghc-pkg + +# echo "-----> Setting up ghc-pkg" +# # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH +# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf + +# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +# perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf +# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH +# rm base.conf -echo "-----> Setting up ghc-pkg" # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf +# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH + +echo "-----> Setting up ghc-pkg" +# ghc-pkg recache +# ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH -rm base.conf +# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +# # perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf +# ghc-pkg update base.conf +# rm base.conf -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -$CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH +ghc-pkg recache +ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From 632a3ba1ab0ecbc682cfb2f571c7c00900fa582d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:41:36 +0100 Subject: [PATCH 169/217] Fix compile --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index b5a6dab..2acc862 100755 --- a/bin/compile +++ b/bin/compile @@ -48,10 +48,10 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so export PATH=$CACHE_DIR/ghc/bin:$HOME/ghc/bin$PATH -# echo "-----> Checking ghc-paths" +echo "-----> Checking ghc-paths" # export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d # echo $GHC_PACKAGE_PATH -# echo $PATH +echo $PATH # which ghc # which ghc-pkg From 5e89a4fc3217c722489114453744f4de5ac9482c Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:43:52 +0100 Subject: [PATCH 170/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 2acc862..44b9276 100755 --- a/bin/compile +++ b/bin/compile @@ -46,7 +46,7 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # Let's murder it to death. # find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" -export PATH=$CACHE_DIR/ghc/bin:$HOME/ghc/bin$PATH +export PATH=$CACHE_DIR/ghc/bin:/app/ghc/bin$PATH echo "-----> Checking ghc-paths" # export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d From b59923ae639cf2d84988ec3c100bcecd6ad80855 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:46:24 +0100 Subject: [PATCH 171/217] Fix compile --- bin/compile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/compile b/bin/compile index 44b9276..54a7db0 100755 --- a/bin/compile +++ b/bin/compile @@ -52,6 +52,9 @@ echo "-----> Checking ghc-paths" # export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d # echo $GHC_PACKAGE_PATH echo $PATH +pwd +ls +ls ghc/bin/ # which ghc # which ghc-pkg From 558bcfe72c5e302917014bba3fbf1107f1156252 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:49:50 +0100 Subject: [PATCH 172/217] Fix compile --- bin/compile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/bin/compile b/bin/compile index 54a7db0..dfee94e 100755 --- a/bin/compile +++ b/bin/compile @@ -51,10 +51,8 @@ export PATH=$CACHE_DIR/ghc/bin:/app/ghc/bin$PATH echo "-----> Checking ghc-paths" # export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d # echo $GHC_PACKAGE_PATH -echo $PATH -pwd -ls -ls ghc/bin/ +ls $HOME +ls /app/ghc/bin/ # which ghc # which ghc-pkg From 461906d19975175f7aa896bfbbe9fb5438c4fcea Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:52:33 +0100 Subject: [PATCH 173/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index dfee94e..542bce7 100755 --- a/bin/compile +++ b/bin/compile @@ -52,7 +52,7 @@ echo "-----> Checking ghc-paths" # export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d # echo $GHC_PACKAGE_PATH ls $HOME -ls /app/ghc/bin/ +ls /app # which ghc # which ghc-pkg From a84f3447ef443220ae4e50f05eb776bd0329d553 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 15:57:03 +0100 Subject: [PATCH 174/217] Fix compile --- bin/compile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 542bce7..875fd52 100755 --- a/bin/compile +++ b/bin/compile @@ -22,7 +22,8 @@ if [ -e $CACHE_DIR/dotghc ]; then mv $CACHE_DIR/dotghc $HOME/.ghc ls $HOME/.ghc else - mv $CACHE_DIR $HOME + mv $CACHE_DIR/ghc $HOME + ls $HOME fi # Restore Cabal cache or download an empty environemt From d71720e8e36ded1c19a780b7206a6cd79906161c Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:00:52 +0100 Subject: [PATCH 175/217] Fix compile --- bin/compile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/bin/compile b/bin/compile index 875fd52..90a6088 100755 --- a/bin/compile +++ b/bin/compile @@ -36,8 +36,8 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -mkdir -p $CACHE_DIR/lib -ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so +mkdir -p /app/lib +ln -fs /usr/lib/libgmp.so.3 $/app/lib/libgmp.so # find $CACHE_DIR/ghc -type f -print0 @@ -47,13 +47,13 @@ ln -fs /usr/lib/libgmp.so.3 $CACHE_DIR/lib/libgmp.so # Let's murder it to death. # find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" -export PATH=$CACHE_DIR/ghc/bin:/app/ghc/bin$PATH +export PATH=/app/ghc/bin$PATH echo "-----> Checking ghc-paths" # export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d # echo $GHC_PACKAGE_PATH -ls $HOME -ls /app +# ls $HOME +# ls /app # which ghc # which ghc-pkg From 43b9b5788fc972077e56d674bbce9a81d37f0390 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:01:50 +0100 Subject: [PATCH 176/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 90a6088..4940e17 100755 --- a/bin/compile +++ b/bin/compile @@ -37,7 +37,7 @@ elif [ ! -e $HOME/.cabal ]; then fi mkdir -p /app/lib -ln -fs /usr/lib/libgmp.so.3 $/app/lib/libgmp.so +ln -fs /usr/lib/libgmp.so.3 /app/lib/libgmp.so # find $CACHE_DIR/ghc -type f -print0 From 06f138f277b34b13d18b983ee2f3bb1ec4cc60b4 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:05:04 +0100 Subject: [PATCH 177/217] Fix compile --- bin/compile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 4940e17..9da7c2d 100755 --- a/bin/compile +++ b/bin/compile @@ -23,7 +23,6 @@ if [ -e $CACHE_DIR/dotghc ]; then ls $HOME/.ghc else mv $CACHE_DIR/ghc $HOME - ls $HOME fi # Restore Cabal cache or download an empty environemt @@ -89,7 +88,7 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=$CACHE_DIR/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob From 2074171cab482a467e526d029f250e773c4b0618 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:08:53 +0100 Subject: [PATCH 178/217] Fix compile --- bin/compile | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/bin/compile b/bin/compile index 9da7c2d..aba54dc 100755 --- a/bin/compile +++ b/bin/compile @@ -56,19 +56,18 @@ echo "-----> Checking ghc-paths" # which ghc # which ghc-pkg -# echo "-----> Setting up ghc-pkg" -# # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg describe base --global-conf=$GHC_PACKAGE_PATH > base.conf +echo "-----> Setting up ghc-pkg" +ghc-pkg recache +$ghc-pkg describe base > base.conf -# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf # perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf -# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg update base.conf --global-conf=$GHC_PACKAGE_PATH -# rm base.conf +ghc-pkg update base.conf +rm base.conf # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH -echo "-----> Setting up ghc-pkg" # ghc-pkg recache # ghc-pkg describe base > base.conf From 3cb50cfff84860dd0ea3eacecd89a0d062392c8b Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:10:32 +0100 Subject: [PATCH 179/217] Fix compile --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index aba54dc..1775b49 100755 --- a/bin/compile +++ b/bin/compile @@ -58,7 +58,7 @@ echo "-----> Checking ghc-paths" echo "-----> Setting up ghc-pkg" ghc-pkg recache -$ghc-pkg describe base > base.conf +ghc-pkg describe base > base.conf sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf # perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf @@ -93,7 +93,7 @@ echo "-----> Caching Cabal packages" shopt -s extglob rm $HOME/.cabal/bin/!(cabal|happy) mv $HOME/.cabal $CACHE_DIR/cabal -mv $HOME/.ghc $CACHE_DIR/dotghc +mv $HOME/ghc $CACHE_DIR/dotghc echo "Cache dir size:" du -ms $CACHE_DIR From 1df6142d4fe22553cf8c8b41bb2bf5275e5fe179 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:13:38 +0100 Subject: [PATCH 180/217] Fix compile --- bin/compile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 1775b49..f26c530 100755 --- a/bin/compile +++ b/bin/compile @@ -57,10 +57,11 @@ echo "-----> Checking ghc-paths" # which ghc-pkg echo "-----> Setting up ghc-pkg" +ghc-pkg describe base ghc-pkg recache ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf +sed -i "s#ld-options:#ld-options: -L/app/lib#" base.conf # perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf ghc-pkg update base.conf rm base.conf From 8857d171e5130018e78f24596a501983c37a9537 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:16:12 +0100 Subject: [PATCH 181/217] Fix compile --- bin/compile | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/bin/compile b/bin/compile index f26c530..60b9e43 100755 --- a/bin/compile +++ b/bin/compile @@ -35,8 +35,8 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -mkdir -p /app/lib -ln -fs /usr/lib/libgmp.so.3 /app/lib/libgmp.so +mkdir -p /app/usr/lib +ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so # find $CACHE_DIR/ghc -type f -print0 @@ -57,14 +57,14 @@ echo "-----> Checking ghc-paths" # which ghc-pkg echo "-----> Setting up ghc-pkg" -ghc-pkg describe base -ghc-pkg recache -ghc-pkg describe base > base.conf +ls /usr/lib +# ghc-pkg recache +# ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L/app/lib#" base.conf +# sed -i "s#ld-options:#ld-options: -L/app/lib#" base.conf # perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf -ghc-pkg update base.conf -rm base.conf +# ghc-pkg update base.conf +# rm base.conf # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH # $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH From 44bb1be040250f111250621b8b6551d01ed9f522 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:19:13 +0100 Subject: [PATCH 182/217] Fix compile --- bin/compile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 60b9e43..33d428b 100755 --- a/bin/compile +++ b/bin/compile @@ -56,8 +56,14 @@ echo "-----> Checking ghc-paths" # which ghc # which ghc-pkg -echo "-----> Setting up ghc-pkg" +echo "-----> Check local libs" +ls /app/usr/lib + +echo "-----> Check global libs" ls /usr/lib + +echo "-----> Setting up ghc-pkg" + # ghc-pkg recache # ghc-pkg describe base > base.conf From 5d5f7bd999f4422152459cdc71680390d16a67ba Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:25:20 +0100 Subject: [PATCH 183/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 33d428b..3b27bee 100755 --- a/bin/compile +++ b/bin/compile @@ -36,7 +36,7 @@ elif [ ! -e $HOME/.cabal ]; then fi mkdir -p /app/usr/lib -ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so.2 # find $CACHE_DIR/ghc -type f -print0 From 4ba08166cf1340ba558f01cac410ff357ab50a27 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:28:43 +0100 Subject: [PATCH 184/217] Fix compile --- bin/compile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 3b27bee..a036089 100755 --- a/bin/compile +++ b/bin/compile @@ -35,8 +35,9 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -mkdir -p /app/usr/lib -ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so.2 +cp /usr/lib /app/usr +# mkdir -p /app/usr/lib +# ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so # find $CACHE_DIR/ghc -type f -print0 From 1dadc1ad9b2c49921cb20aec3ffed1bd676ecd13 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:31:17 +0100 Subject: [PATCH 185/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index a036089..82c93d9 100755 --- a/bin/compile +++ b/bin/compile @@ -35,7 +35,7 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -cp /usr/lib /app/usr +cp -R /usr/lib /app/usr # mkdir -p /app/usr/lib # ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so From eef70f88e6987e73ee86621160a47ca4c6a66611 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:35:45 +0100 Subject: [PATCH 186/217] Fix compile --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index 82c93d9..8284df5 100755 --- a/bin/compile +++ b/bin/compile @@ -35,6 +35,7 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi +mkdir -p /app/usr cp -R /usr/lib /app/usr # mkdir -p /app/usr/lib # ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so From 1aa85ff8301dbd7ee0897982084a7e78ed64e20c Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:39:40 +0100 Subject: [PATCH 187/217] Fix compile --- bin/compile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/bin/compile b/bin/compile index 8284df5..65a0323 100755 --- a/bin/compile +++ b/bin/compile @@ -35,10 +35,9 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -mkdir -p /app/usr -cp -R /usr/lib /app/usr -# mkdir -p /app/usr/lib -# ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +mkdir -p /app/usr/lib +ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +# ln -fs /usr/lib /app/usr/lib # find $CACHE_DIR/ghc -type f -print0 From 728e76fcc4c45d0952c23b98fddf5717bab0afa5 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:44:55 +0100 Subject: [PATCH 188/217] Fix compile --- bin/.#compile | 1 + bin/compile | 2 ++ 2 files changed, 3 insertions(+) create mode 120000 bin/.#compile diff --git a/bin/.#compile b/bin/.#compile new file mode 120000 index 0000000..838a229 --- /dev/null +++ b/bin/.#compile @@ -0,0 +1 @@ +ichistmeinname@protheus.localdomain.21456 \ No newline at end of file diff --git a/bin/compile b/bin/compile index 65a0323..08e597e 100755 --- a/bin/compile +++ b/bin/compile @@ -37,6 +37,8 @@ fi mkdir -p /app/usr/lib ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +ln -fs /usr/lib/libgmp.so.3 /usr/lib/libgmp.so + # ln -fs /usr/lib /app/usr/lib # find $CACHE_DIR/ghc -type f -print0 From 72c9fef61fd8d9a7344b1317f7c62bde7b731d09 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:47:25 +0100 Subject: [PATCH 189/217] Fix compile --- bin/.#compile | 1 - bin/compile | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) delete mode 120000 bin/.#compile diff --git a/bin/.#compile b/bin/.#compile deleted file mode 120000 index 838a229..0000000 --- a/bin/.#compile +++ /dev/null @@ -1 +0,0 @@ -ichistmeinname@protheus.localdomain.21456 \ No newline at end of file diff --git a/bin/compile b/bin/compile index 08e597e..6780a10 100755 --- a/bin/compile +++ b/bin/compile @@ -35,12 +35,12 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi +ldd /app/ghc/lib/ghc-7.0.3/ghc + mkdir -p /app/usr/lib ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so ln -fs /usr/lib/libgmp.so.3 /usr/lib/libgmp.so -# ln -fs /usr/lib /app/usr/lib - # find $CACHE_DIR/ghc -type f -print0 # GHC has shell scripts with a bunch of hardcoded references to From b9f32b00232cb380d686df587d1b68e81d8ce371 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:48:57 +0100 Subject: [PATCH 190/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 6780a10..073c638 100755 --- a/bin/compile +++ b/bin/compile @@ -35,7 +35,7 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -ldd /app/ghc/lib/ghc-7.0.3/ghc +ldd /app/ghc/lib/ghc-7.4.1/ghc mkdir -p /app/usr/lib ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so From ec4435602a60a878e49bb44c0a2261af12c5f274 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:50:29 +0100 Subject: [PATCH 191/217] Fix compile --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 073c638..6a99001 100755 --- a/bin/compile +++ b/bin/compile @@ -38,8 +38,8 @@ fi ldd /app/ghc/lib/ghc-7.4.1/ghc mkdir -p /app/usr/lib -ln -fs /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so -ln -fs /usr/lib/libgmp.so.3 /usr/lib/libgmp.so +ln -s /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +sudo ln -s /usr/lib/libgmp.so.3 /usr/lib/libgmp.so # find $CACHE_DIR/ghc -type f -print0 From 1133de9ed2219e6b77a30ceee1a2ea29e15b8b17 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:52:26 +0100 Subject: [PATCH 192/217] Fix compile --- bin/compile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 6a99001..4ab76f7 100755 --- a/bin/compile +++ b/bin/compile @@ -35,11 +35,10 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -ldd /app/ghc/lib/ghc-7.4.1/ghc - mkdir -p /app/usr/lib ln -s /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so -sudo ln -s /usr/lib/libgmp.so.3 /usr/lib/libgmp.so +chmod ugo+w -R /usr/lib +ln -s /usr/lib/libgmp.so.3 /usr/lib/libgmp.so # find $CACHE_DIR/ghc -type f -print0 From 9d3a01530742039932402d7ef3c90391c1e7ae50 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:55:17 +0100 Subject: [PATCH 193/217] Fix compile --- bin/compile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 4ab76f7..cfd87b5 100755 --- a/bin/compile +++ b/bin/compile @@ -34,11 +34,10 @@ elif [ ! -e $HOME/.cabal ]; then echo "-----> Downloading Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi +echo $LD_LIBRARY_PATH mkdir -p /app/usr/lib ln -s /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so -chmod ugo+w -R /usr/lib -ln -s /usr/lib/libgmp.so.3 /usr/lib/libgmp.so # find $CACHE_DIR/ghc -type f -print0 From 5efdb5507d7a1002695c61fad3c9f21095255a8b Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 16:58:58 +0100 Subject: [PATCH 194/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index cfd87b5..3af6d19 100755 --- a/bin/compile +++ b/bin/compile @@ -34,10 +34,10 @@ elif [ ! -e $HOME/.cabal ]; then echo "-----> Downloading Cabal" curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -echo $LD_LIBRARY_PATH mkdir -p /app/usr/lib ln -s /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +LD_LIBRARY_PATH=/usr/lib:/app/usr/lib # find $CACHE_DIR/ghc -type f -print0 From c45c85e3332290fc28e3959deb7d4a42dee1baec Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 17:08:55 +0100 Subject: [PATCH 195/217] Fix compile --- bin/compile | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/bin/compile b/bin/compile index 3af6d19..87294d9 100755 --- a/bin/compile +++ b/bin/compile @@ -35,9 +35,11 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi -mkdir -p /app/usr/lib -ln -s /usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so -LD_LIBRARY_PATH=/usr/lib:/app/usr/lib +mkdir -p /app/usr +cp /usr/lib /app/usr +ln -s /app/usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +export LD_LIBRARY_PATH=/usr/lib:/app/usr/lib +echo $LD_LIBRARY_PATH # find $CACHE_DIR/ghc -type f -print0 @@ -49,14 +51,6 @@ LD_LIBRARY_PATH=/usr/lib:/app/usr/lib export PATH=/app/ghc/bin$PATH -echo "-----> Checking ghc-paths" -# export GHC_PACKAGE_PATH=$CACHE_DIR/ghc/lib/ghc-7.4.1/package.conf.d -# echo $GHC_PACKAGE_PATH -# ls $HOME -# ls /app -# which ghc -# which ghc-pkg - echo "-----> Check local libs" ls /app/usr/lib From cc37125b600bee69d99a6561380ae6b40e4d7292 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 17:13:03 +0100 Subject: [PATCH 196/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 87294d9..bd1bc54 100755 --- a/bin/compile +++ b/bin/compile @@ -36,7 +36,7 @@ elif [ ! -e $HOME/.cabal ]; then fi mkdir -p /app/usr -cp /usr/lib /app/usr +cp -R /usr/lib /app/usr ln -s /app/usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so export LD_LIBRARY_PATH=/usr/lib:/app/usr/lib echo $LD_LIBRARY_PATH From 8990a3782a847229c3d47a2c1d44b5aee160d7fa Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 17:26:30 +0100 Subject: [PATCH 197/217] Fix compile --- bin/compile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index bd1bc54..55a3777 100755 --- a/bin/compile +++ b/bin/compile @@ -37,7 +37,8 @@ fi mkdir -p /app/usr cp -R /usr/lib /app/usr -ln -s /app/usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so +ln -s /app/usr/lib/libgmp.so.3.5.2 /app/usr/lib/libgmp.so +# ln -s /app/usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so export LD_LIBRARY_PATH=/usr/lib:/app/usr/lib echo $LD_LIBRARY_PATH From f9945a97134ddb8c1abdb8dc5d6d36a3f66f0c4e Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 17:35:23 +0100 Subject: [PATCH 198/217] Fix compile --- bin/compile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index 55a3777..e37905d 100755 --- a/bin/compile +++ b/bin/compile @@ -39,8 +39,7 @@ mkdir -p /app/usr cp -R /usr/lib /app/usr ln -s /app/usr/lib/libgmp.so.3.5.2 /app/usr/lib/libgmp.so # ln -s /app/usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so -export LD_LIBRARY_PATH=/usr/lib:/app/usr/lib -echo $LD_LIBRARY_PATH +export LD_LIBRARY_PATH=/app/usr/lib # find $CACHE_DIR/ghc -type f -print0 @@ -90,7 +89,8 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps -LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +# LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +cabal install echo "-----> Caching Cabal packages" shopt -s extglob From 02fa6eaf33e785a23aa541f1366e5e7043aa5e3f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 18:44:24 +0100 Subject: [PATCH 199/217] Fix compile --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index e37905d..68fe595 100755 --- a/bin/compile +++ b/bin/compile @@ -90,7 +90,7 @@ echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps # LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared -cabal install +cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob From 78e9229b92acd23de5429bfbf4de212354c1bc2f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 19:40:54 +0100 Subject: [PATCH 200/217] Fix compile --- bin/compile | 31 ++----------------------------- 1 file changed, 2 insertions(+), 29 deletions(-) diff --git a/bin/compile b/bin/compile index 68fe595..d7863df 100755 --- a/bin/compile +++ b/bin/compile @@ -35,10 +35,10 @@ elif [ ! -e $HOME/.cabal ]; then curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME fi +# Set LD_LIBRARAY_PATH and link essential libraries mkdir -p /app/usr cp -R /usr/lib /app/usr ln -s /app/usr/lib/libgmp.so.3.5.2 /app/usr/lib/libgmp.so -# ln -s /app/usr/lib/libgmp.so.3 /app/usr/lib/libgmp.so export LD_LIBRARY_PATH=/app/usr/lib # find $CACHE_DIR/ghc -type f -print0 @@ -51,34 +51,7 @@ export LD_LIBRARY_PATH=/app/usr/lib export PATH=/app/ghc/bin$PATH -echo "-----> Check local libs" -ls /app/usr/lib - -echo "-----> Check global libs" -ls /usr/lib - -echo "-----> Setting up ghc-pkg" - -# ghc-pkg recache -# ghc-pkg describe base > base.conf - -# sed -i "s#ld-options:#ld-options: -L/app/lib#" base.conf -# perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf -# ghc-pkg update base.conf -# rm base.conf - -# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg recache --global-conf=$GHC_PACKAGE_PATH -# $CACHE_DIR/ghc/lib/ghc-7.4.1/ghc-pkg check --global-conf=$GHC_PACKAGE_PATH - -# ghc-pkg recache -# ghc-pkg describe base > base.conf - -# sed -i "s#ld-options:#ld-options: -L$CACHE_DIR/lib#" base.conf -# # perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" base.conf -# ghc-pkg update base.conf -# rm base.conf - -ghc-pkg recache +echo "-----> Checking ghc-pkg" ghc-pkg check export PATH=$HOME/.cabal/bin:$PATH From 62dcd516ebccc5fe3d170910f33b023b0782e0eb Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 21:36:41 +0100 Subject: [PATCH 201/217] Add verbose level --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index d7863df..d61ad6a 100755 --- a/bin/compile +++ b/bin/compile @@ -63,7 +63,7 @@ echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps # LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared -cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +cabal install -j5 -v3 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob From df6a5518a94993d3ee7ee6b7837547be42ccbf5f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 21:38:48 +0100 Subject: [PATCH 202/217] Add ghc-pkg list --- bin/compile | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/compile b/bin/compile index d61ad6a..9169be0 100755 --- a/bin/compile +++ b/bin/compile @@ -53,6 +53,7 @@ export PATH=/app/ghc/bin$PATH echo "-----> Checking ghc-pkg" ghc-pkg check +ghc-pkg list export PATH=$HOME/.cabal/bin:$PATH From ba6add58b5acc6dc654818eb336558edb6e59531 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Tue, 12 Mar 2013 22:02:53 +0100 Subject: [PATCH 203/217] Remove ghc-pkg list --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 9169be0..ba55469 100755 --- a/bin/compile +++ b/bin/compile @@ -53,7 +53,7 @@ export PATH=/app/ghc/bin$PATH echo "-----> Checking ghc-pkg" ghc-pkg check -ghc-pkg list +# ghc-pkg list export PATH=$HOME/.cabal/bin:$PATH @@ -64,7 +64,7 @@ echo "-----> Release the hounds! Installing application" cd $BUILD_DIR # the ld library path hack is horrible, but let's see if it helps # LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared -cabal install -j5 -v3 --disable-library-profiling --disable-executable-profiling --disable-shared +cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" shopt -s extglob From c0b72875d59d4a75246fa39fc454821adc1d778d Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 08:08:30 +0100 Subject: [PATCH 204/217] Fix typo --- bin/compile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/compile b/bin/compile index ba55469..8b55faf 100755 --- a/bin/compile +++ b/bin/compile @@ -18,9 +18,9 @@ fi # Restore GHC registry if available if [ -e $CACHE_DIR/dotghc ]; then - rm -rf $HOME/.ghc - mv $CACHE_DIR/dotghc $HOME/.ghc - ls $HOME/.ghc + rm -rf $HOME/ghc + mv $CACHE_DIR/dotghc $HOME/ghc + ls $HOME else mv $CACHE_DIR/ghc $HOME fi From b7a67d71ce0353dd6c9f1eb298f84edc873acb1f Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 08:44:01 +0100 Subject: [PATCH 205/217] Cache .ghc directory --- bin/compile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bin/compile b/bin/compile index 8b55faf..5e04bdd 100755 --- a/bin/compile +++ b/bin/compile @@ -20,7 +20,6 @@ fi if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/ghc mv $CACHE_DIR/dotghc $HOME/ghc - ls $HOME else mv $CACHE_DIR/ghc $HOME fi @@ -62,15 +61,16 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR -# the ld library path hack is horrible, but let's see if it helps -# LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared + cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" +echo $HOME/.ghc shopt -s extglob rm $HOME/.cabal/bin/!(cabal|happy) mv $HOME/.cabal $CACHE_DIR/cabal -mv $HOME/ghc $CACHE_DIR/dotghc +mv $HOME/ghc $CACHE_DIR/ghc +mv $HOME/.ghc $CACHE_DIR/dotghc echo "Cache dir size:" du -ms $CACHE_DIR From dc86f954dff387749af83edfb659648f874e12be Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 09:18:23 +0100 Subject: [PATCH 206/217] Cache .ghc directory --- bin/compile | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/bin/compile b/bin/compile index 5e04bdd..3e91d8c 100755 --- a/bin/compile +++ b/bin/compile @@ -18,8 +18,8 @@ fi # Restore GHC registry if available if [ -e $CACHE_DIR/dotghc ]; then - rm -rf $HOME/ghc - mv $CACHE_DIR/dotghc $HOME/ghc + rm -rf $HOME/.ghc + mv $CACHE_DIR/dotghc $HOME/.ghc else mv $CACHE_DIR/ghc $HOME fi @@ -36,18 +36,10 @@ fi # Set LD_LIBRARAY_PATH and link essential libraries mkdir -p /app/usr -cp -R /usr/lib /app/usr +# cp -R /usr/lib /app/usr ln -s /app/usr/lib/libgmp.so.3.5.2 /app/usr/lib/libgmp.so export LD_LIBRARY_PATH=/app/usr/lib -# find $CACHE_DIR/ghc -type f -print0 - -# GHC has shell scripts with a bunch of hardcoded references to -# /home/vagrant/ghc/* -# -# Let's murder it to death. -# find $CACHE_DIR/ghc -type f -print0 | xargs -0 perl -i -p -e "s{/app/ghc}{$CACHE_DIR/ghc}g" - export PATH=/app/ghc/bin$PATH echo "-----> Checking ghc-pkg" @@ -61,7 +53,6 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR - cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" From a74504e77dccddfdd91b61c0cc947d628ddbea77 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 09:32:15 +0100 Subject: [PATCH 207/217] Fix typo --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index 3e91d8c..3428688 100755 --- a/bin/compile +++ b/bin/compile @@ -35,9 +35,9 @@ elif [ ! -e $HOME/.cabal ]; then fi # Set LD_LIBRARAY_PATH and link essential libraries -mkdir -p /app/usr +mkdir -p /app/usr/lib # cp -R /usr/lib /app/usr -ln -s /app/usr/lib/libgmp.so.3.5.2 /app/usr/lib/libgmp.so +ln -s /usr/lib/libgmp.so.3.5.2 /app/usr/lib/libgmp.so export LD_LIBRARY_PATH=/app/usr/lib export PATH=/app/ghc/bin$PATH From 21eba8401c463a4edc2192fac6c715c95faf78f9 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 09:36:16 +0100 Subject: [PATCH 208/217] Move cache to home directory --- bin/.#compile | 1 + bin/compile | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) create mode 120000 bin/.#compile diff --git a/bin/.#compile b/bin/.#compile new file mode 120000 index 0000000..838a229 --- /dev/null +++ b/bin/.#compile @@ -0,0 +1 @@ +ichistmeinname@protheus.localdomain.21456 \ No newline at end of file diff --git a/bin/compile b/bin/compile index 3428688..928d5fa 100755 --- a/bin/compile +++ b/bin/compile @@ -20,10 +20,10 @@ fi if [ -e $CACHE_DIR/dotghc ]; then rm -rf $HOME/.ghc mv $CACHE_DIR/dotghc $HOME/.ghc -else - mv $CACHE_DIR/ghc $HOME fi +mv $CACHE_DIR/ghc $HOME + # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then rm -rf $HOME/.cabal From 83d8d62ebc7572f0a4c48eafe2c1bee2ccce5fe9 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 09:59:28 +0100 Subject: [PATCH 209/217] Fix dirs --- bin/.#compile | 1 - bin/compile | 48 ++++++++++++++++++++++++++---------------------- 2 files changed, 26 insertions(+), 23 deletions(-) delete mode 120000 bin/.#compile diff --git a/bin/.#compile b/bin/.#compile deleted file mode 120000 index 838a229..0000000 --- a/bin/.#compile +++ /dev/null @@ -1 +0,0 @@ -ichistmeinname@protheus.localdomain.21456 \ No newline at end of file diff --git a/bin/compile b/bin/compile index 928d5fa..aac7180 100755 --- a/bin/compile +++ b/bin/compile @@ -7,10 +7,15 @@ set -eo pipefail BUILD_DIR=$1 CACHE_DIR=$2 +FIXED_HOME=/app + mkdir -p $CACHE_DIR +rm -rf $HOME/ghc +rm -rf $HOME/.ghc +rm -rf $HOME/.cabal + if [ ! -e $CACHE_DIR/ghc ]; then - # GHC_URL="http://s3.amazonaws.com/haskell-heroku-buildpack/ghc.tar.gz" GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" echo "-----> Downloading GHC" curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR @@ -18,50 +23,49 @@ fi # Restore GHC registry if available if [ -e $CACHE_DIR/dotghc ]; then - rm -rf $HOME/.ghc - mv $CACHE_DIR/dotghc $HOME/.ghc + rm -rf $FIXED_HOME/app/.ghc + mv $CACHE_DIR/dotghc $FIXED_HOME/.ghc fi -mv $CACHE_DIR/ghc $HOME +# Fix directory +mv $CACHE_DIR/ghc $FIXED_HOME # Restore Cabal cache or download an empty environemt if [ -e $CACHE_DIR/cabal ]; then - rm -rf $HOME/.cabal - mv $CACHE_DIR/cabal $HOME/.cabal -elif [ ! -e $HOME/.cabal ]; then + rm -rf $FIXED_HOME/.cabal + mv $CACHE_DIR/cabal $FIXED_HOME/.cabal +elif [ ! -e $FIXED_HOME/.cabal ]; then CABAL_URL="http://informatik.uni-kiel.de/~sad/cabal.tar.gz" echo "-----> Downloading Cabal" - curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $HOME + curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $FIXED_HOME fi # Set LD_LIBRARAY_PATH and link essential libraries -mkdir -p /app/usr/lib +mkdir -p $FIXED_HOME/usr/lib # cp -R /usr/lib /app/usr -ln -s /usr/lib/libgmp.so.3.5.2 /app/usr/lib/libgmp.so -export LD_LIBRARY_PATH=/app/usr/lib - -export PATH=/app/ghc/bin$PATH +ln -s /usr/lib/libgmp.so.3.5.2 $FIXED_HOME/usr/lib/libgmp.so +export LD_LIBRARY_PATH=$FIXED_HOME/usr/lib -echo "-----> Checking ghc-pkg" -ghc-pkg check -# ghc-pkg list +export PATH=$FIXED_HOME/ghc/bin:$FIXED_HOME/.cabal/bin$PATH -export PATH=$HOME/.cabal/bin:$PATH +# echo "-----> Checking ghc-pkg" +# ghc-pkg check echo "-----> Updating Cabal" cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR +# LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" -echo $HOME/.ghc +echo $FIXED_HOME/.ghc shopt -s extglob -rm $HOME/.cabal/bin/!(cabal|happy) -mv $HOME/.cabal $CACHE_DIR/cabal -mv $HOME/ghc $CACHE_DIR/ghc -mv $HOME/.ghc $CACHE_DIR/dotghc +rm $FIXED_HOME/.cabal/bin/!(cabal|happy) +mv $FIXED_HOME/.cabal $CACHE_DIR/cabal +mv $FIXED_HOME/ghc $CACHE_DIR/ghc +mv $FIXED_HOME/.ghc $CACHE_DIR/dotghc echo "Cache dir size:" du -ms $CACHE_DIR From 831aab6624d7e08a2f4fdc823ac757d8eb7d5cec Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 10:19:15 +0100 Subject: [PATCH 210/217] Remove rm-statements --- bin/compile | 4 ---- 1 file changed, 4 deletions(-) diff --git a/bin/compile b/bin/compile index aac7180..e20fe64 100755 --- a/bin/compile +++ b/bin/compile @@ -11,10 +11,6 @@ FIXED_HOME=/app mkdir -p $CACHE_DIR -rm -rf $HOME/ghc -rm -rf $HOME/.ghc -rm -rf $HOME/.cabal - if [ ! -e $CACHE_DIR/ghc ]; then GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" echo "-----> Downloading GHC" From 48395f2640f8f1ee82fa6406952b72ab2c764c82 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 10:23:03 +0100 Subject: [PATCH 211/217] Tidy up precompile --- bin/compile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/bin/compile b/bin/compile index e20fe64..f4fa3bc 100755 --- a/bin/compile +++ b/bin/compile @@ -38,21 +38,17 @@ fi # Set LD_LIBRARAY_PATH and link essential libraries mkdir -p $FIXED_HOME/usr/lib -# cp -R /usr/lib /app/usr ln -s /usr/lib/libgmp.so.3.5.2 $FIXED_HOME/usr/lib/libgmp.so export LD_LIBRARY_PATH=$FIXED_HOME/usr/lib +# Set PATH export PATH=$FIXED_HOME/ghc/bin:$FIXED_HOME/.cabal/bin$PATH -# echo "-----> Checking ghc-pkg" -# ghc-pkg check - echo "-----> Updating Cabal" cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR -# LD_LIBRARY_PATH=/app/lib cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" From f4580c15d6ad1dbf4baf73cf39bcccd34a264386 Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 10:27:36 +0100 Subject: [PATCH 212/217] Add comments in readme --- README.md | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index e54d2d0..a3fad0c 100644 --- a/README.md +++ b/README.md @@ -3,22 +3,14 @@ This is a [Heroku buildpack](http://devcenter.heroku.com/articles/buildpacks) for Haskell apps. It uses GHC 7.4.1 and cabal-1.16.0.1. -## Demo - -A demo is online here: - -http://haskell-buildpack-demo.herokuapp.com/ - -The demo repo is here: - -https://github.com/pufuwozu/haskell-buildpack-demo +I build this new version of the buildpack to run a slighty newer Yesod version than 1.1.2; currently I only tested it with yesod-1.1.9. ## Usage $ ls Procfile app.cabal src - $ heroku create --stack=cedar --buildpack https://github.com/pufuwozu/heroku-buildpack-haskell.git + $ heroku create --stack=cedar --buildpack https://github.com/ichistmeinname/heroku-buildpack-haskell.git $ git push heroku master ... From a832e81f5384bdb504f807698adec33a4d5b29ae Mon Sep 17 00:00:00 2001 From: Sandra Dylus Date: Wed, 13 Mar 2013 10:29:21 +0100 Subject: [PATCH 213/217] Remove hpc.conf --- ....1.1-aded85d3c95c51273fc3dedd3c91e956.conf | 36 ------------------- 1 file changed, 36 deletions(-) delete mode 100644 bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf diff --git a/bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf b/bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf deleted file mode 100644 index 4a28a68..0000000 --- a/bin/hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956.conf +++ /dev/null @@ -1,36 +0,0 @@ -name: hpc -version: 0.5.1.1 -id: hpc-0.5.1.1-aded85d3c95c51273fc3dedd3c91e956 -license: BSD3 -copyright: -maintainer: libraries@haskell.org -stability: -homepage: -package-url: -synopsis: Code Coverage Library for Haskell -description: -category: Control -author: Andy Gill -exposed: True -exposed-modules: Trace.Hpc.Util Trace.Hpc.Mix Trace.Hpc.Tix - Trace.Hpc.Reflect -hidden-modules: -trusted: False -import-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 -library-dirs: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/lib/ghc-7.4.2/hpc-0.5.1.1 -hs-libraries: HShpc-0.5.1.1 -extra-libraries: -extra-ghci-libraries: -include-dirs: -includes: -depends: base-4.5.1.0-81d626fb996bc7e140a3fd4481b338cd - containers-0.4.2.1-75f143aa39a3e77a1ce2300025bdd8ce - directory-1.1.0.2-72e928d14fc50f31f7e6404839a15691 - old-time-1.1.0.0-b8e05d63ad4954b34fe6dc2bcdddfd5d -hugs-options: -cc-options: -ld-options: -framework-dirs: -frameworks: -haddock-interfaces: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1/hpc.haddock -haddock-html: /Library/Frameworks/GHC.framework/Versions/7.4.2-x86_64/usr/share/doc/ghc/html/libraries/hpc-0.5.1.1 \ No newline at end of file From 5a89bf115c435917ddd72731250d899f9ce43b55 Mon Sep 17 00:00:00 2001 From: Brian McKenna Date: Thu, 9 May 2013 21:33:01 -0600 Subject: [PATCH 214/217] Sync with changes from @ichistmeinname --- README.md | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index a3fad0c..e54d2d0 100644 --- a/README.md +++ b/README.md @@ -3,14 +3,22 @@ This is a [Heroku buildpack](http://devcenter.heroku.com/articles/buildpacks) for Haskell apps. It uses GHC 7.4.1 and cabal-1.16.0.1. -I build this new version of the buildpack to run a slighty newer Yesod version than 1.1.2; currently I only tested it with yesod-1.1.9. +## Demo + +A demo is online here: + +http://haskell-buildpack-demo.herokuapp.com/ + +The demo repo is here: + +https://github.com/pufuwozu/haskell-buildpack-demo ## Usage $ ls Procfile app.cabal src - $ heroku create --stack=cedar --buildpack https://github.com/ichistmeinname/heroku-buildpack-haskell.git + $ heroku create --stack=cedar --buildpack https://github.com/pufuwozu/heroku-buildpack-haskell.git $ git push heroku master ... From 1c56b5d3231af8fac7c509ef80f9295e07d9e6b4 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Mon, 15 Jul 2013 20:17:03 +1000 Subject: [PATCH 215/217] trying to work out why criterion is being pulled in. --- bin/compile | 69 +++++++++++++++++++++++++++++++++-------------------- 1 file changed, 43 insertions(+), 26 deletions(-) diff --git a/bin/compile b/bin/compile index 60b549a..535c59c 100755 --- a/bin/compile +++ b/bin/compile @@ -7,42 +7,59 @@ set -eo pipefail BUILD_DIR=$1 CACHE_DIR=$2 -cd $BUILD_DIR +FIXED_HOME=/app mkdir -p $CACHE_DIR -cp -R $CACHE_DIR/ghc ghc &> /dev/null || true -cp -R $CACHE_DIR/cabal .cabal &> /dev/null || true - -if [ ! -e ghc ]; then - GHC_URL="http://s3.amazonaws.com/heroku-buildpack-haskell/ghc.tar.gz" +if [ ! -e $CACHE_DIR/ghc ]; then + GHC_URL="http://informatik.uni-kiel.de/~sad/ghc.tar.gz" echo "-----> Downloading GHC" - curl -# --max-time 120 -L "$GHC_URL" | tar xz + curl -# --max-time 120 -L "$GHC_URL" | tar xz -C $CACHE_DIR +fi + +# Restore GHC registry if available +if [ -e $CACHE_DIR/dotghc ]; then + rm -rf $FIXED_HOME/app/.ghc + mv $CACHE_DIR/dotghc $FIXED_HOME/.ghc fi -if [ ! -e .cabal ]; then - CABAL_URL="http://s3.amazonaws.com/heroku-buildpack-haskell/cabal.tar.gz" - echo "-----> Bundling Cabal" - curl -# --max-time 120 -L "$CABAL_URL" | tar xz +# Fix directory +mv $CACHE_DIR/ghc $FIXED_HOME + +# Restore Cabal cache or download an empty environemt +if [ -e $CACHE_DIR/cabal ]; then + rm -rf $FIXED_HOME/.cabal + mv $CACHE_DIR/cabal $FIXED_HOME/.cabal +elif [ ! -e $FIXED_HOME/.cabal ]; then + CABAL_URL="http://informatik.uni-kiel.de/~sad/cabal.tar.gz" + echo "-----> Downloading Cabal" + curl -# --max-time 120 -L "$CABAL_URL" | tar xz -C $FIXED_HOME fi -mkdir -p bin -ln -s ghc/bin/ghc bin/ghc -ln -s .cabal/bin/cabal bin/cabal +# Set LD_LIBRARAY_PATH and link essential libraries +mkdir -p $FIXED_HOME/usr/lib +ln -s /usr/lib/libgmp.so.3.5.2 $FIXED_HOME/usr/lib/libgmp.so +export LD_LIBRARY_PATH=$FIXED_HOME/usr/lib -mkdir -p lib -ln -s /usr/lib/libgmp.so.3 lib/libgmp.so +# Set PATH +export PATH=$FIXED_HOME/ghc/bin:$FIXED_HOME/.cabal/bin$PATH -ghc/bin/ghc-pkg describe base > base.conf -sed -i "s#ld-options:#ld-options: -L`pwd`/lib#" -ghc/bin/ghc-pkg update base.conf -rm base.conf +echo "-----> Updating Cabal" +cabal update -.cabal/bin/cabal update -.cabal/bin/cabal install +echo "-----> Release the hounds! Installing application" +cd $BUILD_DIR +cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared --disable-tests -rm -rf $CACHE_DIR/ghc -cp -R ghc $CACHE_DIR/ghc +echo "-----> Caching Cabal packages" +echo $FIXED_HOME/.ghc +shopt -s extglob +rm $FIXED_HOME/.cabal/bin/!(cabal|happy) +mv $FIXED_HOME/.cabal $CACHE_DIR/cabal +mv $FIXED_HOME/ghc $CACHE_DIR/ghc +mv $FIXED_HOME/.ghc $CACHE_DIR/dotghc -rm -rf $CACHE_DIR/cabal -cp -R .cabal $CACHE_DIR/cabal +echo "Cache dir size:" +du -ms $CACHE_DIR +echo "Build dir size:" +du -ms $BUILD_DIR From 2854fa6a89db1eee88e415af0bcf971150c56034 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Mon, 15 Jul 2013 20:42:09 +1000 Subject: [PATCH 216/217] use threaded runtime for compiles --- bin/compile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/compile b/bin/compile index f4fa3bc..44bd31c 100755 --- a/bin/compile +++ b/bin/compile @@ -49,7 +49,7 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR -cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared +cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared -threaded echo "-----> Caching Cabal packages" echo $FIXED_HOME/.ghc @@ -62,4 +62,4 @@ mv $FIXED_HOME/.ghc $CACHE_DIR/dotghc echo "Cache dir size:" du -ms $CACHE_DIR echo "Build dir size:" -du -ms $BUILD_DIR \ No newline at end of file +du -ms $BUILD_DIR From 36c400e8886fdb38aee69c236ba3e75dc9c27206 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Mon, 15 Jul 2013 20:45:09 +1000 Subject: [PATCH 217/217] bad idea, threaded goes in the cabal file --- bin/compile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/compile b/bin/compile index 44bd31c..730c67a 100755 --- a/bin/compile +++ b/bin/compile @@ -49,7 +49,7 @@ cabal update echo "-----> Release the hounds! Installing application" cd $BUILD_DIR -cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared -threaded +cabal install -j5 --disable-library-profiling --disable-executable-profiling --disable-shared echo "-----> Caching Cabal packages" echo $FIXED_HOME/.ghc