1+ # SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2+ # SPDX-License-Identifier: Apache-2.0
3+
4+ import os
5+ import pathlib
6+ import sys
7+
8+ CUDA_PATH = os .environ .get ("CUDA_PATH" )
9+ CUDA_INCLUDE_PATH = None
10+ CCCL_INCLUDE_PATHS = None
11+ if CUDA_PATH is not None :
12+ path = os .path .join (CUDA_PATH , "include" )
13+ if os .path .isdir (path ):
14+ CUDA_INCLUDE_PATH = path
15+ CCCL_INCLUDE_PATHS = (path ,)
16+ path = os .path .join (path , "cccl" )
17+ if os .path .isdir (path ):
18+ CCCL_INCLUDE_PATHS = (path ,) + CCCL_INCLUDE_PATHS
19+
20+
21+ try :
22+ import cuda_python_test_helpers
23+ except ImportError :
24+ # Import shared platform helpers for tests across repos
25+ sys .path .insert (0 , str (pathlib .Path (__file__ ).resolve ().parents [2 ] / "cuda_python_test_helpers" ))
26+ import cuda_python_test_helpers
27+
28+ # If we imported the package instead of the module, get the actual module
29+ if hasattr (cuda_python_test_helpers , '__path__' ):
30+ # We imported the package, need to get the actual module
31+ import cuda_python_test_helpers .cuda_python_test_helpers as cuda_python_test_helpers
32+
33+
34+ IS_WSL = cuda_python_test_helpers .IS_WSL
35+ supports_ipc_mempool = cuda_python_test_helpers .supports_ipc_mempool
36+
37+
38+ del cuda_python_test_helpers
0 commit comments