diff --git a/libcudacxx/include/cuda/__barrier/barrier_native_handle.h b/libcudacxx/include/cuda/__barrier/barrier_native_handle.h index 29879c71edf..a685c832723 100644 --- a/libcudacxx/include/cuda/__barrier/barrier_native_handle.h +++ b/libcudacxx/include/cuda/__barrier/barrier_native_handle.h @@ -25,6 +25,8 @@ #include #include +#if _CCCL_HAS_CUDA_COMPILER + _LIBCUDACXX_BEGIN_NAMESPACE_CUDA_DEVICE _CCCL_DEVICE inline _CUDA_VSTD::uint64_t* barrier_native_handle(barrier& __b) @@ -34,4 +36,6 @@ _CCCL_DEVICE inline _CUDA_VSTD::uint64_t* barrier_native_handle(barrier +#include #include #include #include diff --git a/libcudacxx/include/cuda/barrier b/libcudacxx/include/cuda/barrier index 0d65d4bf344..bcc2999cb31 100644 --- a/libcudacxx/include/cuda/barrier +++ b/libcudacxx/include/cuda/barrier @@ -34,6 +34,7 @@ #include #include #include +#include #include #include #include