aboutsummaryrefslogtreecommitdiff
path: root/build/config/operation.cxx
blob: 1411ce40177b2294e89916af42f89b48a1e98ebe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
// file      : build/config/operation.cxx -*- C++ -*-
// copyright : Copyright (c) 2014-2015 Code Synthesis Tools CC
// license   : MIT; see accompanying LICENSE file

#include <build/config/operation>

#include <build/diagnostics>

using namespace std;

namespace build
{
  namespace config
  {
    meta_operation_info configure {"configure"};

    // disfigure
    //
    static operation_id
    disfigure_operation_pre (operation_id o)
    {
      return o; // Don't translate default to update.
    }

    static void
    disfigure_load (const path& bf,
                    scope&,
                    const path&,
                    const path&,
                    const location&)
    {
      tracer trace ("disfigure_load");
      level4 ([&]{trace << "skipping " << bf;});
    }

    static void
    disfigure_match (action a,
                     const target_key& tk,
                     const location& l,
                     action_targets& ts)
    {
      tracer trace ("disfigure_match");
      //level4 ([&]{trace << "matching " << t;});
      //ts.push_back (&t);
    }

    static void
    disfigure_execute (action a, const action_targets& ts)
    {
      tracer trace ("execute");


      for (void* v: ts)
      {
        //level4 ([&]{trace << "disfiguring target " << t;});
      }
    }

    meta_operation_info disfigure {
      "disfigure",
      nullptr, // meta-operation pre
      &disfigure_operation_pre,
      &disfigure_load,
      &disfigure_match,
      &disfigure_execute,
      nullptr, // operation post
      nullptr  // meta-operation post
    };
  }
}