Following up on #12348 (closed 2024). There's been more demand since then, and I found a way to bring the extended build time down to about 2 minutes on riscv64.
The key issue with extended Hugo on riscv64 is that compiling vendored libsass takes many hours. But golibsass already has a dev build tag that links against the system libsass library instead. With -tags extended,dev and apt install libsass-dev, the extended build drops from ~14 hours to ~2 minutes on native riscv64 hardware.
Build evidence:
For hugoreleaser.yaml, the regular build just needs goarch: riscv64 added under container1/unix/regular. The extended build would need either:
- Cross-compilation with
riscv64-linux-gnu-gcc (like arm64 uses aarch64-linux-gnu-gcc)
- Native build on a riscv64 runner with system libsass (
-tags extended,dev)
Native riscv64 GitHub Actions runners are available through the RISE Project (https://riseproject.dev/), free for open source. To enable: install https://github.com/apps/rise-risc-v-runners on this repository.
I can put together a PR if this approach works for you.
Following up on #12348 (closed 2024). There's been more demand since then, and I found a way to bring the extended build time down to about 2 minutes on riscv64.
The key issue with extended Hugo on riscv64 is that compiling vendored libsass takes many hours. But golibsass already has a
devbuild tag that links against the systemlibsasslibrary instead. With-tags extended,devandapt install libsass-dev, the extended build drops from ~14 hours to ~2 minutes on native riscv64 hardware.Build evidence:
hugo version: v0.160.0-DEV extended linux/riscv64For
hugoreleaser.yaml, the regular build just needsgoarch: riscv64added under container1/unix/regular. The extended build would need either:riscv64-linux-gnu-gcc(like arm64 usesaarch64-linux-gnu-gcc)-tags extended,dev)Native riscv64 GitHub Actions runners are available through the RISE Project (https://riseproject.dev/), free for open source. To enable: install https://github.com/apps/rise-risc-v-runners on this repository.
I can put together a PR if this approach works for you.