linuxdeploy icon indicating copy to clipboard operation
linuxdeploy copied to clipboard

build more architectures

Open sithlord48 opened this issue 3 years ago • 4 comments

Try to build more architectures

  • aarch64
  • armv7
  • armv6
  • ppc64le
  • s390x Build Status Can be seen here

sithlord48 avatar Jan 12 '22 14:01 sithlord48

I'm not sure whether all these architectures should be added. I've told the last person to send such a PR to create an issue first. Please wait for me to have a look before spending more time on this.

TheAssassin avatar Jan 12 '22 15:01 TheAssassin

I'm not sure whether all these architectures should be added. I've told the last person to send such a PR to create an issue first. Please wait for me to have a look before spending more time on this.

I have an issue where i want to ship appimages but if i have arm builds i have to build the tooling . why do that in my own repo when we can just do it here

sithlord48 avatar Jan 12 '22 17:01 sithlord48

I have a slight issue in the build, I will wait to hear back from @TheAssassin before i update this further.

sithlord48 avatar Jan 13 '22 12:01 sithlord48

Note that linuxdeploy-plugin-appimage is embedded in the linuxdeploy AppImages. You will likely have to have it built for the foreign architectures as well.

TheAssassin avatar Jan 24 '22 22:01 TheAssassin

This is outdated, and most of the criticism was never picked up. I plan to add more architectures myself.

TheAssassin avatar Oct 25 '23 00:10 TheAssassin

@TheAssassin Not sure how advanced you are with this, but I may perhaps be able to help with armhf & aarch64? I've just started to look at AppImage for a (unfortunately private) project that I contribute to where we create cross compiled binaries for Raspberry Pi on GHA ubuntu runners (no Docker, third party plugins etc, just GHA yaml scripts)

The 'nuclear option' approach I took (after many failures) was to create cross toolchains using crosstool-ng with glibc & gcc targeted for compatibility with the Debian 11 'bullseye' system libs, and generate sysroots directly from the Raspbian/Debian mirrors using mk-sbuild The sysroots and toolchains are then cached using GHA.

I could possibly extract some of that stuff into here, although I've not even built linuxdeploy yet. A sticky point might be that I was using an older GCC (10.4.0) and glibc (2.31) for 'out-of-the-box' compatibility with the older bullseye libstdc++ system lib which places limits on newer C++ standards use. That's probably easily fixed by building with newer versions and bundling libstdc++ though.

Is there a minimum version of GCC required to build linuxdeploy?

Not sure what approach you intended to take, but let me know if you think any of this would be useful to you?

neildavis avatar Nov 03 '23 11:11 neildavis

The plan is to do what I've done for other repositories, which means long build times but runs with little to no maintenance: use QEMU to run ARM Docker containers as a build environment. This approach works fine both locally and on GitHub actions, and should be rather straightforward to implement (famous last words). Cross compiling is a lot more effort. This tool is not complex enough to justify that effort.

I can't tell you the definite minimum GCC version, but the tool requires C++17 as a minimum. GCC 7 should suffice. I'd just try.

I just build on relatively recent distros and provide static binaries for linuxdeploy itself nowadays, as it was too much effort to support platforms like CentOS 7 (which, unfortunately, continues to be supported until next year, at least on paper). I'm not a fan of static binaries in general, but for such small utilities which are used on such a variety of platforms, it's totally justified.

TheAssassin avatar Nov 03 '23 11:11 TheAssassin