From Fedora Project Wiki
No edit summary
(Added Fedora's dedicated Koji build system in Fedora's data center. Reference: <https://fedoramagazine.org/risc-v-and-fedora-all-aboard/>.)
 
(68 intermediate revisions by 12 users not shown)
Line 1: Line 1:
[https://riscv.org/ RISC-V] (pronounced "RISC Five") is an [https://en.wikipedia.org/wiki/RISC-V open source instruction set architecture (ISA)].  This project, informally called '''Fedora/RISC-V''', aims to get Fedora bootstrapped on the RISC-V (64 bit) architecture.
[https://riscv.org/ RISC-V] (pronounced "RISC Five") is an [https://en.wikipedia.org/wiki/RISC-V open source instruction set architecture (ISA)].  This project, informally called '''Fedora/RISC-V''', aims to provide a complete Fedora experience on the RISC-V (64 bit, RV64GC) architecture.


= Topics =
= Topics =


* [[Architectures/RISC-V/Bootstrapping]] - Find out how to take part in the current bootstrapping of Fedora on RISC-V, how to build RPMs, common problems, etc.
* [[Architectures/RISC-V/Installing|Installing]] - How to download, install and run Fedora/RISC-V.
* [[Architectures/RISC-V/Hardware|Hardware]] - Information about supported and experimental Fedora/RISC-V hardware


= Downloads =
= Get in touch =


* http://copr-fe.cloud.fedoraproject.org/coprs/rjones/riscv/
Most of the people working on the effort hang out in [https://app.element.io/#/room/#riscv:fedoraproject.org Fedora RISC-V Matrix room]. Come say hello :)
** COPR repository (for Fedora 24/x86_64) containing: QEMU, Spike, cross-compiler toolchain
* https://github.com/rwmjones/fedora-riscv
** Git repository containing the bootstrapping work. Read the README file!
* http://oirase.annexia.org/riscv/
** Interim stage3 disk image.


= Status =
Follow (and post to!) [https://discussion.fedoraproject.org/tag/risc-v-sig #risc-v-sig on Fedora Discussion]! (If you prefer, you can follow this tag by email.)


Last updated: 2016-08-16
= News =


Status: The stage3 disk image boots to a shell, with GCC, numerous developer utilities, and rpmbuild.
'''Jan 2025''' [https://dl.fedoraproject.org/pub/alt/risc-v/release/41/ Fedora 41] images are now available.


I have started using the stage3 to build stage4 RPMs.
= Additional resources =


For the latest information, see:
; https://fedoraproject.org/wiki/SIGs/RISC-V
https://github.com/rwmjones/fedora-riscv
: RISC-V SIG


= Communications =
: https://riscv-koji.fedoraproject.org/koji/
: Koji build system in Fedora data center. In time it will be accessible to all Fedora packagers for submitting builds.


There is no specific mailing list.  Use [https://lists.fedoraproject.org/admin/lists/devel.lists.fedoraproject.org/ Fedora devel] for now.
; http://fedora.riscv.rocks/koji/
: Koji build system


On FreeNode IRC: <code>#fedora-riscv</code>
; http://fedora.riscv.rocks:3000/
: RISC-V Package Sources


= People =
; https://abologna.gitlab.io/fedora-riscv-tracker/
: Track the progress of upstreaming changes to Fedora


* [[RichardJones|Richard Jones]] <br>
= Outdated information =
<i>(add your name here)</i>


= Building packages in stage3 =
Over time, we have accumulated lots of information on this wiki. A large chunk of it, while useful at the time, is not really relevant to anyone looking to run Fedora on RISC-V today, or contribute to the porting effort. To avoid any confusion, all outdated material has been moved to the [[Architectures/RISC-V/Archive|Archive]].
 
The stage3 environment can be built from source or you can download a snapshot binary image.  See above for links to git etc.
 
Pick a package which:
* has very few dependencies
* is written in C or C++
* is part of Fedora @Core
 
Grab the source RPM from [http://koji.fedoraproject.org/koji/ Koji].
 
Copy the source RPM into the stage3 disk image.  The disk image <b>must not</b> be running when you do this:
 
virt-copy-in -a stage3-disk.img the_package.src.rpm /var/tmp/
 
Boot the disk image in qemu:
 
make boot-stage3-in-qemu
 
Inside the VM you can now "install" the source RPM, which makes it available under <code>/rpmbuild</code>:
 
rpm -i /var/tmp/the_package.src.rpm
cd /rpmbuild/SPECS
 
You may need to disable hardened build by adding:
 
%undefine _hardened_build
 
to the spec file.  Use <code>vim</code> to edit files.
 
You can now try building the package:
 
rpmbuild -ba the_package.spec --define "debug_package %{nil}"
 
If it builds successfully, brilliant!  More usually this will require many cycles of debugging and fixing things.  Removing dependencies or parts of the spec file is an option for these stage3 builds.
 
If you get a build, it will be in <code>/rpmbuild</code> inside the VM.  sync and shut down the VM, then do:
 
virt-copy-out -a stage3-disk.img /rpmbuild ./
 
and the files will be downloaded to ./SRPMS and ./RPMS in the current directory.  Note: Keep the source RPM too, especially if you modified it.
 
Add notes to the section below.  Also come to <code>#fedora-riscv</code> and discuss where to put your built packages.
 
== Notes on packages built so far ==
 
<i>The list of packages in this section was constantly out of date, so I deleted it</i>
 
To see the packages which have been built so far, look in the git repo.  If you are planning to port another package, please ping us on <code>#fedora-riscv</code> first, just to make sure that two people don't do overlapping work.
 
=== "all-recursive" bug in make ===
 
Making all in .
Makefile:742: recipe for target 'all-recursive' failed
 
Added this to the spec file as a workaround:
 
sed 's/\$(am__cd) \$\$subdir \&\&/cd $$subdir ;/g' -i Makefile.in
 
=== debugedit missing ===
 
Use <code>%global debug_package %{nil}</code> (temporarily for stage3, in stage4 we will attempt to build the debuginfo packages).
 
=== bugs about locking, random "Permission denied" ===
 
Update to the latest riscv-gnu-toolchain and rebuild the kernel from the repo.  All known locking bugs have been fixed.

Latest revision as of 16:58, 19 February 2025

RISC-V (pronounced "RISC Five") is an open source instruction set architecture (ISA). This project, informally called Fedora/RISC-V, aims to provide a complete Fedora experience on the RISC-V (64 bit, RV64GC) architecture.

Topics

  • Installing - How to download, install and run Fedora/RISC-V.
  • Hardware - Information about supported and experimental Fedora/RISC-V hardware

Get in touch

Most of the people working on the effort hang out in Fedora RISC-V Matrix room. Come say hello :)

Follow (and post to!) #risc-v-sig on Fedora Discussion! (If you prefer, you can follow this tag by email.)

News

Jan 2025 Fedora 41 images are now available.

Additional resources

https://fedoraproject.org/wiki/SIGs/RISC-V
RISC-V SIG
https://riscv-koji.fedoraproject.org/koji/
Koji build system in Fedora data center. In time it will be accessible to all Fedora packagers for submitting builds.
http://fedora.riscv.rocks/koji/
Koji build system
http://fedora.riscv.rocks:3000/
RISC-V Package Sources
https://abologna.gitlab.io/fedora-riscv-tracker/
Track the progress of upstreaming changes to Fedora

Outdated information

Over time, we have accumulated lots of information on this wiki. A large chunk of it, while useful at the time, is not really relevant to anyone looking to run Fedora on RISC-V today, or contribute to the porting effort. To avoid any confusion, all outdated material has been moved to the Archive.