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

Unified Diff: tools/gn/target.h

Issue 216903004: Add optional public header checking to GN build (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: unit test Created 6 years, 8 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/setup.cc ('k') | tools/gn/target.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/target.h
diff --git a/tools/gn/target.h b/tools/gn/target.h
index 5e257ec3e53c6c428ed152281f224ea53feb5335..6b8eb99e186bbea2ec042f458c3612faa3956956 100644
--- a/tools/gn/target.h
+++ b/tools/gn/target.h
@@ -69,6 +69,16 @@ class Target : public Item {
const FileList& sources() const { return sources_; }
FileList& sources() { return sources_; }
+ // Set to true when all sources are public. This is the default. In this case
+ // the public headers list should be empty.
+ bool all_headers_public() const { return all_headers_public_; }
+ void set_all_headers_public(bool p) { all_headers_public_ = p; }
+
+ // When all_headers_public is false, this is the list of public headers. It
+ // could be empty which would mean no headers are public.
+ const FileList& public_headers() const { return public_headers_; }
+ FileList& public_headers() { return public_headers_; }
+
// Compile-time extra dependencies.
const FileList& source_prereqs() const { return source_prereqs_; }
FileList& source_prereqs() { return source_prereqs_; }
@@ -145,6 +155,8 @@ class Target : public Item {
std::string output_extension_;
FileList sources_;
+ bool all_headers_public_;
+ FileList public_headers_;
FileList source_prereqs_;
FileList data_;
« no previous file with comments | « tools/gn/setup.cc ('k') | tools/gn/target.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698