Hi everyone,
I am Sun Haiyong, from China. I want to port Fedora for the LoongArch architecture. LoongArch is a RISC ISA released by Loongson Technology Corporation Limited, and has supported a series of (Binutils, GCC, Linux, Glibc, LLVM, QEMU, etc.) core open source projects.
Currently, there are many linux distributions that can run on LoongArch machines, they are OpenEuler, OpenAnolis, UOS, Kylin.
I am good at cross-compiling operating systems and often build Linux systems using something like LFS or CLFS.
I have built Linux distributions using rpm package management from scratch several times since 2015 (some systems are not publicly available):
1 Fedora 21, 28, 32 based on MIPS64EL architecture; 2 CentOS 7 based on MIPS64EL architecture; 3 CentOS 7 based on Power8 architecture; 4 CentOS 8.3 based on LoongArch architecture; 5 OpenEuler 2109 based on LoongArch architecture.
And I have published a book on porting Fedora systems to new architectures.
I want to add LoongArch to the official Fedora support architecture, and I've been doing so for some time, here's some of what I've done so far:
To verify the feasibility of building a LoongArch architecture branch for Fedora, I have used the software version from the rawhide git repository, and have now compiled a large number of base packages and built a temporary repository that can be accessed at https://mirrors.wsyu.edu.cn/fedora/
I have compiled and generated more than 45,000 installable rpm files (of course there are a lot of perl, Python, rust and texlive files), and the number is still expanding, the scope of the package is enough to build a LiveCD system, for which I have built LXDE, MATE, WorkStation ( Gnome3) of the LiveCD and the installation of the ISO, you can get in the following address: https://github.com/fedora-remix-loongarch/releases-info
Of course, there are still a lot of problems with LoongArch's Fedora system, for example, some software is not yet fully supported by the upstream community, but I believe the power of the community can gradually improve them, so I am sending out an email here to get more people to support this new LoongArch architecture.
I have recruited some developers who are interested in this and they are:
Wu Xiaotian Chen Huacai Shi Pujin Si Yanteng Chen Feiyang
Of course, there are many other users who are interested in Fedora systems.
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
Again, thanks for reading this email.
Best Regards Sun Haiyong
On Tue, Jan 10, 2023 at 10:13 AM 孙海勇 sunhaiyong@zdbr.net wrote:
Hi everyone,
I am Sun Haiyong, from China. I want to port Fedora for the LoongArch architecture. LoongArch is a RISC ISA released by Loongson Technology Corporation Limited, and has supported a series of (Binutils, GCC, Linux, Glibc, LLVM, QEMU, etc.) core open source projects.
Currently, there are many linux distributions that can run on LoongArch machines, they are OpenEuler, OpenAnolis, UOS, Kylin.
I am good at cross-compiling operating systems and often build Linux systems using something like LFS or CLFS.
I have built Linux distributions using rpm package management from scratch several times since 2015 (some systems are not publicly available):
1 Fedora 21, 28, 32 based on MIPS64EL architecture; 2 CentOS 7 based on MIPS64EL architecture; 3 CentOS 7 based on Power8 architecture; 4 CentOS 8.3 based on LoongArch architecture; 5 OpenEuler 2109 based on LoongArch architecture.
And I have published a book on porting Fedora systems to new architectures.
I want to add LoongArch to the official Fedora support architecture, and I've been doing so for some time, here's some of what I've done so far:
To verify the feasibility of building a LoongArch architecture branch for Fedora, I have used the software version from the rawhide git repository, and have now compiled a large number of base packages and built a temporary repository that can be accessed at https://mirrors.wsyu.edu.cn/fedora/
I have compiled and generated more than 45,000 installable rpm files (of course there are a lot of perl, Python, rust and texlive files), and the number is still expanding, the scope of the package is enough to build a LiveCD system, for which I have built LXDE, MATE, WorkStation ( Gnome3) of the LiveCD and the installation of the ISO, you can get in the following address: https://github.com/fedora-remix-loongarch/releases-info
Of course, there are still a lot of problems with LoongArch's Fedora system, for example, some software is not yet fully supported by the upstream community, but I believe the power of the community can gradually improve them, so I am sending out an email here to get more people to support this new LoongArch architecture.
I have recruited some developers who are interested in this and they are:
Wu Xiaotian Chen Huacai Shi Pujin Si Yanteng Chen Feiyang
Of course, there are many other users who are interested in Fedora systems.
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
Again, thanks for reading this email.
I think a starting point is to talk to Fedora Infrastructure and Release Engineering about this.
Also, is there any server-class hardware that can be racked for us to power builds? We don't typically do emulated builds because they're incredibly slow.
That said, Fedora RISC-V is probably a good blueprint for how to get started bootstrapping LoongArch in Fedora. Those folks are here on this list and they can reply with some details (I don't remember exactly how they did it).
-- 真実はいつも一つ!/ Always, there's only one truth!
在 2023/1/10 23:54, Neal Gompa 写道:
On Tue, Jan 10, 2023 at 10:13 AM 孙海勇 sunhaiyong@zdbr.net wrote:
Hi everyone,
I am Sun Haiyong, from China. I want to port Fedora for the LoongArch architecture. LoongArch is a RISC ISA released by Loongson Technology Corporation Limited, and has supported a series of (Binutils, GCC, Linux, Glibc, LLVM, QEMU, etc.) core open source projects.
Currently, there are many linux distributions that can run on LoongArch machines, they are OpenEuler, OpenAnolis, UOS, Kylin.
I am good at cross-compiling operating systems and often build Linux systems using something like LFS or CLFS.
I have built Linux distributions using rpm package management from scratch several times since 2015 (some systems are not publicly available):
1 Fedora 21, 28, 32 based on MIPS64EL architecture; 2 CentOS 7 based on MIPS64EL architecture; 3 CentOS 7 based on Power8 architecture; 4 CentOS 8.3 based on LoongArch architecture; 5 OpenEuler 2109 based on LoongArch architecture.
And I have published a book on porting Fedora systems to new architectures.
I want to add LoongArch to the official Fedora support architecture, and I've been doing so for some time, here's some of what I've done so far:
To verify the feasibility of building a LoongArch architecture branch for Fedora, I have used the software version from the rawhide git repository, and have now compiled a large number of base packages and built a temporary repository that can be accessed at https://mirrors.wsyu.edu.cn/fedora/
I have compiled and generated more than 45,000 installable rpm files (of course there are a lot of perl, Python, rust and texlive files), and the number is still expanding, the scope of the package is enough to build a LiveCD system, for which I have built LXDE, MATE, WorkStation ( Gnome3) of the LiveCD and the installation of the ISO, you can get in the following address: https://github.com/fedora-remix-loongarch/releases-info
Of course, there are still a lot of problems with LoongArch's Fedora system, for example, some software is not yet fully supported by the upstream community, but I believe the power of the community can gradually improve them, so I am sending out an email here to get more people to support this new LoongArch architecture.
I have recruited some developers who are interested in this and they are:
Wu Xiaotian Chen Huacai Shi Pujin Si Yanteng Chen Feiyang
Of course, there are many other users who are interested in Fedora systems.
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
Again, thanks for reading this email.
I think a starting point is to talk to Fedora Infrastructure and Release Engineering about this.
Also, is there any server-class hardware that can be racked for us to power builds? We don't typically do emulated builds because they're incredibly slow.
That said, Fedora RISC-V is probably a good blueprint for how to get started bootstrapping LoongArch in Fedora. Those folks are here on this list and they can reply with some details (I don't remember exactly how they did it).
Thanks! We have completed the bootstrap steps, and we want to learn more about how to further interface with Fedora's build system.
Regards,
Haiyong
-- 真実はいつも一つ!/ Always, there's only one truth! _______________________________________________ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
On Tue, Jan 10, 2023 at 11:12:22PM +0800, 孙海勇 wrote:
I want to add LoongArch to the official Fedora support architecture,
This is really cool -- welcome, and I'd love to help make sure you succeed!
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
This message is a good start! There is a little bit of information here https://fedoraproject.org/wiki/Architectures, but it's not really complete. I'm afraid a lot of the knowledge is really held in a few people's heads. Hopefully we can get you connected with the right people!
Hi Folks,
On Tue, Jan 10, 2023 at 11:12:22PM +0800, 孙海勇 wrote:
I want to add LoongArch to the official Fedora support architecture,
This is really cool -- welcome, and I'd love to help make sure you succeed!
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
This message is a good start! There is a little bit of information here https://fedoraproject.org/wiki/Architectures, but it's not really complete. I'm afraid a lot of the knowledge is really held in a few people's heads. Hopefully we can get you connected with the right people!
There's generally about a 5 stage process from initial bootstrap of an arch to mainline Fedora support, it roughly lays out as follows: 1) Low level toolchain bring up 2) A small Linux kernel+userspace 3) Using 2) to build a reduced size/dep standard Fedora rpm userspace of a random Fedora release 4) Standalone koji instance shadowing the primary Fedora instance 5) Proposal to merge/import the architecture packages into the main Fedora koji instance
From your previous message [1] I gather you're basically now at 3) but I'm not sure if you're yet at 4 and doing a shadow build operation of rawhide.
As part of stages 3 and 4 you'll likely have a bunch of hacks, patches and changes to both upstream project releases to add support for the architecture, or possibly as simple as bumping autoconf macros to detect the architecture that are required to get things to build or run. This will include things like spec changes that need to get merged into Fedora package git repos. Long before we get to proposing 5) this needs to be done and the shadow instance of koji should ultimately be building unchanged packages.
Also before becoming a main Fedora architecture the infrastructure team will need to be able to source enterprise grade hardware that can be racked in a datacentre and remotely managed. There's likely some other requirements the infrastructure team has here.
We have in the past not progressed to stage 5 on a number of archtectures, and aarch64 was delayed for some time from this, due to lack of readily available hardware for people to be able to purchase for testing, development and just general hacking purposes. I have read some articles about restrictions on getting Loongson chips [2] but I am not sure if that's all variants or just a subset of the Loongson architecture. I have in the past actually looked at getting a Loongson device or two but ultimately gave up because it was far from straight forward, this may end up being a problem.
Peter
[1] https://lists.fedoraproject.org/archives/list/secondary@lists.fedoraproject.... [2] https://www.theregister.com/2022/12/15/china_loongson_chip_export_ban/
在 2023/1/11 14:24, Peter Robinson 写道:
主题: Re: Porting Fedora for the LoongArch architecture. From: Peter Robinson pbrobinson@gmail.com 日期: 2023/1/11 14:24
收件人: Development discussions related to Fedora devel@lists.fedoraproject.org 抄送: "siyanteng@loongson.cn" siyanteng@loongson.cn, "chenhuacai@loongson.cn" chenhuacai@loongson.cn, "shipujin.t@gmail.com" shipujin.t@gmail.com, Xiaotian Wu wuxiaotian@loongson.cn, zhangfuxin@loongson.cn, chenfeiyang@loongson.cn
Hi Folks,
On Tue, Jan 10, 2023 at 11:12:22PM +0800, 孙海勇 wrote:
I want to add LoongArch to the official Fedora support architecture,
This is really cool -- welcome, and I'd love to help make sure you succeed!
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? 😄
This message is a good start! There is a little bit of information here https://fedoraproject.org/wiki/Architectures, but it's not really complete. I'm afraid a lot of the knowledge is really held in a few people's heads. Hopefully we can get you connected with the right people!
There's generally about a 5 stage process from initial bootstrap of an arch to mainline Fedora support, it roughly lays out as follows:
- Low level toolchain bring up
- A small Linux kernel+userspace
- Using 2) to build a reduced size/dep standard Fedora rpm userspace
of a random Fedora release 4) Standalone koji instance shadowing the primary Fedora instance 5) Proposal to merge/import the architecture packages into the main Fedora koji instance
From your previous message [1] I gather you're basically now at 3) but I'm not sure if you're yet at 4 and doing a shadow build operation of rawhide.
Yes, as you said, we are going to start on step 4.
As part of stages 3 and 4 you'll likely have a bunch of hacks, patches and changes to both upstream project releases to add support for the architecture, or possibly as simple as bumping autoconf macros to detect the architecture that are required to get things to build or run. This will include things like spec changes that need to get merged into Fedora package git repos. Long before we get to proposing 5) this needs to be done and the shadow instance of koji should ultimately be building unchanged packages.
Also before becoming a main Fedora architecture the infrastructure team will need to be able to source enterprise grade hardware that can be racked in a datacentre and remotely managed. There's likely some other requirements the infrastructure team has here.
We have in the past not progressed to stage 5 on a number of archtectures, and aarch64 was delayed for some time from this, due to lack of readily available hardware for people to be able to purchase for testing, development and just general hacking purposes. I have read some articles about restrictions on getting Loongson chips [2] but I am not sure if that's all variants or just a subset of the Loongson architecture. I have in the past actually looked at getting a Loongson device or two but ultimately gave up because it was far from straight forward, this may end up being a problem.
Thanks!everything is moving in a good direction, so if you have time, stay tuned to LoongArch.
Regards,
Haiyong
Peter
[1]https://lists.fedoraproject.org/archives/list/secondary@lists.fedoraproject.... [2]https://www.theregister.com/2022/12/15/china_loongson_chip_export_ban/ _______________________________________________ devel mailing list --devel@lists.fedoraproject.org To unsubscribe send an email todevel-leave@lists.fedoraproject.org Fedora Code of Conduct:https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines:https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives:https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it:https://pagure.io/fedora-infrastructure/new_issue
On 1/11/23 01:24, Peter Robinson wrote:
Also before becoming a main Fedora architecture the infrastructure team will need to be able to source enterprise grade hardware that can be racked in a datacentre and remotely managed. There's likely some other requirements the infrastructure team has here.
The Registrer claims that China is banning exports of Loongson hardware
https://www.theregister.com/2022/12/15/china_loongson_chip_export_ban/
I have no additional information, just reporting what I saw on the Internet.
在 2023/1/11 0:20, Matthew Miller 写道:
On Tue, Jan 10, 2023 at 11:12:22PM +0800, 孙海勇 wrote:
I want to add LoongArch to the official Fedora support architecture,
This is really cool -- welcome, and I'd love to help make sure you succeed!
Thank you very much!
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
This message is a good start! There is a little bit of information here https://fedoraproject.org/wiki/Architectures, but it's not really complete. I'm afraid a lot of the knowledge is really held in a few people's heads. Hopefully we can get you connected with the right people!
Thanks for the link! Thank you!
Regards,
Haiyong
On Tue, Jan 10, 2023 at 11:13 PM 孙海勇 sunhaiyong@zdbr.net wrote:
Hi everyone,
I am Sun Haiyong, from China. I want to port Fedora for the LoongArch architecture. LoongArch is a RISC ISA released by Loongson Technology Corporation Limited, and has supported a series of (Binutils, GCC, Linux, Glibc, LLVM, QEMU, etc.) core open source projects.
Currently, there are many linux distributions that can run on LoongArch machines, they are OpenEuler, OpenAnolis, UOS, Kylin.
I am good at cross-compiling operating systems and often build Linux systems using something like LFS or CLFS.
I have built Linux distributions using rpm package management from scratch several times since 2015 (some systems are not publicly available):
1 Fedora 21, 28, 32 based on MIPS64EL architecture; 2 CentOS 7 based on MIPS64EL architecture; 3 CentOS 7 based on Power8 architecture; 4 CentOS 8.3 based on LoongArch architecture; 5 OpenEuler 2109 based on LoongArch architecture.
And I have published a book on porting Fedora systems to new architectures.
I want to add LoongArch to the official Fedora support architecture, and I've been doing so for some time, here's some of what I've done so far:
To verify the feasibility of building a LoongArch architecture branch for Fedora, I have used the software version from the rawhide git repository, and have now compiled a large number of base packages and built a temporary repository that can be accessed at https://mirrors.wsyu.edu.cn/fedora/
I have compiled and generated more than 45,000 installable rpm files (of course there are a lot of perl, Python, rust and texlive files), and the number is still expanding, the scope of the package is enough to build a LiveCD system, for which I have built LXDE, MATE, WorkStation ( Gnome3) of the LiveCD and the installation of the ISO, you can get in the following address: https://github.com/fedora-remix-loongarch/releases-info
Of course, there are still a lot of problems with LoongArch's Fedora system, for example, some software is not yet fully supported by the upstream community, but I believe the power of the community can gradually improve them, so I am sending out an email here to get more people to support this new LoongArch architecture.
I have recruited some developers who are interested in this and they are:
Wu Xiaotian Chen Huacai Shi Pujin Si Yanteng Chen Feiyang
Of course, there are many other users who are interested in Fedora systems.
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
Again, thanks for reading this email.
Hi, 海勇 and other LoongArch contributors!
I am a long-term Chinese Fedora packager. I also got interested in LoongArch recently and started to create some PRs[1][2] related to LoongArch.
Please feel free to reach out to me personally. I hope I can help you from the Fedora side.
[1] https://src.fedoraproject.org/rpms/cross-binutils/pull-request/2 [2] https://src.fedoraproject.org/rpms/cross-gcc/pull-request/3 -robin
Best Regards Sun Haiyong _______________________________________________ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
在 2023/1/11 0:50, Robin Lee 写道:
On Tue, Jan 10, 2023 at 11:13 PM 孙海勇 sunhaiyong@zdbr.net wrote:
Hi everyone,
I am Sun Haiyong, from China. I want to port Fedora for the LoongArch architecture. LoongArch is a RISC ISA released by Loongson Technology Corporation Limited, and has supported a series of (Binutils, GCC, Linux, Glibc, LLVM, QEMU, etc.) core open source projects.
Currently, there are many linux distributions that can run on LoongArch machines, they are OpenEuler, OpenAnolis, UOS, Kylin.
I am good at cross-compiling operating systems and often build Linux systems using something like LFS or CLFS.
I have built Linux distributions using rpm package management from scratch several times since 2015 (some systems are not publicly available):
1 Fedora 21, 28, 32 based on MIPS64EL architecture; 2 CentOS 7 based on MIPS64EL architecture; 3 CentOS 7 based on Power8 architecture; 4 CentOS 8.3 based on LoongArch architecture; 5 OpenEuler 2109 based on LoongArch architecture.
And I have published a book on porting Fedora systems to new architectures.
I want to add LoongArch to the official Fedora support architecture, and I've been doing so for some time, here's some of what I've done so far:
To verify the feasibility of building a LoongArch architecture branch for Fedora, I have used the software version from the rawhide git repository, and have now compiled a large number of base packages and built a temporary repository that can be accessed at https://mirrors.wsyu.edu.cn/fedora/
I have compiled and generated more than 45,000 installable rpm files (of course there are a lot of perl, Python, rust and texlive files), and the number is still expanding, the scope of the package is enough to build a LiveCD system, for which I have built LXDE, MATE, WorkStation ( Gnome3) of the LiveCD and the installation of the ISO, you can get in the following address: https://github.com/fedora-remix-loongarch/releases-info
Of course, there are still a lot of problems with LoongArch's Fedora system, for example, some software is not yet fully supported by the upstream community, but I believe the power of the community can gradually improve them, so I am sending out an email here to get more people to support this new LoongArch architecture.
I have recruited some developers who are interested in this and they are:
Wu Xiaotian Chen Huacai Shi Pujin Si Yanteng Chen Feiyang
Of course, there are many other users who are interested in Fedora systems.
I'm currently a newbie in the Fedora community, so I need help from community developers, and would like someone to guide me on what to do next, such as what would be a better time to submit necessary patches to packages in the Fedora repository, how to develop in a collaborative manner, what other systems to be used for management, etc. In short, any information would be useful. Could I get help here? :)
Again, thanks for reading this email.
Hi, 海勇 and other LoongArch contributors!
I am a long-term Chinese Fedora packager. I also got interested in LoongArch recently and started to create some PRs[1][2] related to LoongArch.
Please feel free to reach out to me personally. I hope I can help you from the Fedora side.
[1] https://src.fedoraproject.org/rpms/cross-binutils/pull-request/2 [2] https://src.fedoraproject.org/rpms/cross-gcc/pull-request/3 -robin
Thanks!if you don't mind, we can get it together.
Regards,
Haiyong
Best Regards Sun Haiyong _______________________________________________ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
Hi,
Porting Fedora to a new architecture is quite a challenge but a lot of fun. It sounds as if you've made a lot of progress already. A few thoughts from the Fedora/RISC-V effort ...
(1) Cross-compiling RPMs (eg. from x86-64 to LoongArch) isn't really useful. Almost any significantly complex RPM must be compiled on the same architecture as it targets. For example it may run tests or tools that it builds as part of building the RPM.
For Fedora/RISC-V the problem was that we didn't have a viable Linux environment to even run RPM on (in 2016), so I came up with a pretty nasty bootstrapping hack, which cross-compiled enough of an environment to be able to run rpmbuild. For historical interest that's here: https://github.com/rwmjones/fedora-riscv-bootstrap
However you won't need to use this. There already exists a major distro on LoongAch (ie. Debian). You could use Debian to build a base set of RPMs, and then once you have enough, install them into a buildroot and continue using the Fedora you've built.
(I guess from your email that you've already done something like this.)
(2) noarch RPMs don't need to be compiled! You can just copy them from x86-64. (At least for bootstrapping purposes, you'll want to be able to compile them eventually.) This is a nice time-saving tip to remember.
(3) For RISC-V we didn't start with Koji (used our own hacky build system), but did eventually set one up: http://fedora.riscv.rocks/koji/
You'll also want to set up a Koji instance eventually.
(4) As another reply mentioned, to get LoongArch as a primary Fedora architecture, an essential requirement is 19" rackable server-class hardware. It needs to be fully manageable through a BMC. Fedora will probably need a few such servers to be donated.
This is the main reason why RISC-V isn't a primary Fedora architecture yet, although progress is happening.
(5) PLEASE PLEASE PLEASE get your patches upstream! If they are patches to the upstream software, send them to the upstream maintainers. If they are patches to the RPM builds, add them to Fedora. (People on this list can help with both these tasks.)
Getting stuff upstream benefits the whole community beyond Fedora, and makes everyone's life easier.
Rich.
On Tue, 10 Jan 2023 at 17:37, Richard W.M. Jones rjones@redhat.com wrote:
Hi,
... clipped as I want to focus on this part.
(4) As another reply mentioned, to get LoongArch as a primary Fedora architecture, an essential requirement is 19" rackable server-class hardware. It needs to be fully manageable through a BMC. Fedora will probably need a few such servers to be donated.
This is usually the major hanging point for bringing up it as a 'main' OS. I am going to outline in depth what it takes from an operational side to get any new 'deliverable' into Fedora currently. I am not doing so to say 'this can't be done' as much as to explain why it can't usually be done at the speed most people seem to think can be done.
The complete Fedora koji build system has a lot of assumptions of being in the same datacenter with just one set of hardware remote and 'breaking' regularly due to that (mounts are being done over NFS over ssh and disconnect regularly.. connections between the main DC and other places may time out etc.). The build system is generally locked together so that if one architecture has slowness/problems it affects all builds on the other arches. Adding more architectures to this tends to add a non-linear complexity in places. [The opposite of having multiple koji's adds a different level of complexity and requires more dedicated people time which is in even shorter supply.]
The main DC is in the continental United States and in a 'lights' out facility (aka there are no hands in the facility regularly). This means that the hardware needs to be able to be managed remotely and be redundant so that it can 'work' in a degraded shape for weeks until replacements can be reached. There is no 'lab' for fixing equipment so the parts generally need to have a dedicated tech to fix. [Practically this means the hardware in the facility needs to be rated and insurable for this sort of data-center. Certain hardware is rated only for 'labs' or places where someone can unplug quickly if it smokes.. this is not that kind of place.]
The next issue is space to put more equipment into this facility. Pretty much every build architecture takes at least 1 full sized rack for the number of systems needed to keep up with builds. That requires additional planning as the space used is shared between multiple groups and may not be possible to add in quickly (or at all). Other solutions are possible but would require additional work and time. There are also the requirements for additional NFS storage, power, etc etc that each deliverable requires. Those all need to be added, budgeted for and purchased. [What has happened several times to slow things down is that it wasn't ordered/budgeted/purchased/put-in-place.. and well 6-12 months got lost making it happen.]
That all sounds like a lot of 'no' wrapped up in a 'it depends', but it can be done. In general it can be a 2-5 year process from when someone says 'Hey wouldn't it be great to build X' to getting the 'factory' built and working with the rest of the build system. During that time, usually a secondary external build system may be built elsewhere using shadow-koji or some other build tools to keep up and work out a lot of the bugs in the many parts of the build system (bodhi, koji, pungi, odcs, osbs, git, bugzilla, messaging system, pdc, mbs, oci, signing-infra, qa, koschei, and various things which are containers that affected/are affected by any build). Doing that allows for the eventual infusion of the arch into the main Fedora to take weeks versus months/year.
This is the main reason why RISC-V isn't a primary Fedora architecture yet, although progress is happening.
在 2023/1/11 21:15, Stephen Smoogen 写道:
主题: Re: Porting Fedora for the LoongArch architecture. From: Stephen Smoogen ssmoogen@redhat.com 日期: 2023/1/11 21:15
收件人: Development discussions related to Fedora devel@lists.fedoraproject.org 抄送: "siyanteng@loongson.cn" siyanteng@loongson.cn, "chenhuacai@loongson.cn" chenhuacai@loongson.cn, "shipujin.t@gmail.com" shipujin.t@gmail.com, Xiaotian Wu wuxiaotian@loongson.cn, zhangfuxin@loongson.cn, chenfeiyang@loongson.cn
On Tue, 10 Jan 2023 at 17:37, Richard W.M. Jones rjones@redhat.com wrote:
Hi,
... clipped as I want to focus on this part.
(4) As another reply mentioned, to get LoongArch as a primary Fedora architecture, an essential requirement is 19" rackable server-class hardware. It needs to be fully manageable through a BMC. Fedora will probably need a few such servers to be donated.
This is usually the major hanging point for bringing up it as a 'main' OS. I am going to outline in depth what it takes from an operational side to get any new 'deliverable' into Fedora currently. I am not doing so to say 'this can't be done' as much as to explain why it can't usually be done at the speed most people seem to think can be done.
The complete Fedora koji build system has a lot of assumptions of being in the same datacenter with just one set of hardware remote and 'breaking' regularly due to that (mounts are being done over NFS over ssh and disconnect regularly.. connections between the main DC and other places may time out etc.). The build system is generally locked together so that if one architecture has slowness/problems it affects all builds on the other arches. Adding more architectures to this tends to add a non-linear complexity in places. [The opposite of having multiple koji's adds a different level of complexity and requires more dedicated people time which is in even shorter supply.]
The main DC is in the continental United States and in a 'lights' out facility (aka there are no hands in the facility regularly). This means that the hardware needs to be able to be managed remotely and be redundant so that it can 'work' in a degraded shape for weeks until replacements can be reached. There is no 'lab' for fixing equipment so the parts generally need to have a dedicated tech to fix. [Practically this means the hardware in the facility needs to be rated and insurable for this sort of data-center. Certain hardware is rated only for 'labs' or places where someone can unplug quickly if it smokes.. this is not that kind of place.]
The next issue is space to put more equipment into this facility. Pretty much every build architecture takes at least 1 full sized rack for the number of systems needed to keep up with builds. That requires additional planning as the space used is shared between multiple groups and may not be possible to add in quickly (or at all). Other solutions are possible but would require additional work and time. There are also the requirements for additional NFS storage, power, etc etc that each deliverable requires. Those all need to be added, budgeted for and purchased. [What has happened several times to slow things down is that it wasn't ordered/budgeted/purchased/put-in-place.. and well 6-12 months got lost making it happen.]
That all sounds like a lot of 'no' wrapped up in a 'it depends', but it can be done. In general it can be a 2-5 year process from when someone says 'Hey wouldn't it be great to build X' to getting the 'factory' built and working with the rest of the build system. During that time, usually a secondary external build system may be built elsewhere using shadow-koji or some other build tools to keep up and work out a lot of the bugs in the many parts of the build system (bodhi, koji, pungi, odcs, osbs, git, bugzilla, messaging system, pdc, mbs, oci, signing-infra, qa, koschei, and various things which are containers that affected/are affected by any build). Doing that allows for the eventual infusion of the arch into the main Fedora to take weeks versus months/year.
This is the main reason why RISC-V isn't a primary Fedora architecture yet, although progress is happening.
Thank you so much!
The information you provided is very useful and this information can save us a lot of trouble.
I'm going to digest this information slowly next.
Regards,
Haiyong
-- Stephen Smoogen, Red Hat Automotive Let us be kind to one another, for most of us are fighting a hard battle. -- Ian MacClaren
devel mailing list --devel@lists.fedoraproject.org To unsubscribe send an email todevel-leave@lists.fedoraproject.org Fedora Code of Conduct:https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines:https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives:https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it:https://pagure.io/fedora-infrastructure/new_issue
Hi
在 2023/1/11 6:37, Richard W.M. Jones 写道:
Hi,
Porting Fedora to a new architecture is quite a challenge but a lot of fun. It sounds as if you've made a lot of progress already. A few thoughts from the Fedora/RISC-V effort ...
(1) Cross-compiling RPMs (eg. from x86-64 to LoongArch) isn't really useful. Almost any significantly complex RPM must be compiled on the same architecture as it targets. For example it may run tests or tools that it builds as part of building the RPM.
For Fedora/RISC-V the problem was that we didn't have a viable Linux environment to even run RPM on (in 2016), so I came up with a pretty nasty bootstrapping hack, which cross-compiled enough of an environment to be able to run rpmbuild. For historical interest that's here: https://github.com/rwmjones/fedora-riscv-bootstrap
However you won't need to use this. There already exists a major distro on LoongAch (ie. Debian). You could use Debian to build a base set of RPMs, and then once you have enough, install them into a buildroot and continue using the Fedora you've built.
(I guess from your email that you've already done something like this.)
Yes, I use cross-compilation to build the bootstrap environment, and use it to create an rpm group that is sufficient to build the rest of the system self-sufficiently, and then use this package group to build the whole system.
(2) noarch RPMs don't need to be compiled! You can just copy them from x86-64. (At least for bootstrapping purposes, you'll want to be able to compile them eventually.) This is a nice time-saving tip to remember.
(3) For RISC-V we didn't start with Koji (used our own hacky build system), but did eventually set one up: http://fedora.riscv.rocks/koji/
You'll also want to set up a Koji instance eventually.
We're already setting up koji.
(4) As another reply mentioned, to get LoongArch as a primary Fedora architecture, an essential requirement is 19" rackable server-class hardware. It needs to be fully manageable through a BMC. Fedora will probably need a few such servers to be donated.
This is the main reason why RISC-V isn't a primary Fedora architecture yet, although progress is happening.
This is a difficult task, but I will try to do it.
(5) PLEASE PLEASE PLEASE get your patches upstream! If they are patches to the upstream software, send them to the upstream maintainers. If they are patches to the RPM builds, add them to Fedora. (People on this list can help with both these tasks.)
Ok, I will do these as soon as possible.
Getting stuff upstream benefits the whole community beyond Fedora, and makes everyone's life easier.
Thank you very much!
Regards,
Haiyong
Rich.
On Wed, Jan 11, 2023 at 4:34 PM Zbigniew Jędrzejewski-Szmek zbyszek@in.waw.pl wrote:
On Tue, Jan 10, 2023 at 11:12:22PM +0800, 孙海勇 wrote:
Hi everyone,
I am Sun Haiyong, from China. I want to port Fedora for the LoongArch architecture.
Cool!
What is the status of qemu support?
QEMU support is fully upstreamed. Qemu[1] in F38/Rawhide already built loongarch64 sub-packages. EDK2 support is also upstreamed but Fedora does not catch up. We can download edk2-loongarch64-code.fd from here[2]
[1] https://koji.fedoraproject.org/koji/buildinfo?buildID=2102503 [2] https://github.com/loongson/Firmware/blob/b5cbb26048ab3000e76df9ebae72a2a3ec... -robin
Zbyszek _______________________________________________ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
On Wed, Jan 11, 2023 at 05:26:33PM +0800, Robin Lee wrote:
EDK2 support is also upstreamed but Fedora does not catch up.
There is no cross compiler (yet) in Fedora so I can hardly build edk2 firmware binaries ...
I expect that will change when the gcc-13 update lands in rawhide.
take care, Gerd
On Wed, 11 Jan 2023 11:45:59 +0100 Gerd Hoffmann kraxel@redhat.com wrote:
On Wed, Jan 11, 2023 at 05:26:33PM +0800, Robin Lee wrote:
EDK2 support is also upstreamed but Fedora does not catch up.
There is no cross compiler (yet) in Fedora so I can hardly build edk2 firmware binaries ...
I expect that will change when the gcc-13 update lands in rawhide.
right now we have a FTBFS issue in cross-binutils after their rebase to 2.39. Once solved we can continue with cross-gcc and the LoongArch PRs, which are pretty straightforward.
Dan
Is there still any work being done on this? I'm interested in running Fedora on LoongArch and helping with the porting efforts. I do have hardware as well (it's available on AliExpress, even outside of China).