Skip to content

Commit 53ff625

Browse files
committed
Add LIBCLANG_LIBRARY_PATH and LIBCLANG_LIBRARY_FILE
1 parent af2e246 commit 53ff625

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

clang/bindings/python/clang/cindex.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4383,8 +4383,8 @@ def register(item: LibFunc) -> None:
43834383

43844384

43854385
class Config:
4386-
library_path = None
4387-
library_file: str | None = None
4386+
library_path: str | None = os.environ.get("LIBCLANG_LIBRARY_PATH")
4387+
library_file: str | None = os.environ.get("LIBCLANG_LIBRARY_FILE")
43884388
compatibility_check = True
43894389
loaded = False
43904390

clang/docs/ReleaseNotes.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,9 @@ Clang Python Bindings Potentially Breaking Changes
170170
ElaboratedTypes. The value becomes unused, and all the existing users should
171171
expect the former underlying type to be reported instead.
172172
- Remove ``AccessSpecifier.NONE`` kind. No libclang interfaces ever returned this kind.
173+
- Added the environment variables ``LIBCLANG_LIBRARY_PATH`` and ``LIBCLANG_LIBRARY_FILE``,
174+
which allow users to specify the directory path and the exact library file that
175+
should be used to locate libclang.
173176

174177
What's New in Clang |release|?
175178
==============================

0 commit comments

Comments
 (0)