diff --git a/sycl/test-e2e/lit.cfg.py b/sycl/test-e2e/lit.cfg.py index e1b2b4a1ef28d..2729eb204ae2c 100644 --- a/sycl/test-e2e/lit.cfg.py +++ b/sycl/test-e2e/lit.cfg.py @@ -80,6 +80,12 @@ llvm_config.with_environment("PATH", config.lit_tools_dir, append_path=True) +if "cuda:gpu" in config.sycl_devices: + llvm_config.with_system_environment("CUDA_PATH") + +if "hip:gpu" in config.sycl_devices: + llvm_config.with_system_environment("ROCM_PATH") + # Configure LD_LIBRARY_PATH or corresponding os-specific alternatives if platform.system() == "Linux": config.available_features.add("linux")