herumi / bls

288 stars 132 forks source link

Go library errors #82

Closed PumpkinSeed closed 2 years ago

PumpkinSeed commented 2 years ago

I pulled the go library in and got the following error:

# github.com/herumi/bls/ffi/go/bls
In file included from /usr/local/include/bls/bls.h:10,
                 from vendor/github.com/herumi/bls/ffi/go/bls/bls.go:15:
/usr/local/include/mcl/bn.h:13:10: error: #error "define MCLBN_FP_UNIT_SIZE 4(, 6 or 8)"
   13 |         #error "define MCLBN_FP_UNIT_SIZE 4(, 6 or 8)"
      |          ^~~~~

Also I think it would make sense to use the mcl go library instead of this, because I have an implementation which uses the mcl lib and it's not compatible with the bls's go lib because using a copied version.

herumi commented 2 years ago

The code in ffi/go of mcl/bls are for only tests. Could you use https://github.com/herumi/bls-go-binary or https://github.com/herumi/bls-eth-go-binary for Go binding? These repositories contain compiled static libraries (both mcl and bls), so you can use them quickly.

PumpkinSeed commented 2 years ago

Thanks, I will give it a try.