Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GOARM 会影响 ARM64 构建产物的文件名 #167

Closed
Simple-Tracker opened this issue Apr 12, 2024 · 3 comments
Closed

GOARM 会影响 ARM64 构建产物的文件名 #167

Simple-Tracker opened this issue Apr 12, 2024 · 3 comments

Comments

@Simple-Tracker
Copy link
Contributor

Simple-Tracker commented Apr 12, 2024

若在变量中使用 GOARM (尤其是在 matrix 中为所有 OS/Arch 设置默认 GOARM 时), 会使 GOARCH=ARM64 的产物文件名出现意想不到的情况, 如: Program-1.0-linux-arm64v6.tar.gz. 这似乎是由于 release.sh 中使用了宽泛匹配导致的.

Go 编译器使用精确匹配, 摘自文档: https://pkg.go.dev/cmd/go/internal/help@go1.19.13
GOARM
For GOARCH=arm, the ARM architecture for which to compile.
Valid values are 5, 6, 7.

关于 GOARM64: golang/go#60905

示例 matrix:

    strategy:
      matrix:
        goos: [linux]
        goarch: ['arm', 'arm64']
        goarm: ['6']
        include:
          - goos: linux
             goarch: 'arm'
             goarm: '7'
@wangyoucao577
Copy link
Owner

看上去应该严格匹配? 欢迎 PR

@wangyoucao577
Copy link
Owner

wangyoucao577/go-release-action:v1.50 is ready for you

@Simple-Tracker
Copy link
Contributor Author

Thanks! It works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants