Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Unified Diff: tools/gn/config_values.h

Issue 21114002: Add initial prototype for the GN meta-buildsystem. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add owners and readme Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/gn/config.cc ('k') | tools/gn/config_values.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/config_values.h
diff --git a/tools/gn/config_values.h b/tools/gn/config_values.h
new file mode 100644
index 0000000000000000000000000000000000000000..e7c17122af0f724d11d5b629dc0507fbb6d64364
--- /dev/null
+++ b/tools/gn/config_values.h
@@ -0,0 +1,50 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef TOOLS_GN_CONFIG_VALUES_H_
+#define TOOLS_GN_CONFIG_VALUES_H_
+
+#include <string>
+#include <vector>
+
+#include "base/basictypes.h"
+#include "tools/gn/source_dir.h"
+
+// Holds the values (includes, defines, compiler flags, etc.) for a given
+// config or target.
+class ConfigValues {
+ public:
+ ConfigValues();
+ ~ConfigValues();
+
+ const std::vector<SourceDir>& includes() const { return includes_; }
+ void swap_in_includes(std::vector<SourceDir>* lo) { includes_.swap(*lo); }
+
+ const std::vector<std::string>& defines() const { return defines_; }
+ void swap_in_defines(std::vector<std::string>* d) { defines_.swap(*d); }
+
+ const std::vector<std::string>& cflags() const { return cflags_; }
+ void swap_in_cflags(std::vector<std::string>* lo) { cflags_.swap(*lo); }
+
+ const std::vector<std::string>& cflags_c() const { return cflags_c_; }
+ void swap_in_cflags_c(std::vector<std::string>* lo) { cflags_c_.swap(*lo); }
+
+ const std::vector<std::string>& cflags_cc() const { return cflags_cc_; }
+ void swap_in_cflags_cc(std::vector<std::string>* lo) { cflags_cc_.swap(*lo); }
+
+ const std::vector<std::string>& ldflags() const { return ldflags_; }
+ void swap_in_ldflags(std::vector<std::string>* lo) { ldflags_.swap(*lo); }
+
+ private:
+ std::vector<SourceDir> includes_;
+ std::vector<std::string> defines_;
+ std::vector<std::string> cflags_;
+ std::vector<std::string> cflags_c_;
+ std::vector<std::string> cflags_cc_;
+ std::vector<std::string> ldflags_;
+
+ DISALLOW_COPY_AND_ASSIGN(ConfigValues);
+};
+
+#endif // TOOLS_GN_CONFIG_VALUES_H_
« no previous file with comments | « tools/gn/config.cc ('k') | tools/gn/config_values.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698