Skip to content

Add loongarch64 support#31338

Merged
robertsirc merged 1 commit into
helm:mainfrom
yzewei:add-loong64-support
Oct 21, 2025
Merged

Add loongarch64 support#31338
robertsirc merged 1 commit into
helm:mainfrom
yzewei:add-loong64-support

Conversation

@yzewei

@yzewei yzewei commented Sep 26, 2025

Copy link
Copy Markdown
Contributor

What this PR does / why we need it:
Add loongarch64 support for helm

LoongArch is a RISC-based CPU architecture increasingly adopted in server, cloud, and edge computing environments. As the LoongArch ecosystem grows, more and more open-source projects and container images provide LoongArch builds, for example, Alpine 3.22 already supports it, and Debian support is coming soon.

Helm, as a key package manager in the Kubernetes ecosystem, directly affects the experience of millions of LoongArch CPU users. Adding support for LoongArch builds would make Helm official binaries directly usable on LoongArch platforms, simplifying installation and deployment workflows, improving cross-architecture compatibility, and enhancing the value to the community.

Special notes for your reviewer:
The LoongArch architecture (LoongArch) is an Instruction Set Architecture (ISA) that has a RISC style.
Use QEMU to simulate the Loongarch architecture in other architecture.

If applicable:

  • [ x ] this PR contains documentation
  • this PR contains unit tests
  • this PR has been tested for backwards compatibility

@pull-request-size pull-request-size Bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Sep 26, 2025
@yzewei

yzewei commented Sep 26, 2025

Copy link
Copy Markdown
Contributor Author

@NickJosevski thanks! ptal

@yzewei

yzewei commented Sep 26, 2025

Copy link
Copy Markdown
Contributor Author

If LoongArch is supported, millions more developers will be involved in the development and use of Helm.

Comment thread scripts/get Outdated
Signed-off-by: yzewei <yangzewei@loongson.cn>
@yzewei yzewei force-pushed the add-loong64-support branch from 6f611a0 to fd3ef2e Compare October 9, 2025 01:09
gjenkins8
gjenkins8 previously approved these changes Oct 10, 2025
@gjenkins8

gjenkins8 commented Oct 10, 2025

Copy link
Copy Markdown
Member

I didn't get a chance to look in detail. But at a glance it seems that gox might not support linux/loong64 as a target platform:

$ make build-cross
GOFLAGS="-trimpath" CGO_ENABLED=0 /Users/gjenkins8/.go/bin/gox -parallel=3 -output="_dist/{{.OS}}-{{.Arch}}/helm" -osarch='darwin/amd64 darwin/arm64 linux/amd64 linux/386 linux/arm linux/arm64 linux/loong64 linux/ppc64le linux/s390x linux/riscv64 windows/amd64 windows/arm64'  -tags '' -ldflags '-w -s -X helm.sh/helm/v4/internal/version.metadata=unreleased -X helm.sh/helm/v4/internal/version.gitCommit=fd3ef2e000a56a2668c134a16fe152314b6e5dfc -X helm.sh/helm/v4/internal/version.gitTreeState=dirty  -X helm.sh/helm/v4/pkg/chart/v2/lint/rules.k8sVersionMajor=1 -X helm.sh/helm/v4/pkg/chart/v2/lint/rules.k8sVersionMinor=34 -X helm.sh/helm/v4/pkg/internal/v3/lint/rules.k8sVersionMajor=1 -X helm.sh/helm/v4/pkg/internal/v3/lint/rules.k8sVersionMinor=34 -X helm.sh/helm/v4/pkg/chart/common/util.k8sVersionMajor=1 -X helm.sh/helm/v4/pkg/chart/common/util.k8sVersionMinor=34 -extldflags "-static"' ./cmd/helm
Number of parallel builds: 3

-->    darwin/amd64: helm.sh/helm/v4/cmd/helm
-->       linux/386: helm.sh/helm/v4/cmd/helm
-->   linux/ppc64le: helm.sh/helm/v4/cmd/helm
-->     linux/amd64: helm.sh/helm/v4/cmd/helm
-->       linux/arm: helm.sh/helm/v4/cmd/helm
-->    darwin/arm64: helm.sh/helm/v4/cmd/helm
-->     linux/arm64: helm.sh/helm/v4/cmd/helm
-->   windows/amd64: helm.sh/helm/v4/cmd/helm
-->     linux/s390x: helm.sh/helm/v4/cmd/helm

(note: linux/loong64 is in the -osarch list above)

The good news is #31343 replaces gox (now deprecated) with goreleaser. This change might need to depend on this PR.

@yzewei

yzewei commented Oct 11, 2025

Copy link
Copy Markdown
Contributor Author

I didn't get a chance to look in detail. But at a glance it seems that gox might not support linux/loong64 as a target platform:

$ make build-cross
GOFLAGS="-trimpath" CGO_ENABLED=0 /Users/gjenkins8/.go/bin/gox -parallel=3 -output="_dist/{{.OS}}-{{.Arch}}/helm" -osarch='darwin/amd64 darwin/arm64 linux/amd64 linux/386 linux/arm linux/arm64 linux/loong64 linux/ppc64le linux/s390x linux/riscv64 windows/amd64 windows/arm64'  -tags '' -ldflags '-w -s -X helm.sh/helm/v4/internal/version.metadata=unreleased -X helm.sh/helm/v4/internal/version.gitCommit=fd3ef2e000a56a2668c134a16fe152314b6e5dfc -X helm.sh/helm/v4/internal/version.gitTreeState=dirty  -X helm.sh/helm/v4/pkg/chart/v2/lint/rules.k8sVersionMajor=1 -X helm.sh/helm/v4/pkg/chart/v2/lint/rules.k8sVersionMinor=34 -X helm.sh/helm/v4/pkg/internal/v3/lint/rules.k8sVersionMajor=1 -X helm.sh/helm/v4/pkg/internal/v3/lint/rules.k8sVersionMinor=34 -X helm.sh/helm/v4/pkg/chart/common/util.k8sVersionMajor=1 -X helm.sh/helm/v4/pkg/chart/common/util.k8sVersionMinor=34 -extldflags "-static"' ./cmd/helm
Number of parallel builds: 3

-->    darwin/amd64: helm.sh/helm/v4/cmd/helm
-->       linux/386: helm.sh/helm/v4/cmd/helm
-->   linux/ppc64le: helm.sh/helm/v4/cmd/helm
-->     linux/amd64: helm.sh/helm/v4/cmd/helm
-->       linux/arm: helm.sh/helm/v4/cmd/helm
-->    darwin/arm64: helm.sh/helm/v4/cmd/helm
-->     linux/arm64: helm.sh/helm/v4/cmd/helm
-->   windows/amd64: helm.sh/helm/v4/cmd/helm
-->     linux/s390x: helm.sh/helm/v4/cmd/helm

(note: linux/loong64 is in the -osarch list above)

The good news is #31343 replaces gox (now deprecated) with goreleaser. This change might need to depend on this PR.

That’s really good news, thank you!
Is there anything else I need to do on my side?

@robertsirc robertsirc left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@robertsirc

Copy link
Copy Markdown
Member

@yzewei sorry for the delay in this one.

@robertsirc robertsirc merged commit f0386b1 into helm:main Oct 21, 2025
5 checks passed
@scottrigby scottrigby added this to the 4.0.0 milestone Oct 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants