[114696] trunk/dports/lang/ghc/Portfile

cal at macports.org cal at macports.org
Fri Dec 13 16:33:37 PST 2013


Revision: 114696
          https://trac.macports.org/changeset/114696
Author:   cal at macports.org
Date:     2013-12-13 16:33:37 -0800 (Fri, 13 Dec 2013)
Log Message:
-----------
ghc: clean up some files left in place on the buildbot (and probably on other systems, too) due to a bug in the haskell portgroup fixed in r114507

Revision Links:
--------------
    https://trac.macports.org/changeset/114507

Modified Paths:
--------------
    trunk/dports/lang/ghc/Portfile

Modified: trunk/dports/lang/ghc/Portfile
===================================================================
--- trunk/dports/lang/ghc/Portfile	2013-12-13 23:50:59 UTC (rev 114695)
+++ trunk/dports/lang/ghc/Portfile	2013-12-14 00:33:37 UTC (rev 114696)
@@ -9,7 +9,7 @@
 # Do not update GHC separate from Haskell Platform.
 # When updating GHC, make sure to revbump all Haskell ports.
 version             7.6.3
-revision            2
+revision            3
 categories          lang haskell
 maintainers         gmail.com:kitchen.andy cal openmaintainer
 license             BSD
@@ -169,5 +169,45 @@
 }
 
 post-activate {
+    set libprefix "${prefix}/lib/${name}-${version}"
+    # delete old ${prefix}/lib/ghc-${version} directories
+    foreach fullpath [glob -directory ${prefix}/lib ghc-*] {
+        if {$fullpath ne $libprefix} {
+            ui_debug "Cleaning up remnant GHC library directory ${fullpath}"
+            delete $fullpath
+        }
+    }
+
+    set packageconfd "${libprefix}/package.conf.d"
+    set deletefiles [list]
+
+    # files that were not correctly unregistered due to --force missing in the
+    # haskell portgroup, leaving package registrations of packages that still
+    # had dependents in place
+
+    # added 2013-12-14
+    lappend deletefiles "${packageconfd}/Cabal-1.16.0.3-*.conf"
+    lappend deletefiles "${packageconfd}/binary-0.5.1.1-*.conf"
+    lappend deletefiles "${packageconfd}/cereal-0.3.5.2-*.conf"
+    lappend deletefiles "${packageconfd}/cpphs-1.16-*.conf"
+    lappend deletefiles "${packageconfd}/entropy-0.2.2.2-*.conf"
+    lappend deletefiles "${packageconfd}/highlighting-kate-0.5.3.9-*.conf"
+    lappend deletefiles "${packageconfd}/language-c-0.3.2.1-*.conf"
+    lappend deletefiles "${packageconfd}/nats-0.1-*.conf"
+    lappend deletefiles "${packageconfd}/primitive-0.5.0.1-*.conf"
+    lappend deletefiles "${packageconfd}/semigroups-0.11-*.conf"
+    lappend deletefiles "${packageconfd}/semigroups-0.9.2-*.conf"
+    lappend deletefiles "${packageconfd}/template-haskell-2.8.0.0-10af654f73a6befd48e3430f5bf44c21.conf"
+    lappend deletefiles "${packageconfd}/uniplate-1.6.10-*.conf"
+
+    fs-traverse file $packageconfd {
+        foreach pattern $deletefiles {
+            if {[string match $pattern $file]} {
+                ui_debug "Removing remnant package registration file ${file}" 
+                delete $file
+            }
+        }
+    }
+
     catch {system "${prefix}/bin/ghc-pkg -v recache"}
 }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20131213/f1221f94/attachment.html>


More information about the macports-changes mailing list