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
f1a379aa
Commit
f1a379aa
authored
Jul 06, 2024
by
jmorganca
Browse files
llm: statically link pthread and stdc++ dependencies in windows build
parent
9ae14699
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
llm/generate/gen_windows.ps1
llm/generate/gen_windows.ps1
+0
-1
llm/llm.go
llm/llm.go
+2
-1
No files found.
llm/generate/gen_windows.ps1
View file @
f1a379aa
...
@@ -204,7 +204,6 @@ function build_static() {
...
@@ -204,7 +204,6 @@ function build_static() {
"
-DCMAKE_C_COMPILER
=
gcc.exe
",
"
-DCMAKE_C_COMPILER
=
gcc.exe
",
"
-DCMAKE_CXX_COMPILER
=
g
++.
exe
",
"
-DCMAKE_CXX_COMPILER
=
g
++.
exe
",
"
-DBUILD_SHARED_LIBS
=
off
",
"
-DBUILD_SHARED_LIBS
=
off
",
"
-DGGML_STATIC
=
on
",
"
-DGGML_NATIVE
=
off
",
"
-DGGML_NATIVE
=
off
",
"
-DGGML_AVX
=
off
",
"
-DGGML_AVX
=
off
",
"
-DGGML_AVX2
=
off
",
"
-DGGML_AVX2
=
off
",
...
...
llm/llm.go
View file @
f1a379aa
package
llm
package
llm
// #cgo CFLAGS: -Illama.cpp -Illama.cpp/include -Illama.cpp/ggml/include
// #cgo CFLAGS: -Illama.cpp -Illama.cpp/include -Illama.cpp/ggml/include
// #cgo LDFLAGS: -lllama -lggml -lstdc++
// #cgo LDFLAGS: -lllama -lggml -lstdc++ -lpthread
// #cgo windows LDFLAGS: -static-libstdc++ -static-libgcc -static
// #cgo darwin,arm64 LDFLAGS: -L${SRCDIR}/build/darwin/arm64_static -L${SRCDIR}/build/darwin/arm64_static/src -L${SRCDIR}/build/darwin/arm64_static/ggml/src -framework Accelerate -framework Metal
// #cgo darwin,arm64 LDFLAGS: -L${SRCDIR}/build/darwin/arm64_static -L${SRCDIR}/build/darwin/arm64_static/src -L${SRCDIR}/build/darwin/arm64_static/ggml/src -framework Accelerate -framework Metal
// #cgo darwin,amd64 LDFLAGS: -L${SRCDIR}/build/darwin/x86_64_static -L${SRCDIR}/build/darwin/x86_64_static/src -L${SRCDIR}/build/darwin/x86_64_static/ggml/src
// #cgo darwin,amd64 LDFLAGS: -L${SRCDIR}/build/darwin/x86_64_static -L${SRCDIR}/build/darwin/x86_64_static/src -L${SRCDIR}/build/darwin/x86_64_static/ggml/src
// #cgo windows,amd64 LDFLAGS: -L${SRCDIR}/build/windows/amd64_static -L${SRCDIR}/build/windows/amd64_static/src -L${SRCDIR}/build/windows/amd64_static/ggml/src
// #cgo windows,amd64 LDFLAGS: -L${SRCDIR}/build/windows/amd64_static -L${SRCDIR}/build/windows/amd64_static/src -L${SRCDIR}/build/windows/amd64_static/ggml/src
...
...
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