Project

General

Profile

Bug #14089

Configure/build issue on OSX 10.12 w/ utimensat

Added by zenspider (Ryan Davis) almost 2 years ago. Updated 27 days ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
[ruby-core:83691]

Description

For other reasons I recently installed xcode (instead of JUST using the command line developer tools). This caused builds on ruby to break.

The symptom happens when rdoc tries to build the doco:

dyld: lazy symbol binding failed: Symbol not found: _utimensat

You can see this in the build output:

file.c:2580:13: warning: 'utimensat' is only available on macOS 10.13 or newer
      [-Wunguarded-availability-new]
        if (utimensat(AT_FDCWD, path, tsp, 0) < 0) {
            ^~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/sys/stat.h:374:5: note: 
      'utimensat' has been explicitly marked partial here
int     utimensat(int __fd, const char *__path, const struct timespec __...
        ^
file.c:2580:13: note: enclose 'utimensat' in a __builtin_available check to
      silence this warning
        if (utimensat(AT_FDCWD, path, tsp, 0) < 0) {
            ^~~~~~~~~

and the clue is that path to MacOSX10.13.sdk. The Xcode.app doesn't ship with 10.12, but the developer tools do. It is fixed with:

$ sudo xcode-select --switch /Library/Developer/CommandLineTools

This is here mostly for documentation / search purposes... but maybe we could do something to improve the situation by figuring out that it is being linked against the wrong SDK version?

History

Updated by hsbt (Hiroshi SHIBATA) almost 2 years ago

  • Status changed from Open to Feedback

Hi, Can you try patch of https://github.com/rbenv/ruby-build/issues/1133#issuecomment-331332963 with your environment?

#2

Updated by jeremyevans0 (Jeremy Evans) 27 days ago

  • Status changed from Feedback to Closed

Also available in: Atom PDF