[clang] [libclang/python] Add LIBCLANG_LIBRARY_PATH and LIBCLANG_LIBRARY_FILE (PR #170201)

Vlad Serebrennikov via cfe-commits cfe-commits at lists.llvm.org
Thu Dec 4 09:24:49 PST 2025


================
@@ -4468,10 +4468,11 @@ def get_cindex_library(self) -> CDLL:
         try:
             library = cdll.LoadLibrary(self.get_filename())
         except OSError as e:
-            msg = (
-                str(e) + ". To provide a path to libclang use "
-                "Config.set_library_path() or "
-                "Config.set_library_file()."
+            msg = str(e) + (
+                "To provide the path to libclang, you can use the environment variable "
+                "LIBCLANG_LIBRARY_PATH or call Config.set_library_path(). "
+                "Alternatively, you can specify the exact library file using "
----------------
Endilll wrote:

```suggestion
                "Alternatively, you can specify path of the library file using "
```

https://github.com/llvm/llvm-project/pull/170201


More information about the cfe-commits mailing list