Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
ollama
Commits
642128b7
Commit
642128b7
authored
Oct 31, 2023
by
Michael Yang
Browse files
append LD_LIBRARY_PATH
parent
ad887994
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
llm/llama.go
llm/llama.go
+9
-1
No files found.
llm/llama.go
View file @
642128b7
...
...
@@ -360,7 +360,15 @@ func newLlama(model string, adapters []string, runners []ModelRunner, numLayers
runner
.
Path
,
append
(
params
,
"--port"
,
strconv
.
Itoa
(
port
))
...
,
)
cmd
.
Env
=
append
(
os
.
Environ
(),
fmt
.
Sprintf
(
"LD_LIBRARY_PATH=%s"
,
filepath
.
Dir
(
runner
.
Path
)))
var
libraryPaths
[]
string
if
libraryPath
,
ok
:=
os
.
LookupEnv
(
"LD_LIBRARY_PATH"
);
ok
{
libraryPaths
=
append
(
libraryPaths
,
libraryPath
)
}
libraryPaths
=
append
(
libraryPaths
,
filepath
.
Dir
(
runner
.
Path
))
cmd
.
Env
=
append
(
os
.
Environ
(),
fmt
.
Sprintf
(
"LD_LIBRARY_PATH=%s"
,
strings
.
Join
(
libraryPaths
,
":"
)))
cmd
.
Stdout
=
os
.
Stderr
statusWriter
:=
NewStatusWriter
()
cmd
.
Stderr
=
statusWriter
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment