3 This file is part of builder
4 Copyright © 2006-2007 Mikko Rasa, Mikkosoft Productions
5 Distributed under the LGPL
8 #ifndef DEPENDENCYCACHE_H_
9 #define DEPENDENCYCACHE_H_
11 #include <msp/time/timestamp.h>
17 Stores dependencies to avoid expensive operations during DAG building phase.
18 The dependencies are stored in a map with target name as key and a list of
19 strings as value. The targets are free to store whatever they want here.
24 DependencyCache(SourcePackage &p);
25 void set_deps(const std::string &tgt, const StringList &d);
26 const StringList &get_deps(const std::string &tgt) const;
27 const Msp::Time::TimeStamp &get_mtime() const { return mtime; }
31 typedef std::map<std::string, StringList> DepsMap;
33 SourcePackage &package;
35 Msp::Time::TimeStamp mtime;