langgenius / dify-sandbox

A lightweight, fast, and secure code execution environment that supports multiple programming languages
https://docs.dify.ai/development/backend/sandbox
Apache License 2.0
434 stars 97 forks source link

can not build libraries for amd64 #14

Open CocoaML opened 4 months ago

CocoaML commented 4 months ago

运行./build/build_arm64.sh 报错如下:

Building Python lib
# internal/abi
/usr/local/go/src/internal/abi/funcpc.go:22:6: FuncPCABI0 redeclared in this block
    /usr/local/go/src/internal/abi/abi.go:117:6: other declaration of FuncPCABI0
/usr/local/go/src/internal/abi/funcpc.go:31:6: FuncPCABIInternal redeclared in this block
    /usr/local/go/src/internal/abi/abi.go:126:6: other declaration of FuncPCABIInternal
# internal/chacha8rand
/usr/local/go/src/internal/chacha8rand/chacha8_arm64.s:19: ABI selector only permitted when compiling runtime, reference was to "\"\".block"
asm: assembly of /usr/local/go/src/internal/chacha8rand/chacha8_arm64.s failed

使用的go版本:

go version go1.20.6 linux/arm64

Linux版本:

Linux ml 5.4.0-189-generic #209-Ubuntu SMP Fri Jun 7 14:05:34 UTC 2024 aarch64 aarch64 aarch64 GNU/Linux

请问如何修复呢?期待反馈。

Yeuoly commented 4 months ago

Your golang environment was broken I guess, it looks like you have installed some non-standard libraries which cause this error

CocoaML commented 4 months ago

Your golang environment was broken I guess, it looks like you have installed some non-standard libraries which cause this error

How can i check golang environment which is non-standard libraries ? How can i fix it? Looking forward to your reply, Thanks.