AvalancheGO not building / debugging in Apple M1 by using Go arm64

hi there developers!, can you help me with two questions regarding Debugging for AvalancheGo in Mac M1:

  1. Having Apple M1 and Golang ARM “go1.16.5.darwin-arm64” I can’t build the project (./scripts/build.sh). The build only works with AMD “go1.16.5.darwin-amd64”, how can I achieve it?

  2. Having Apple M1, ARM “go1.16.5.darwin-arm64” and using the latest versions of IntellijGoland and Visual Studio Code for Apple M1, if I can debug other Golang projects, but unfortunately avalancheGo cannot be debugged since it debug only runs in AMD, like can i achieve this by using my Mac M1?

Thanks in advance for any feedback.