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

Unified Diff: tools/gn/xcode_object.cc

Issue 2591893002: [Refactor Xcode Objects] Allow extra attributes for native targets. (Closed)
Patch Set: Created 4 years 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
« tools/gn/xcode_object.h ('K') | « tools/gn/xcode_object.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/xcode_object.cc
diff --git a/tools/gn/xcode_object.cc b/tools/gn/xcode_object.cc
index e97cbfdb7b1a240fb1df936ed393a2bba13adab2..2c590f8d44ad1df91f27a0b2d8424e140771c046 100644
--- a/tools/gn/xcode_object.cc
+++ b/tools/gn/xcode_object.cc
@@ -667,7 +667,8 @@ void PBXProject::AddNativeTarget(const std::string& name,
const std::string& type,
const std::string& output_name,
const std::string& output_type,
- const std::string& shell_script) {
+ const std::string& shell_script,
+ const PBXAttributes& extra_attributes) {
base::StringPiece ext = FindExtension(&output_name);
PBXFileReference* product = static_cast<PBXFileReference*>(
products_->AddChild(base::MakeUnique<PBXFileReference>(
@@ -680,6 +681,7 @@ void PBXProject::AddNativeTarget(const std::string& name,
: output_name;
PBXAttributes attributes;
sdefresne 2016/12/21 09:39:12 You can use copy construction here instead: P
liaoyuke 2016/12/21 16:59:26 Done.
+ attributes.insert(extra_attributes.begin(), extra_attributes.end());
attributes["CODE_SIGNING_REQUIRED"] = "NO";
attributes["CONFIGURATION_BUILD_DIR"] = ".";
attributes["PRODUCT_NAME"] = product_name;
« tools/gn/xcode_object.h ('K') | « tools/gn/xcode_object.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698