[haskell-platform] #190: uninstall-hs should check that system has greator version of GHC or not
haskell-platform
haskell-platform at projects.haskell.org
Fri Jan 6 15:43:37 GMT 2012
#190: uninstall-hs should check that system has greator version of GHC or not
---------------------------+------------------------------------------------
Reporter: shelarcy | Owner: gregorycollins
Type: defect | Status: new
Priority: major | Milestone:
Component: OSX installer | Keywords: uninstall-hs
---------------------------+------------------------------------------------
uninstall-hs works well if system has only Haskell Platform version or
prior version of GHC. But if system has greator version of GHC, uninstall-
hs causes undesirable result.
For example:
My system already has GHC 7.2.2, I installed Haskell Platform 2011.4.0.0
(GHC 7.0.4), and then I installed GHC HEAD's binary pkg for testing. After
testing, I tried to remove GHC HEAD by using uninstall-hs. uninstall-hs
removes /usr/bin/ghc and /usr/bin/cabal symbolic link accidently.
{{{
$ sudo uninstall-hs only 7.5.20111221 --remove
$ ghc -V-bash: /usr/bin/ghc: No such file or directory
$ cabal -V
cabal: unrecognised command: -v (try --help)
}}}
And uninsatll-hs can't parse GHC 7.4.1 RC 1's version.
{{{
$ sudo uninstall-hs only 7.4.0.20111219 --remove
*** couldn't parse version
Usage: uninstall-hs -- find versions on system
uninstall-hs thru VERSION -- remove VERSION and earlier
uninstall-hs only VERSION -- remove only VERSION
uninstall-hs all -- remove all
NOTE: Commands are 'dry run' by default and don't actually delete.
Options (can appear anywhere):
-v --verbose report each path
-n --dry-run only report what would be removed
-s --sh, --script generate a shell script to remove files
-r --rm, --remove actually remove files
-? --help help (this message)
}}}
Okay, /Library/Haskell/doc/start.html says that uninstall-hs can remove
just current and prior version. But there is one more problem. My system
was installed GHC 7.0.4, 7.2.2, and HEAD (7.5.20111221). So, if using
GHC's uninstaller
(/Library/Frameworks/GHC.framework/Versions/<version>/Tools/Uninstaller),
/usr/bin/ghc is changes into GHC 7.2.2 instead of 7.0.4. This is
undesirable result, too.
And same problem occur when uninstall-hs removes Haskell Platform's GHC
7.0.4 if system has greator version....
I think that uninstall-hs should check system has greator version of GHC
or not in /Library/Frameworks/GHC.framework/Versions/ directory.
--
Ticket URL: <http://trac.haskell.org/haskell-platform/ticket/190>
haskell-platform <http://trac.haskell.org/haskell-platform>
The Haskell Platform: a comprehensive and robust collection of Haskell libraries
More information about the Haskell-platform
mailing list