diff options
author | Joey Hess <joey@kitenet.net> | 2013-05-09 13:08:24 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-05-09 13:08:24 -0400 |
commit | b65f5dc9a5139db0b42b696d71a7f00e619e049e (patch) | |
tree | b7bec0b33ee8d08fafaf448a017d3fada5bd8c0b /standalone | |
parent | 1831d438d8c5b0e2c5e25b40681ef375112d724b (diff) |
add cleancross target
Diffstat (limited to 'standalone')
-rwxr-xr-x | standalone/android/install-haskell-packages | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/standalone/android/install-haskell-packages b/standalone/android/install-haskell-packages index 262e34b30..e03ab1303 100755 --- a/standalone/android/install-haskell-packages +++ b/standalone/android/install-haskell-packages @@ -175,10 +175,14 @@ native_install () { install_pkgs } +cross_path () { + PATH=$HOME/.ghc/android-14/arm-linux-androideabi-4.7/bin:$HOME/.ghc/android-14/arm-linux-androideabi-4.7/arm-linux-androideabi/bin:$PATH +} + cross_install () { echo "Cross install" native= - PATH=$HOME/.ghc/android-14/arm-linux-androideabi-4.7/bin:$HOME/.ghc/android-14/arm-linux-androideabi-4.7/arm-linux-androideabi/bin:$PATH + cross_path if [ ! -e $HOME/.ghc/android-14/arm-linux-androideabi-4.7/cabal/packages/hackage.haskell.org ]; then cabal update fi @@ -192,6 +196,14 @@ case "$mode" in cross) cross_install ;; + cleancross) + # cross install, first removing all currently installed + # packages except those part of ghc + rm -f $(grep -l $HOME/.ghc/android-14/arm-linux-androideabi-4.7/.cabal/lib/ $HOME/.ghc/android-14/arm-linux-androideabi-4.7/lib/ghc-*/package.conf.d/*.conf) + cross_path + ghc-pkg recache + cross_install + ;; "") cross_install native_install |