I am trying to build a Go program which uses github.com/ungerik/go-cairo as a Cairo wrapper in Go. I built it successfully for several months and then it suddenly stopped working. Unfortunately, I don't know how my system has changed.
Build command:
go build -o=/tmp/bin/api ./cmd/api
Error:
# github.com/ungerik/go-cairo
/Users/jan/go/pkg/mod/github.com/ungerik/[email protected]/cairo.go:6:11: fatal error: 'cairo/cairo-pdf.h' file not found
#include <cairo/cairo-pdf.h>
I have tried to debug it further by checking the following output:
Output of cmd: pkg-config --cflags cairo-pdf
-I/opt/homebrew/Cellar/cairo/1.18.0/include -I/opt/homebrew/Cellar/cairo/1.18.0/include/cairo
Output of cmd: which -a pkg-config
/opt/homebrew/bin/pkg-config`
There is also an existing issue on Github: https://github.com/ungerik/go-cairo/issues/16
I have already tried the solution of running: xcode-select --install
But I still get the same error.
Can you help me debug it further?