diff options
Diffstat (limited to 'src/libstore/build/worker.hh')
-rw-r--r-- | src/libstore/build/worker.hh | 74 |
1 files changed, 37 insertions, 37 deletions
diff --git a/src/libstore/build/worker.hh b/src/libstore/build/worker.hh index 5af93b49e..a741b2672 100644 --- a/src/libstore/build/worker.hh +++ b/src/libstore/build/worker.hh @@ -105,35 +105,59 @@ private: */ std::map<StorePath, bool> pathContentsGoodCache; - void goalFinished(GoalPtr goal, Goal::Finished & f); - void handleWorkResult(GoalPtr goal, Goal::WorkResult how); - -public: - - const Activity act; - const Activity actDerivations; - const Activity actSubstitutions; - /** * Set if at least one derivation had a BuildError (i.e. permanent * failure). */ - bool permanentFailure; + bool permanentFailure = false; /** * Set if at least one derivation had a timeout. */ - bool timedOut; + bool timedOut = false; /** * Set if at least one derivation fails with a hash mismatch. */ - bool hashMismatch; + bool hashMismatch = false; /** * Set if at least one derivation is not deterministic in check mode. */ - bool checkMismatch; + bool checkMismatch = false; + + void goalFinished(GoalPtr goal, Goal::Finished & f); + void handleWorkResult(GoalPtr goal, Goal::WorkResult how); + + /** + * Put `goal` to sleep until a build slot becomes available (which + * might be right away). + */ + void waitForBuildSlot(GoalPtr goal); + + /** + * Wait for a few seconds and then retry this goal. Used when + * waiting for a lock held by another process. This kind of + * polling is inefficient, but POSIX doesn't really provide a way + * to wait for multiple locks in the main select() loop. + */ + void waitForAWhile(GoalPtr goal); + + /** + * Wake up a goal (i.e., there is something for it to do). + */ + void wakeUp(GoalPtr goal); + + /** + * Wait for input to become available. + */ + void waitForInput(); + +public: + + const Activity act; + const Activity actDerivations; + const Activity actSubstitutions; Store & store; Store & evalStore; @@ -206,11 +230,6 @@ public: void removeGoal(GoalPtr goal); /** - * Wake up a goal (i.e., there is something for it to do). - */ - void wakeUp(GoalPtr goal); - - /** * Return the number of local build processes currently running (but not * remote builds via the build hook). */ @@ -234,29 +253,10 @@ public: void childTerminated(Goal * goal); /** - * Put `goal` to sleep until a build slot becomes available (which - * might be right away). - */ - void waitForBuildSlot(GoalPtr goal); - - /** - * Wait for a few seconds and then retry this goal. Used when - * waiting for a lock held by another process. This kind of - * polling is inefficient, but POSIX doesn't really provide a way - * to wait for multiple locks in the main select() loop. - */ - void waitForAWhile(GoalPtr goal); - - /** * Loop until the specified top-level goals have finished. */ void run(const Goals & topGoals); - /** - * Wait for input to become available. - */ - void waitForInput(); - /*** * The exit status in case of failure. * |