Hi! I'm trying to compile a part of the geth-client with the current gollvm build. But it fails in this file: https://github.com/ethereum/go-ethereum/blob/master/crypto/bn256/cloudflare/gfp_amd64.s
Here is an exempt from the error: root@llvmbuilder-successful-s-1vcpu-2gb-fra1-s-1vcpu-2gb-fra1-01:~/compile# go build -tags gofuzz -buildmode=c-shared -o ./geth-runtime-gollvm.so ./main.go # github.com/ethereum/go-ethereum/crypto/bn256/cloudflare ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s: Assembler messages: ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:4: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:4: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:5: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:5: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:6: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:6: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:7: Error: too many memory references for `movq' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:10: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:10: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:11: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:11: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:12: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:12: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:13: Error: too many memory references for `movq' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:16: Error: junk at end of line, first unrecognized character is `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:17: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:17: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:18: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:18: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:19: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:19: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:20: Warning: stray `\' ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:20: Error: invalid character '\' in operand 2 ../go/src/github.com/ethereum/go-ethereum/crypto/bn256/cloudflare/gfp_amd64.s:21: Warning: stray `\' [...] When I compile this with the regular go build command it works without issue. It seems the compilation fails due to the multiline definitions. Does someone have an idea how I can fix this? I guess there is something missing in the gollvm implementation that handles this? If you want to try it yourself do this: go get github.com/ethereum/go-ethereum/ printf "package main\nimport \"C\"\nimport \"github.com/ethereum/go-ethereum/core/vm/runtime\"\nfunc main(){}//export Fuzz\nfunc Fuzz(data []byte){\nruntime.Fuzz(data)\n}\n" > ./main.go go build -tags gofuzz -buildmode=c-shared -o ./geth-runtime-gollvm.so ./main.go This will create a main.go file in the current directory with the necessary stub for compilation in c-shared mode. Cheers, Benedikt -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.