whisper.cpp
whisper.cpp copied to clipboard
Golang Bindings Error
I would like to start by saying a big thank you for all the work that you put into maintaining and developing this project. My issue is with regards to the golang bindings. As I try to initialise the model, I get the following error.
../go/pkg/mod/github.com/ggerganov/whisper.cpp/bindings/[email protected]/params.go:11:10: fatal error: 'whisper.h' file not found #include <whisper.h>
Does anyone has any idea why this might happen?
The same thing happens when I try to run the whisper_test file.
Running tool: /opt/homebrew/bin/go test -timeout 30s -coverprofile=/var/folders/y0/dbsx2zd55lz31wt__nmdgm840000gn/T/vscode-goJry90s/go-code-cover github.com/ggerganov/whisper.cpp/bindings/go
github.com/ggerganov/whisper.cpp/bindings/go
/var/folders/y0/dbsx2zd55lz31wt__nmdgm840000gn/T/go-build3341714362/b084/params.cover.go:11:10: fatal error: 'whisper.h' file not found #include <whisper.h> ^~~~~~~~~~~ 1 error generated. FAIL github.com/ggerganov/whisper.cpp/bindings/go [build failed] FAIL
When I run the tests from the make file everything works fine, whilst when I run the package test, it fails with the error above
![Screenshot 2023-01-17 at 13 10 09](https://user-images.githubusercontent.com/70760023/212907512-47717446-738c-4603-bf9b-12c5d088ab5f.png)
I believe this has been resolved at some point. Feel free to reopen if problem persists
mbaxamb3333 This typically means you need to tell the go compiler where your whisper.cpp files are located. Try setting these environment variables
export CGO_CFLAGS=-I/path/to/whisper.cpp/ export CGO_LDFLAGS=-L/path/to//whisper.cpp/
On Thu, 16 Feb 2023 at 04:38, Georgi Gerganov @.***> wrote:
I believe this has been resolved at some point. Feel free to reopen if problem persists
— Reply to this email directly, view it on GitHub https://github.com/ggerganov/whisper.cpp/issues/418#issuecomment-1431835186, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALQR6YJHPDHVD4JYZ6MEL3WXUPDPANCNFSM6AAAAAAT5Q73H4 . You are receiving this because you are subscribed to this thread.Message ID: @.***>
-- Sincerely
Jay