Closed panlilu closed 3 years ago
Could you check out gozstd
source code and run GOOS=darwin GOARCH=arm64 make libzstd.a
from the repository root on a MacBook with M1 chip? This should create libzstd_darwin_arm64.a
file in the root folder of the repository. Then manually create libzstd_darwin_arm64.go
file with the following contents:
package gozstd
/*
#cgo LDFLAGS: ${SRCDIR}/libzstd_darwin_arm64.a
*/
import "C"
Then verify whether everything works by running make test
. If all tests pass, then make a pull request with the added files libzstd_darwin_arm64.a
and libzstd_darwin_arm64.go
package gozstd /* #cgo LDFLAGS: ${SRCDIR}/libzstd_darwin_arm64.a */ import "C"
Hello, I have the some problema with my M1. I followed the steps you described and all tests worked.
MacBook with M1 chip