/**
  * Propagate recompilation through the dependency chains. Avoid re-tainting packages that have
  * already been compiled.
  */
 public void taintPackagesDependingOnChangedPackages(
     Set<String> pkgs, Set<String> recentlyCompiled) {
   for (Package pkg : prev.packages().values()) {
     for (String dep : pkg.dependencies()) {
       if (pkgs.contains(dep) && !recentlyCompiled.contains(pkg.name())) {
         taintPackage(pkg.name(), " its depending on " + dep);
       }
     }
   }
 }
 /** If artifacts have gone missing, force a recompile of the packages they belong to. */
 public void taintPackagesThatMissArtifacts() {
   for (Package pkg : prev.packages().values()) {
     for (File f : pkg.artifacts().values()) {
       if (!f.exists()) {
         // Hmm, the artifact on disk does not exist! Someone has removed it....
         // Lets rebuild the package.
         taintPackage(pkg.name(), "" + f + " is missing.");
       }
     }
   }
 }