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

Side by Side Diff: tools/gn/builder.h

Issue 350743004: Allow dependencies of toolchains in GN. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « build/toolchain/gcc_toolchain.gni ('k') | tools/gn/builder.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef TOOLS_GN_BUILDER_H_ 5 #ifndef TOOLS_GN_BUILDER_H_
6 #define TOOLS_GN_BUILDER_H_ 6 #define TOOLS_GN_BUILDER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/containers/hash_tables.h" 10 #include "base/containers/hash_tables.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 50
51 // If there are any undefined references, returns false and sets the error. 51 // If there are any undefined references, returns false and sets the error.
52 bool CheckForBadItems(Err* err) const; 52 bool CheckForBadItems(Err* err) const;
53 53
54 private: 54 private:
55 friend class base::RefCountedThreadSafe<Builder>; 55 friend class base::RefCountedThreadSafe<Builder>;
56 56
57 virtual ~Builder(); 57 virtual ~Builder();
58 58
59 bool TargetDefined(BuilderRecord* record, Err* err); 59 bool TargetDefined(BuilderRecord* record, Err* err);
60 bool ToolchainDefined(BuilderRecord* record, Err* err);
60 61
61 // Returns the record associated with the given label. This function checks 62 // Returns the record associated with the given label. This function checks
62 // that if we already have references for it, the type matches. If no record 63 // that if we already have references for it, the type matches. If no record
63 // exists yet, a new one will be created. 64 // exists yet, a new one will be created.
64 // 65 //
65 // If any of the conditions fail, the return value will be null and the error 66 // If any of the conditions fail, the return value will be null and the error
66 // will be set. request_from is used as the source of the error. 67 // will be set. request_from is used as the source of the error.
67 BuilderRecord* GetOrCreateRecordOfType(const Label& label, 68 BuilderRecord* GetOrCreateRecordOfType(const Label& label,
68 const ParseNode* request_from, 69 const ParseNode* request_from,
69 BuilderRecord::ItemType type, 70 BuilderRecord::ItemType type,
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 // Owning pointers. 127 // Owning pointers.
127 typedef base::hash_map<Label, BuilderRecord*> RecordMap; 128 typedef base::hash_map<Label, BuilderRecord*> RecordMap;
128 RecordMap records_; 129 RecordMap records_;
129 130
130 ResolvedCallback resolved_callback_; 131 ResolvedCallback resolved_callback_;
131 132
132 DISALLOW_COPY_AND_ASSIGN(Builder); 133 DISALLOW_COPY_AND_ASSIGN(Builder);
133 }; 134 };
134 135
135 #endif // TOOLS_GN_BUILDER_H_ 136 #endif // TOOLS_GN_BUILDER_H_
OLDNEW
« no previous file with comments | « build/toolchain/gcc_toolchain.gni ('k') | tools/gn/builder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698