{"action":"created","comment":{"url":"https://api.github.com/repos/facebook/xcbuild/pulls/comments/68511950","id":68511950,"diff_hunk":"@@ -324,15 +327,27 @@ main(int argc, char **argv)\n     /*\n      * Determine the toolchains to use. Default to the SDK's toolchains.\n      */\n-    xcsdk::SDK::Toolchain::vector toolchains = target->toolchains();\n-    if (!toolchain.empty()) {\n+    xcsdk::SDK::Toolchain::vector toolchains;\n+    if (!toolchainsInput.empty()) {\n         /* If the custom toolchain exists, use it instead. */\n-        if (auto TC = manager->findToolchain(toolchain)) {\n-            toolchains = { TC };\n-        } else {\n-            fprintf(stderr, \"error: unable to find toolchain '%s'\\n\", toolchain.c_str());\n+        std::vector<std::string> toolchainTokens;\n+        std::stringstream sstream(toolchainsInput);\n+        copy(std::istream_iterator<std::string>(sstream),\n+             std::istream_iterator<std::string>(),\n+             std::back_inserter(toolchainTokens));","path":"Libraries/xcsdk/Tools/xcrun.cpp","position":41,"original_position":41,"commit_id":"59607830276c509229186a880b76d0f8247951c4","original_commit_id":"59607830276c509229186a880b76d0f8247951c4","user":{"login":"grp","id":163390,"avatar_url":"https://avatars.githubusercontent.com/u/163390?v=3","gravatar_id":"","url":"https://api.github.com/users/grp","html_url":"https://github.com/grp","followers_url":"https://api.github.com/users/grp/followers","following_url":"https://api.github.com/users/grp/following{/other_user}","gists_url":"https://api.github.com/users/grp/gists{/gist_id}","starred_url":"https://api.github.com/users/grp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grp/subscriptions","organizations_url":"https://api.github.com/users/grp/orgs","repos_url":"https://api.github.com/users/grp/repos","events_url":"https://api.github.com/users/grp/events{/privacy}","received_events_url":"https://api.github.com/users/grp/received_events","type":"User","site_admin":false},"body":"You could use `pbxsetting::Type::ParseList()` here, it's a little shorter and IMO more clear about what it's doing.","created_at":"2016-06-26T23:10:22Z","updated_at":"2016-06-26T23:10:22Z","html_url":"https://github.com/facebook/xcbuild/pull/76#discussion_r68511950","pull_request_url":"https://api.github.com/repos/facebook/xcbuild/pulls/76","_links":{"self":{"href":"https://api.github.com/repos/facebook/xcbuild/pulls/comments/68511950"},"html":{"href":"https://github.com/facebook/xcbuild/pull/76#discussion_r68511950"},"pull_request":{"href":"https://api.github.com/repos/facebook/xcbuild/pulls/76"}}},"pull_request":{"url":"https://api.github.com/repos/facebook/xcbuild/pulls/76","id":75215026,"html_url":"https://github.com/facebook/xcbuild/pull/76","diff_url":"https://github.com/facebook/xcbuild/pull/76.diff","patch_url":"https://github.com/facebook/xcbuild/pull/76.patch","issue_url":"https://api.github.com/repos/facebook/xcbuild/issues/76","number":76,"state":"open","locked":false,"title":"[xcsdk] Treat TOOLCHAINS as a list of possible toolchains, not just one toolchain","user":{"login":"Ktwu","id":470651,"avatar_url":"https://avatars.githubusercontent.com/u/470651?v=3","gravatar_id":"","url":"https://api.github.com/users/Ktwu","html_url":"https://github.com/Ktwu","followers_url":"https://api.github.com/users/Ktwu/followers","following_url":"https://api.github.com/users/Ktwu/following{/other_user}","gists_url":"https://api.github.com/users/Ktwu/gists{/gist_id}","starred_url":"https://api.github.com/users/Ktwu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ktwu/subscriptions","organizations_url":"https://api.github.com/users/Ktwu/orgs","repos_url":"https://api.github.com/users/Ktwu/repos","events_url":"https://api.github.com/users/Ktwu/events{/privacy}","received_events_url":"https://api.github.com/users/Ktwu/received_events","type":"User","site_admin":false},"body":"TOOLCHAINS should be a space-delimited string of toolchain names.  xcrun\r\nnow correctly parses this string to build a final toolchains list.","created_at":"2016-06-25T21:37:15Z","updated_at":"2016-06-26T23:10:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b6a3cf4da61ea8d24b6eb5127261371f3f6ac4fd","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/facebook/xcbuild/pulls/76/commits","review_comments_url":"https://api.github.com/repos/facebook/xcbuild/pulls/76/comments","review_comment_url":"https://api.github.com/repos/facebook/xcbuild/pulls/comments{/number}","comments_url":"https://api.github.com/repos/facebook/xcbuild/issues/76/comments","statuses_url":"https://api.github.com/repos/facebook/xcbuild/statuses/59607830276c509229186a880b76d0f8247951c4","head":{"label":"Ktwu:personal-xcsdk","ref":"personal-xcsdk","sha":"59607830276c509229186a880b76d0f8247951c4","user":{"login":"Ktwu","id":470651,"avatar_url":"https://avatars.githubusercontent.com/u/470651?v=3","gravatar_id":"","url":"https://api.github.com/users/Ktwu","html_url":"https://github.com/Ktwu","followers_url":"https://api.github.com/users/Ktwu/followers","following_url":"https://api.github.com/users/Ktwu/following{/other_user}","gists_url":"https://api.github.com/users/Ktwu/gists{/gist_id}","starred_url":"https://api.github.com/users/Ktwu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ktwu/subscriptions","organizations_url":"https://api.github.com/users/Ktwu/orgs","repos_url":"https://api.github.com/users/Ktwu/repos","events_url":"https://api.github.com/users/Ktwu/events{/privacy}","received_events_url":"https://api.github.com/users/Ktwu/received_events","type":"User","site_admin":false},"repo":{"id":59503840,"name":"xcbuild","full_name":"Ktwu/xcbuild","owner":{"login":"Ktwu","id":470651,"avatar_url":"https://avatars.githubusercontent.com/u/470651?v=3","gravatar_id":"","url":"https://api.github.com/users/Ktwu","html_url":"https://github.com/Ktwu","followers_url":"https://api.github.com/users/Ktwu/followers","following_url":"https://api.github.com/users/Ktwu/following{/other_user}","gists_url":"https://api.github.com/users/Ktwu/gists{/gist_id}","starred_url":"https://api.github.com/users/Ktwu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ktwu/subscriptions","organizations_url":"https://api.github.com/users/Ktwu/orgs","repos_url":"https://api.github.com/users/Ktwu/repos","events_url":"https://api.github.com/users/Ktwu/events{/privacy}","received_events_url":"https://api.github.com/users/Ktwu/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Ktwu/xcbuild","description":"Xcode-compatible build tool.","fork":true,"url":"https://api.github.com/repos/Ktwu/xcbuild","forks_url":"https://api.github.com/repos/Ktwu/xcbuild/forks","keys_url":"https://api.github.com/repos/Ktwu/xcbuild/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Ktwu/xcbuild/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Ktwu/xcbuild/teams","hooks_url":"https://api.github.com/repos/Ktwu/xcbuild/hooks","issue_events_url":"https://api.github.com/repos/Ktwu/xcbuild/issues/events{/number}","events_url":"https://api.github.com/repos/Ktwu/xcbuild/events","assignees_url":"https://api.github.com/repos/Ktwu/xcbuild/assignees{/user}","branches_url":"https://api.github.com/repos/Ktwu/xcbuild/branches{/branch}","tags_url":"https://api.github.com/repos/Ktwu/xcbuild/tags","blobs_url":"https://api.github.com/repos/Ktwu/xcbuild/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Ktwu/xcbuild/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Ktwu/xcbuild/git/refs{/sha}","trees_url":"https://api.github.com/repos/Ktwu/xcbuild/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Ktwu/xcbuild/statuses/{sha}","languages_url":"https://api.github.com/repos/Ktwu/xcbuild/languages","stargazers_url":"https://api.github.com/repos/Ktwu/xcbuild/stargazers","contributors_url":"https://api.github.com/repos/Ktwu/xcbuild/contributors","subscribers_url":"https://api.github.com/repos/Ktwu/xcbuild/subscribers","subscription_url":"https://api.github.com/repos/Ktwu/xcbuild/subscription","commits_url":"https://api.github.com/repos/Ktwu/xcbuild/commits{/sha}","git_commits_url":"https://api.github.com/repos/Ktwu/xcbuild/git/commits{/sha}","comments_url":"https://api.github.com/repos/Ktwu/xcbuild/comments{/number}","issue_comment_url":"https://api.github.com/repos/Ktwu/xcbuild/issues/comments{/number}","contents_url":"https://api.github.com/repos/Ktwu/xcbuild/contents/{+path}","compare_url":"https://api.github.com/repos/Ktwu/xcbuild/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Ktwu/xcbuild/merges","archive_url":"https://api.github.com/repos/Ktwu/xcbuild/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Ktwu/xcbuild/downloads","issues_url":"https://api.github.com/repos/Ktwu/xcbuild/issues{/number}","pulls_url":"https://api.github.com/repos/Ktwu/xcbuild/pulls{/number}","milestones_url":"https://api.github.com/repos/Ktwu/xcbuild/milestones{/number}","notifications_url":"https://api.github.com/repos/Ktwu/xcbuild/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Ktwu/xcbuild/labels{/name}","releases_url":"https://api.github.com/repos/Ktwu/xcbuild/releases{/id}","deployments_url":"https://api.github.com/repos/Ktwu/xcbuild/deployments","created_at":"2016-05-23T17:25:18Z","updated_at":"2016-05-23T17:25:22Z","pushed_at":"2016-06-26T19:50:47Z","git_url":"git://github.com/Ktwu/xcbuild.git","ssh_url":"git@github.com:Ktwu/xcbuild.git","clone_url":"https://github.com/Ktwu/xcbuild.git","svn_url":"https://github.com/Ktwu/xcbuild","homepage":null,"size":3563,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"facebook:master","ref":"master","sha":"d03e246a51558073e17a9965c9518d298603d97f","user":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"repo":{"id":43019030,"name":"xcbuild","full_name":"facebook/xcbuild","owner":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/facebook/xcbuild","description":"Xcode-compatible build tool.","fork":false,"url":"https://api.github.com/repos/facebook/xcbuild","forks_url":"https://api.github.com/repos/facebook/xcbuild/forks","keys_url":"https://api.github.com/repos/facebook/xcbuild/keys{/key_id}","collaborators_url":"https://api.github.com/repos/facebook/xcbuild/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/facebook/xcbuild/teams","hooks_url":"https://api.github.com/repos/facebook/xcbuild/hooks","issue_events_url":"https://api.github.com/repos/facebook/xcbuild/issues/events{/number}","events_url":"https://api.github.com/repos/facebook/xcbuild/events","assignees_url":"https://api.github.com/repos/facebook/xcbuild/assignees{/user}","branches_url":"https://api.github.com/repos/facebook/xcbuild/branches{/branch}","tags_url":"https://api.github.com/repos/facebook/xcbuild/tags","blobs_url":"https://api.github.com/repos/facebook/xcbuild/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/facebook/xcbuild/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/facebook/xcbuild/git/refs{/sha}","trees_url":"https://api.github.com/repos/facebook/xcbuild/git/trees{/sha}","statuses_url":"https://api.github.com/repos/facebook/xcbuild/statuses/{sha}","languages_url":"https://api.github.com/repos/facebook/xcbuild/languages","stargazers_url":"https://api.github.com/repos/facebook/xcbuild/stargazers","contributors_url":"https://api.github.com/repos/facebook/xcbuild/contributors","subscribers_url":"https://api.github.com/repos/facebook/xcbuild/subscribers","subscription_url":"https://api.github.com/repos/facebook/xcbuild/subscription","commits_url":"https://api.github.com/repos/facebook/xcbuild/commits{/sha}","git_commits_url":"https://api.github.com/repos/facebook/xcbuild/git/commits{/sha}","comments_url":"https://api.github.com/repos/facebook/xcbuild/comments{/number}","issue_comment_url":"https://api.github.com/repos/facebook/xcbuild/issues/comments{/number}","contents_url":"https://api.github.com/repos/facebook/xcbuild/contents/{+path}","compare_url":"https://api.github.com/repos/facebook/xcbuild/compare/{base}...{head}","merges_url":"https://api.github.com/repos/facebook/xcbuild/merges","archive_url":"https://api.github.com/repos/facebook/xcbuild/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/facebook/xcbuild/downloads","issues_url":"https://api.github.com/repos/facebook/xcbuild/issues{/number}","pulls_url":"https://api.github.com/repos/facebook/xcbuild/pulls{/number}","milestones_url":"https://api.github.com/repos/facebook/xcbuild/milestones{/number}","notifications_url":"https://api.github.com/repos/facebook/xcbuild/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/facebook/xcbuild/labels{/name}","releases_url":"https://api.github.com/repos/facebook/xcbuild/releases{/id}","deployments_url":"https://api.github.com/repos/facebook/xcbuild/deployments","created_at":"2015-09-23T18:24:01Z","updated_at":"2016-06-26T02:22:38Z","pushed_at":"2016-06-26T19:50:48Z","git_url":"git://github.com/facebook/xcbuild.git","ssh_url":"git@github.com:facebook/xcbuild.git","clone_url":"https://github.com/facebook/xcbuild.git","svn_url":"https://github.com/facebook/xcbuild","homepage":null,"size":3613,"stargazers_count":982,"watchers_count":982,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":50,"mirror_url":null,"open_issues_count":25,"forks":50,"open_issues":25,"watchers":982,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/facebook/xcbuild/pulls/76"},"html":{"href":"https://github.com/facebook/xcbuild/pull/76"},"issue":{"href":"https://api.github.com/repos/facebook/xcbuild/issues/76"},"comments":{"href":"https://api.github.com/repos/facebook/xcbuild/issues/76/comments"},"review_comments":{"href":"https://api.github.com/repos/facebook/xcbuild/pulls/76/comments"},"review_comment":{"href":"https://api.github.com/repos/facebook/xcbuild/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/facebook/xcbuild/pulls/76/commits"},"statuses":{"href":"https://api.github.com/repos/facebook/xcbuild/statuses/59607830276c509229186a880b76d0f8247951c4"}}}}
{"actor":{"display_login":"grp"}}