aboutsummaryrefslogtreecommitdiff
path: root/build2/cli
diff options
context:
space:
mode:
Diffstat (limited to 'build2/cli')
-rw-r--r--build2/cli/rule.cxx31
-rw-r--r--build2/cli/rule.hxx3
2 files changed, 1 insertions, 33 deletions
diff --git a/build2/cli/rule.cxx b/build2/cli/rule.cxx
index 9e925b3..83774a3 100644
--- a/build2/cli/rule.cxx
+++ b/build2/cli/rule.cxx
@@ -174,7 +174,7 @@ namespace build2
switch (a)
{
case perform_update_id: return &perform_update;
- case perform_clean_id: return &perform_clean;
+ case perform_clean_id: return &perform_clean_group; // Standard impl.
default: return noop_recipe; // Configure update.
}
}
@@ -304,34 +304,5 @@ namespace build2
return target_state::changed;
}
-
- target_state compile::
- perform_clean (action a, const target& xt)
- {
- const cli_cxx& t (xt.as<cli_cxx> ());
-
- // The reverse order of update: first delete the files, then clean
- // prerequisites. Also update timestamp in case there are operations
- // after us that could use the information.
- //
- // @@ Can't we use clean_extra() for this?
- //
- bool r (false);
-
- if (t.i != nullptr)
- r = rmfile (t.i->path (), *t.i) || r;
- r = rmfile (t.c->path (), *t.c) || r;
- r = rmfile (t.h->path (), *t.h) || r;
-
- t.mtime (timestamp_nonexistent);
-
- target_state ts (r ? target_state::changed : target_state::unchanged);
-
- // Clean prerequisites.
- //
- ts |= reverse_execute_prerequisites (a, t);
-
- return ts;
- }
}
}
diff --git a/build2/cli/rule.hxx b/build2/cli/rule.hxx
index 6798a6b..9af1da4 100644
--- a/build2/cli/rule.hxx
+++ b/build2/cli/rule.hxx
@@ -29,9 +29,6 @@ namespace build2
static target_state
perform_update (action, const target&);
-
- static target_state
- perform_clean (action, const target&);
};
}
}