We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 63d8a3c + 2559e5a commit 0460fdbCopy full SHA for 0460fdb
llama_cpp/llama_cpp.py
@@ -25,6 +25,12 @@ def _load_shared_library(lib_base_name):
25
_base_path / f"{lib_base_name}{lib_ext}"
26
]
27
28
+ if ("LLAMA_CPP_LIB" in os.environ):
29
+ lib_base_name = os.environ["LLAMA_CPP_LIB"]
30
+ _lib = pathlib.Path(lib_base_name)
31
+ _base_path = _lib.parent.resolve()
32
+ _lib_paths = [_lib.resolve()]
33
+
34
# Add the library directory to the DLL search path on Windows (if needed)
35
if sys.platform == "win32" and sys.version_info >= (3, 8):
36
os.add_dll_directory(str(_base_path))
0 commit comments