electron-userland / electron-builder-binaries

172 stars 60 forks source link

Please update fpm to fix rpm aarch64 build #49

Open MrMYHuang opened 2 years ago

MrMYHuang commented 2 years ago

The aarch64 rpm built by electron-builder 23.0.4 can not installed on Fedora 35 Linux aarch64. For example,

sudo rpm -i https://github.com/MrMYHuang/cbetar2/releases/download/v19.0.0/cbetar2_19.0.0_linux_aarch64.rpm
        package cbetar2-19.0.0-1.arm64 is intended for a different architecture                                           

It seems to be a bug of fpm https://github.com/jordansissel/fpm/pull/1775 It has been fixed in fpm 1.13.0: https://fpm.readthedocs.io/en/v1.13.1/changelog.html?highlight=arm64

Please update fpm to the latest version for fixing this issue. Thanks.

MrMYHuang commented 2 years ago

I find a workaround: https://github.com/electron-userland/electron-builder/issues/5154#issuecomment-815962946

sudo dnf install ruby ruby-devel
sudo gem install fpm
export USE_SYSTEM_FPM=true

electron-builder 23.0.4 works well with fpm-1.14.2 to build correct rpms on Fedora 35 Linux aarch64.

mmaietta commented 2 years ago

Happy to review a PR! Setting up a dev env should be fairly simple: https://github.com/electron-userland/electron-builder/blob/master/CONTRIBUTING.md#to-setup-a-local-dev-environment

mkurz commented 1 year ago

Probably compiling for arm64/aarch64 will not be enough, also app-builder-bin needs to be aware of such an new version. I wrote a guide here: https://github.com/signalapp/Signal-Desktop/issues/6063#issuecomment-1307001166 Feel free to pick up that work.

pinkisemils commented 1 year ago

The fix for this is to pass different arguments to fpm when building an RPM package for aarch64 - specifically, instead of passing --architecture arm64, one should be passing --architecture aarch64. Of course, maybe newer versions of FPM will do the switcheroo themselves.

jgresham commented 5 months ago

@develar if I can build a binary of a arm64/aarch64 fpm version, will you add it to the releases?

jgresham commented 5 months ago

I believe I have an arm64 executable for fpm https://github.com/jgresham/fpm-arm-binary along with a shell scrip to generate the binary. Compiles fpm v1.15.1

cc @mmaietta @mkurz @develar

mkurz commented 5 months ago

@jgresham I am not part of any project here and will not work on anything. I leave that to others. But thank you very much for you work and efforts! :+1:

jgresham commented 5 months ago

@codebytere sorry for mention, but I can't get a reply from other devs. Could we get an arm64 fpm binary included in the releases on this repo?

I believe I have an arm64 executable for fpm https://github.com/jgresham/fpm-arm-binary along with a shell scrip to generate the binary. Compiles fpm v1.15.1

cc @mmaietta @mkurz @develar