#84: generic source hp does not build with generic linux binary ghc
-------------------------------------+--------------------------------------
Reporter: [email protected] | Owner: duncan
Type: defect | Status: new
Priority: critical | Milestone: 2009.4.0
Component: Generic source tarball | Resolution:
Keywords: |
-------------------------------------+--------------------------------------
Comment (by [email protected]):
{{{
A quick(-and-dirty) hot fix: -- code copied from build.sh
---
scripts/install.sh | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
Index: haskell-platform-2009.2.0.2/scripts/install.sh
===================================================================
--- haskell-platform-2009.2.0.2.orig/scripts/install.sh
+++ haskell-platform-2009.2.0.2/scripts/install.sh
@@ -34,13 +34,23 @@ install_pkg () {
fi
}
+# Is this exact version of the package already installed?
+is_pkg_installed () {
+ PKG_VER=$1
+ grep " ${PKG_VER} " installed.packages > /dev/null 2>&1
+}
+
# Actually do something!
cd packages
for pkg in `cat platform.packages`; do
- cd "${pkg}" || die "The directory for the component ${PKG} is missing"
- echo "Installing ${pkg}..."
- install_pkg ${pkg}
- cd ..
+ if is_pkg_installed "${pkg}"; then
+ echo "Platform package ${pkg} is already installed. Skipping..."
+ else
+ cd "${pkg}" || die "The directory for the component ${PKG} is
missing"
+ echo "Installing ${pkg}..."
+ install_pkg ${pkg}
+ cd ..
+ fi
done
echo
}}}
--
Ticket URL: <http://trac.haskell.org/haskell-platform/ticket/84#comment:3>
haskell-platform <http://trac.haskell.org/haskell-platform>
The Haskell Platform: a comprehensive and robust collection of Haskell libraries
_______________________________________________
Haskell-platform mailing list
[email protected]
http://projects.haskell.org/cgi-bin/mailman/listinfo/haskell-platform