[llvm-bugs] [Bug 38160] New: init_priority breaks compilation of pmr::memory_resource with GCC on OS X
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Jul 13 10:11:14 PDT 2018
https://bugs.llvm.org/show_bug.cgi?id=38160
Bug ID: 38160
Summary: init_priority breaks compilation of
pmr::memory_resource with GCC on OS X
Product: libc++
Version: unspecified
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: All Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: ldionne at apple.com
CC: llvm-bugs at lists.llvm.org, mclow.lists at gmail.com
GCC on OSX can't compile pmr::memory_resource:
# On OS X, with a Homebrew-installed GCC
CXX_COMPILER="/usr/local/Cellar/gcc/8.1.0/bin/g++-8"
C_COMPILER="/usr/local/Cellar/gcc/8.1.0/bin/gcc-8"
cd root-of-llvm-monorepo
mkdir build
cd build
cmake .. -DCMAKE_CXX_COMPILER=${CXX_COMPILER}
-DCMAKE_C_COMPILER=${C_COMPILER}
-DLLVM_ENABLE_PROJECTS="clang;libcxx;libcxxabi"
cmake --build . --target cxx_experimental
This produces:
/Users/ldionne/work/llvm/libcxx/src/experimental/memory_resource.cpp:76:65:
error: 'init_priority' attribute is not supported on this platform
ResourceInitHelper res_init __attribute__((init_priority (101)));
^
ninja: build stopped: subcommand failed.
The problem seems to be that `init_priority` is not an attribute supported by
GCC on OS X. Is there any way we can use something else when for GCC on OSX?
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180713/fc69a2d0/attachment.html>
More information about the llvm-bugs
mailing list