fixed finding model libs

This commit is contained in:
Richard Guo
2023-06-02 10:57:21 -04:00
committed by AT
parent ab56364da8
commit c54c42e3fb
5 changed files with 44 additions and 21 deletions

View File

@@ -9,6 +9,8 @@
#include <cassert>
#include <cstdlib>
std::string LLModel::m_implementations_search_path = ".";
static bool requires_avxonly() {
#ifdef __x86_64__
#ifndef _MSC_VER
@@ -76,7 +78,7 @@ const std::vector<LLModel::Implementation> &LLModel::implementationList() {
};
const char *custom_impl_lookup_path = getenv("GPT4ALL_IMPLEMENTATIONS_PATH");
search_in_directory(custom_impl_lookup_path?custom_impl_lookup_path:".");
search_in_directory(m_implementations_search_path);
#if defined(__APPLE__)
search_in_directory("../../../");
#endif