-
Notifications
You must be signed in to change notification settings - Fork 29.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
xcrun error when building master #12531
Comments
The issue with the |
@gibfahn can you verify it's tools/gyp/pylib/gyp/mac_tool.py:
79 - args = ['xcrun', 'ibtool', '--errors', '--warnings', '--notices',
80 - '--output-format', 'human-readable-text', '--compile', dest, source]
86 + args = ['xcrun', 'ibtool', '--errors', '--warnings', '--notices'] So I can dig deeper? |
(I meen that whole patched area ) |
Is your |
I put some print statements in there but nothing happened. I don't know enough about GYP to know whether that file is even being triggered. I think it might not be. I don't have any XCODE things in my environment (or |
Hmm. I'll have to spin up my hackintosh VM. |
P.S. you say these errors comes from |
[not a solution]
|
macOS 10.12.4 (16E195) (the latest Sierra). Yes, errors come from Not sure how to tell which version of the command line tools, but it should be the latest, here's the output of ➜ node git:(master) ✗ ❯ clang --version ~/wrk/com/node
Apple LLVM version 8.1.0 (clang-802.0.38)
Target: x86_64-apple-darwin16.5.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin |
AFAIK they are just messages, right? you can |
Yep, they don't actually seem to affect anything. I know |
FYI, trying to push this upstream https://chromium-review.googlesource.com/c/492046/ voice your opinion |
This is still a thing, right? |
Yep, just confirmed on |
@Trott just got this. Could we check what's wrong here? |
What does |
@bnoordhuis the exact same thing. > $ xcrun --show-sdk-platform-path
xcrun: error: unable to lookup item 'PlatformPath' from command line tools installation
xcrun: error: unable to lookup item 'PlatformPath' in SDK '/' |
Good, that means it isn't because of the environment gyp invokes it in. Does this patch fix it? diff --git a/tools/gyp/pylib/gyp/xcode_emulation.py b/tools/gyp/pylib/gyp/xcode_emulation.py
index 9082b9da35..c303313a30 100644
--- a/tools/gyp/pylib/gyp/xcode_emulation.py
+++ b/tools/gyp/pylib/gyp/xcode_emulation.py
@@ -645,9 +645,10 @@ class XcodeSettings(object):
cflags += self._Settings().get('WARNING_CFLAGS', [])
- platform_root = self._XcodePlatformPath(configname)
- if platform_root and self._IsXCTest():
- cflags.append('-F' + platform_root + '/Developer/Library/Frameworks/')
+ if self._IsXCTest():
+ platform_root = self._XcodePlatformPath(configname)
+ if platform_root:
+ cflags.append('-F' + platform_root + '/Developer/Library/Frameworks/')
if sdk_root:
framework_root = sdk_root
@@ -913,10 +914,11 @@ class XcodeSettings(object):
for directory in framework_dirs:
ldflags.append('-F' + directory.replace('$(SDKROOT)', sdk_root))
- platform_root = self._XcodePlatformPath(configname)
- if sdk_root and platform_root and self._IsXCTest():
- ldflags.append('-F' + platform_root + '/Developer/Library/Frameworks/')
- ldflags.append('-framework XCTest')
+ if self._IsXCTest():
+ platform_root = self._XcodePlatformPath(configname)
+ if sdk_root and platform_root:
+ ldflags.append('-F' + platform_root + '/Developer/Library/Frameworks/')
+ ldflags.append('-framework XCTest')
is_extension = self._IsIosAppExtension() or self._IsIosWatchKitExtension()
if sdk_root and is_extension: |
@bnoordhuis it did, awesome! I hope it landed in a version of gyp we don't have yet? If not, why aren't we floating this upstream? |
Because I just wrote it 30 minutes ago. :-) I'd be okay with floating it on top of our local copy. Upstream gyp is pretty much dead by now. |
@bnoordhuis making a PR for nodejs/node. |
BTW, I was confused because I thought @refack had made a similar patch for upstream gyp, but maybe it didn't land? |
It didn't. |
Previously running ./configure with only the Xcode Command Line Tools installed would give: xcrun: error: unable to lookup item 'PlatformPath' from command line tools installation xcrun: error: unable to lookup item 'PlatformPath' in SDK '/' Co-authored-by: Ben Noordhuis <info@bnoordhuis.nl> Fixes: nodejs#12531
Previously running ./configure with only the Xcode Command Line Tools installed would give: xcrun: error: unable to lookup item 'PlatformPath' from command line tools installation xcrun: error: unable to lookup item 'PlatformPath' in SDK '/' Co-authored-by: Ben Noordhuis <info@bnoordhuis.nl> Fixes: #12531 PR-URL: #21520 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Previously running ./configure with only the Xcode Command Line Tools installed would give: xcrun: error: unable to lookup item 'PlatformPath' from command line tools installation xcrun: error: unable to lookup item 'PlatformPath' in SDK '/' Co-authored-by: Ben Noordhuis <info@bnoordhuis.nl> Fixes: nodejs/node#12531 PR-URL: nodejs/node#21520 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Previously running ./configure with only the Xcode Command Line Tools installed would give: xcrun: error: unable to lookup item 'PlatformPath' from command line tools installation xcrun: error: unable to lookup item 'PlatformPath' in SDK '/' Co-authored-by: Ben Noordhuis <info@bnoordhuis.nl> Fixes: nodejs/node#12531 PR-URL: nodejs/node#21520 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Previously running ./configure with only the Xcode Command Line Tools installed would give: xcrun: error: unable to lookup item 'PlatformPath' from command line tools installation xcrun: error: unable to lookup item 'PlatformPath' in SDK '/' Co-authored-by: Ben Noordhuis <info@bnoordhuis.nl> Fixes: nodejs#12531 PR-URL: nodejs#21520 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> (cherry picked from commit 51812ff)
As of I think yesterday, when I run
./configure
on macOS, I get a newxcrun
error in addition to thexcodebuild
warnings that we all know and love. The build still passes, but it'd be nice to avoid these.Error:
The text was updated successfully, but these errors were encountered: