]> git.tdb.fi Git - builder.git/blobdiff - source/target.h
Style update: add spaces around assignment operators
[builder.git] / source / target.h
index 5deb2344b3c00ed72d6253ad0d294d502ba25a89..80c6a17832edf804760f7d640c3e7993d125492d 100644 (file)
@@ -10,6 +10,7 @@ Distributed under the LGPL
 
 #include <list>
 #include <map>
+#include <set>
 #include <string>
 #include <msp/time/timestamp.h>
 
@@ -41,14 +42,14 @@ protected:
        TargetList rdepends;
        bool deps_ready;
 
+       bool preparing;
        bool prepared;
-       bool counted;
 
        Target(Builder &, const Package *, const std::string &);
 public:
        virtual ~Target() { }
 
-       virtual const char *get_type() const=0;
+       virtual const char *get_type() const = 0;
        const std::string &get_name() const { return name; }
        const Package *get_package() const { return package; }
        const Msp::Time::TimeStamp &get_mtime() const { return mtime; }
@@ -60,7 +61,7 @@ public:
        */
        Target *get_buildable_target();
 
-       bool get_buildable() const { return buildable; }
+       bool is_buildable() const { return buildable; }
        bool get_rebuild() const { return rebuild; }
        const std::string &get_rebuild_reason() const { return rebuild_reason; }
        void add_depend(Target *);
@@ -71,7 +72,7 @@ public:
        Finds dependencies for the target.  When all dependencies have been found,
        the function should set deps_ready to true.
        */
-       virtual void find_depends() { deps_ready=true; }
+       virtual void find_depends() { deps_ready = true; }
 
        /**
        Prepares the target by recursively preparing dependencies, then checking
@@ -85,14 +86,6 @@ public:
        */
        Action *build();
 
-       void reset_count() { counted=false; }
-
-       /**
-       Returns the number of targets that need to be rebuilt in order to get this
-       target up-to-date.
-       */
-       virtual unsigned count_rebuild();
-
        /**
        Changes the mtime of the target to the current time.
        */
@@ -111,7 +104,7 @@ protected:
        virtual Action *create_action() =0;
 
        /**
-       Handles for the build_done signal of Action.
+       Handler for the build_done signal of Action.
        */
        virtual void build_done();
 };