eclipse-platform / eclipse.platform

https://eclipse.dev/eclipse/
Eclipse Public License 2.0
67 stars 100 forks source link

Add riscv64 build support #1431

Open yuzibo opened 4 weeks ago

yuzibo commented 4 weeks ago

Steps to reproduce

I am trying to build eclipse on riscv64, but unfortunately it failed. I have posted this on eclipse-dev mail list.

Here is some relevant log output

The log see here

Tested under this environment:

From other eclipse developers' help, I think maybe it is easy to add riscv64 build support, just some build stack get updated in time, but maybe we have setup riscv ci env from #565419. Do we have a plan to support it?

Sorry if I bring the noise.

Community

HannesWell commented 4 weeks ago

I am trying to build eclipse on riscv64, but unfortunately it failed. I have posted this on eclipse-dev mail list.

Since the log mentions some unresolved requirements for packages from UI plugins I assume the initial problem is that there is no SWT fragment for your platform (i.e. OS, WS and arch combination) available. So you probably have to create a org.eclipse.swt.gtk.linux.riscv64 fragment (not sure what the 'official' OSGi name is for that architecture) and build the SWT native binaries for it. How to build them is explained in the ReadMe of https://github.com/eclipse-platform/eclipse.platform.swt/blob/7ac43c0d40016f04974ae6ef971f4e5f39bd3c3c/bundles/org.eclipse.swt/Readme.md#building-and-testing-locally and the co-located OS specific ReadMe files.

If you want to build a product you probably have to do something similar for the Equinox launcher binaries.

Issue https://github.com/eclipse-platform/eclipse.platform.releng.aggregator/issues/577 should give you a good impression about what has to be done (it should now be simpler than when that issue started).

From other eclipse developers' help, I think maybe it is easy to add riscv64 build support, just some build stack get updated in time, but maybe we have setup riscv ci env from #565419. Do we have a plan to support it?

As far as I can tell there is no plan to support it yet, but if it is important for a wider audience it can be considered. The 'main' difficulty to support it 'officially' by Eclipse is to get a dedicated machine to build the native binaries and run the tests into the Eclipse Jenkins agent pool. Unfortunately, for reasons of security, sustainability and manageability, it is not possible to just provide such a machine. Someone has to sponsor it and the Eclipse-Foundation IT team then purchases an agent and adds it to the pool: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/issues/1110

yuzibo commented 3 weeks ago

Hi,

Thank you very much for your help here.

Since the log mentions some unresolved requirements for packages from UI plugins I assume the initial problem is that there is no SWT fragment for your platform (i.e. OS, WS and arch combination) available. So you probably have to create a org.eclipse.swt.gtk.linux.riscv64 fragment (not sure what the 'official' OSGi name is for that architecture) and build the SWT native binaries for it. How to build them is explained in the ReadMe of https://github.com/eclipse-platform/eclipse.platform.swt/blob/7ac43c0d40016f04974ae6ef971f4e5f39bd3c3c/bundles/org.eclipse.swt/Readme.md#building-and-testing-locally and the co-located OS specific ReadMe files.

If you want to build a product you probably have to do something similar for the Equinox launcher binaries.

Issue eclipse-platform/eclipse.platform.releng.aggregator#577 should give you a good impression about what has to be done (it should now be simpler than when that issue started).

Okay, let me try it with your guide. For me I am not familiar with mvn build system, so maybe it cost some time on how to it works.

From other eclipse developers' help, I think maybe it is easy to add riscv64 build support, just some build stack get updated in time, but maybe we have setup riscv ci env from #565419. Do we have a plan to support it?

As far as I can tell there is no plan to support it yet, but if it is important for a wider audience it can be considered. The 'main' difficulty to support it 'officially' by Eclipse is to get a dedicated machine to build the native binaries and run the tests into the Eclipse Jenkins agent pool. Unfortunately, for reasons of security, sustainability and manageability, it is not possible to just provide such a machine. Someone has to sponsor it and the Eclipse-Foundation IT team then purchases an agent and adds it to the pool: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/issues/1110

Okay, no problem. I think the issue can be viewed as headup for support riscv64 and if someone has interesting that would be great. So let us wait some time and see what happened. For riscv64 hardware, I will look for any chances to reach out this(sponsor it).

Thanks again.