build: Add preliminary RISC-V (riscv64) build support#6285
Merged
algorandskiy merged 2 commits intoalgorand:masterfrom Apr 9, 2025
Merged
build: Add preliminary RISC-V (riscv64) build support#6285algorandskiy merged 2 commits intoalgorand:masterfrom
algorandskiy merged 2 commits intoalgorand:masterfrom
Conversation
This commit adds support for the riscv64 architecture to the crypto libraries. It includes the necessary CFLAGS and LDFLAGS for compiling with the libsodium library on riscv64 Linux systems. Additionally, it updates the archtype.sh script to correctly identify the riscv64 architecture.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #6285 +/- ##
==========================================
- Coverage 51.70% 51.67% -0.04%
==========================================
Files 647 647
Lines 86874 86874
==========================================
- Hits 44917 44888 -29
- Misses 39100 39118 +18
- Partials 2857 2868 +11 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
cce
approved these changes
Apr 3, 2025
algorandskiy
approved these changes
Apr 9, 2025
|
Nullun! Nullun! Nullun! |
This was referenced May 15, 2025
cce
pushed a commit
to cce/go-algorand
that referenced
this pull request
May 29, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request adds the necessary cgo directives to compile go-algorand for RISC-V (64-bit) CPUs. By supporting this architecture, we ensure future compatibility with the growing open hardware market and enhance the decentralized nature of the Algorand network.
I have tested this on local hardware and was able to successfully sync a RISC-V device to Mainnet. I had also compiled node_exporter, but decided against including it here and instead just copied one of the dummy (empty node_exporter) .tar.gz archives with the correct naming scheme, so the Makefile works as expected for riscv64.
I imagine providing precompiled binaries and officially support RISC-V is a ways off, but at least this helps interested parties to build it themselves.