diff options
author | Marius Kintel <marius@kintel.net> | 2011-11-09 02:18:32 (GMT) |
---|---|---|
committer | Marius Kintel <marius@kintel.net> | 2011-11-09 02:18:32 (GMT) |
commit | 96c480b1bd8da7f4f47d3f67653346052a0a9a5e (patch) | |
tree | 9a719c0d287e3aa8eb8df6a0785600d1106b962d /src/handle_dep.cc | |
parent | 9146f16492b1de0775e81aa7c82d83ccd017c65b (diff) |
Ported QCache and related code away from Qt
Diffstat (limited to 'src/handle_dep.cc')
-rw-r--r-- | src/handle_dep.cc | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/handle_dep.cc b/src/handle_dep.cc index 2a05b4a..d4380f5 100644 --- a/src/handle_dep.cc +++ b/src/handle_dep.cc @@ -1,13 +1,14 @@ #include "handle_dep.h" -#include "myqhash.h" #include <string> #include <sstream> #include <QString> #include <QDir> #include <QSet> #include <stdlib.h> // for system() +#include <boost/unordered_set.hpp> +#include <boost/foreach.hpp> -QSet<std::string> dependencies; +boost::unordered_set<std::string> dependencies; const char *make_command = NULL; void handle_dep(const std::string &filename) @@ -33,9 +34,10 @@ bool write_deps(const std::string &filename, const std::string &output_file) return false; } fprintf(fp, "%s:", output_file.c_str()); - QSetIterator<std::string> i(dependencies); - while (i.hasNext()) - fprintf(fp, " \\\n\t%s", i.next().c_str()); + + BOOST_FOREACH(const std::string &str, dependencies) { + fprintf(fp, " \\\n\t%s", str.c_str()); + } fprintf(fp, "\n"); fclose(fp); return true; |