proper build_selection for clean_build (amending 961285f581e6): e.g. relevant for "isabelle build_doc";
authorwenzelm
Tue Nov 07 21:40:53 2017 +0100 (19 months ago)
changeset 67030a9859e879f38
parent 67029 d6d9fd2559ce
child 67031 22a47374a205
proper build_selection for clean_build (amending 961285f581e6): e.g. relevant for "isabelle build_doc";
src/Pure/Tools/build.scala
     1.1 --- a/src/Pure/Tools/build.scala	Tue Nov 07 21:32:22 2017 +0100
     1.2 +++ b/src/Pure/Tools/build.scala	Tue Nov 07 21:40:53 2017 +0100
     1.3 @@ -391,13 +391,13 @@
     1.4        SHA1.digest(cat_lines(digests.map(_.toString).sorted)).toString
     1.5      }
     1.6  
     1.7 +    val selection1 =
     1.8 +      Sessions.Selection(requirements, all_sessions, base_sessions, exclude_session_groups,
     1.9 +        exclude_sessions, session_groups, sessions) ++ selection
    1.10 +
    1.11      val (selected_sessions, deps) =
    1.12      {
    1.13 -      val selected_sessions0 =
    1.14 -        full_sessions.selection(
    1.15 -            Sessions.Selection(requirements, all_sessions, base_sessions, exclude_session_groups,
    1.16 -              exclude_sessions, session_groups, sessions) ++ selection)
    1.17 -
    1.18 +      val selected_sessions0 = full_sessions.selection(selection1)
    1.19        val deps0 =
    1.20          Sessions.deps(selected_sessions0, full_sessions.global_theories,
    1.21            progress = progress, inlined_files = true, verbose = verbose,
    1.22 @@ -450,7 +450,7 @@
    1.23  
    1.24      // optional cleanup
    1.25      if (clean_build) {
    1.26 -      for (name <- full_sessions.build_descendants(selected_sessions.build_topological_order)) {
    1.27 +      for (name <- full_sessions.build_descendants(full_sessions.build_selection(selection1))) {
    1.28          val files =
    1.29            List(Path.basic(name), store.database(name), store.log(name), store.log_gz(name)).
    1.30              map(store.output_dir + _).filter(_.is_file)