[Openmp-dev] LLVM 3.9 openmp build failure on linux -- cannot find atomic

Paul Osmialowski via Openmp-dev openmp-dev at lists.llvm.org
Fri Sep 9 11:25:16 PDT 2016


Hi Riyaz,


I'm always building LLVM OpenMP runtime with latest LLVM and Clang (from 
git master) and I on every of my Linux machines I never had to set any 
additional flags. What system are you building it on?


On 09/03/16 05:07, Riyaz Puthiyapurayil via Openmp-dev wrote:
>
> With Release 3.9, kmp_lock.h is now including <atomic> under #ifdef 
> __cplusplus. This wasn’t the case with Release 3.8.1. However, there 
> are ‘.c’ files that are compiled as C++ files with ‘-x c++’ but they 
> are not compiled with -stdlib=libc++. As a result, clang does not find 
> <atomic> and gives the following error:
>
> … Building C object 
> projects/openmp/runtime/src/CMakeFiles/omp.dir/kmp_error.c.o
>
> :
>
> :
>
> In file included from 
> /remote/vgsource7/riyaz/llvm/projects/openmp/runtime/src/kmp_error.c:16:
>
> In file included from 
> /remote/vgsource7/riyaz/llvm/projects/openmp/runtime/src/kmp.h:92:
>
> /remote/vgsource7/riyaz/llvm/projects/openmp/runtime/src/kmp_lock.h:26:10: 
> fatal error: 'atomic' file not found
>
> #include <atomic>
>
> ^
>
> 1 error generated.
>
> Should LIBOMP_USE_STDCPPLIB be set to TRUE?
>
> /-Riyaz/
>
>
>
> _______________________________________________
> Openmp-dev mailing list
> Openmp-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20160909/749d5c21/attachment.html>


More information about the Openmp-dev mailing list