[cfe-dev] llvm fails to build on MacOS prior to 10.12

Arthur O'Dwyer via cfe-dev cfe-dev at lists.llvm.org
Tue May 7 09:26:21 PDT 2019


Adrian,

Your recent commit
https://github.com/llvm-mirror/llvm/commit/e8c5427c
causes build failures for me locally on Mac OSX 10.11.6 using a stock (and
I guess fairly old) Xcode Clang.

Is there any way to fix trunk so that your new code is #ifdef'ed out for
versions of Clang that don't support this bizarre __builtin_available(macos
10.12, *) syntax?  Or maybe hide it behind a macro?

Thanks in advance,
Arthur

In file included from $ROOT/llvm/lib/Support/Path.cpp:1113:

*$ROOT/llvm/lib/Support/Unix/Path.inc:1140:27: **error: **use of undeclared
identifier 'macos'; did you mean 'acos'?*

  if (__builtin_available(macos 10.12, *)) {

*                          ^~~~~*

                          acos

*/usr/include/math.h:323:15: note: *'acos' declared here

extern double acos(double);

*              ^*

In file included from $ROOT/llvm/lib/Support/Path.cpp:1113:

*$ROOT/llvm/lib/Support/Unix/Path.inc:1147:14: **error: **use of undeclared
identifier 'COPYFILE_CLONE'*

      Flag = COPYFILE_CLONE;

*             ^*

2 errors generated.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20190507/0f4011d5/attachment.html>


More information about the cfe-dev mailing list