Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cache/electron-builder/appimage/appimage-9.1.0/runtime-armv7l: no such file or directory #20

Closed
dj-at-work opened this issue Nov 17, 2018 · 11 comments

Comments

@dj-at-work
Copy link

dj-at-work commented Nov 17, 2018

I'm building an electron on a Raspberry Pi. On my old Raspberry Pi 3 everything works fine, but now on my new Raspberry Pi 3 b+ it shows the following error:

open /home/pi/.cache/electron-builder/appimage/appimage-9.1.0/runtime-armv7l: no such file or directory

The appimage-9.1.0 directory is empty on the new Pi, while on my old Pi the directory contains the expected app images.

Shouldn't Electron Builder take care to download the images?

@develar
Copy link
Member

develar commented Nov 17, 2018

Hmmm.... try to delete cache dir and build again. What electron-builder version do you use? If still no such file, download it from https://github.com/electron-userland/electron-builder-binaries/blob/master/AppImage/runtime-armv7l

@dj-at-work
Copy link
Author

dj-at-work commented Nov 17, 2018

Hi @develar thank you for your prompt reply!

I'm using electron-builder version 20.36.1

I had already run into the problem "AppImage/armv7l mksquashfs? #14" before and therefore created the folder (.cache/electron-builder/appimage/appimage-9.1.0/...) manually and set a link to mksquashfs.

The existence of the folder/path seems to prevent Electron Builder from downloading the images. After I deleted the cache folder, all images were downloaded again.

However, my build aborted again with the error message:

error: fork/exec /home/pi/.cache/electron-builder/appimage/appimage-9.1.0/linux-arm/mksquashfs: no such file or directory

After I had set the link to mksquashfs again, the project could be built again completely.

All in all a somewhat unpleasant situation. It would be better if Electron Builder would check if images actually exist and download them in case of doubt.

@develar
Copy link
Member

develar commented Nov 17, 2018

  1. Why do you need AppImage for ARM? I want to know because I work for interest.
  2. "the project could be built again completely." How could it be possible ... OUCH... OMG... we do provide for ARM — https://github.com/electron-userland/electron-builder-binaries/blob/master/AppImage/linux-arm64/mksquashfs but path is not correct.
  3. How do I can emulate your ARM arch on macOS to verify fix?

@develar
Copy link
Member

develar commented Nov 17, 2018

armv7l it is 64bit? It seems https://github.com/electron-userland/electron-builder-binaries/tree/master/AppImage/linux-arm64 working for you or did you use another file?

@develar
Copy link
Member

develar commented Nov 17, 2018

BTW, if your project doesn't have native node modules, you can build AppImage for arm on your dev machine.

@dj-at-work
Copy link
Author

dj-at-work commented Nov 18, 2018

@develar

  1. Why do you need AppImage for ARM? I want to know because I work for interest.

I'm developing an app that runs on different types of systems, including Rasperry Pi, which is based on ARM.

  1. "the project could be built again completely." How could it be possible ... OUCH... OMG... we do provide for ARM — https://github.com/electron-userland/electron-builder-binaries/blob/master/AppImage/linux-arm64/mksquashfs but path is not correct.

:o)

  1. How do I can emulate your ARM arch on macOS to verify fix?

You can't without an ARM (afaik). Let me know if I can support you.

armv7l it is 64bit? It seems https://github.com/electron-userland/electron-builder-binaries/tree/master/AppImage/linux-arm64 working for you or did you use another file?

Yes and no. The ARM itself supports 64bit, but the operating system does not. Which makes sense if you consider the limited resources of a Raspberry Pi 3b+ (1 GB RAM).

BTW, if your project doesn't have native node modules, you can build AppImage for arm on your dev machine.

Thanks for the tip, but unfortunately it has... ¯\_(ツ)_/¯

@develar
Copy link
Member

develar commented Nov 19, 2018

Is mksquashfs from arm-64 works for you or do use another file?

@dj-at-work
Copy link
Author

dj-at-work commented Nov 23, 2018

@develar
Sorry for my delayed response. Due to the operating system, I have to use the 32bit version. And I have to rebuild the latest version to run a version that offers support of the offset option (as mentioned here by @hirokiht)

    cd /usr/src
    git clone https://git.kernel.org/pub/scm/fs/squashfs/squashfs-tools.git
    
    cd mksquashfs/squashfs-tools/squashfs-tools 

    sudo make install 

Afterwards I have to create the linux-arm folder and add the link to mksquashfs:

    mkdir -p  ~/.cache/electron-builder/appimage/appimage-9.1.0/linux-arm
    cd ~/.cache/electron-builder/appimage/appimage-9.1.0/linux-arm
    ln -s /usr/local/bin/mksquashfs mksquashfs  

@noisymime
Copy link

noisymime commented Jul 9, 2019

For anyone coming across this and trying to build squashfs-tools on a recent OS version, glibc version 2.28 moves a number of macros out of <sys/types.h> and in to <sys/sysmacros.h>. Therefore the version of squashfs-tools on git (https://git.kernel.org/pub/scm/fs/squashfs/squashfs-tools) will not compile out of the box with glibc 2.28 or above.

The fix is relatively straightforward, you simply need to add #include <sys/sysmacros.h> into the mksquashfs.c and unsquashfs.c files and the compile will work.

I've also attached a 32-bit ARM binary of mksquashfs in case it helps anyone. Even better would be if this binary can be included by default rather than only the arm64 binary being supplied.
mksquashfs.zip

@develar
Copy link
Member

develar commented Jul 9, 2019

@noisymime Thanks, I included your binary.

@hesparza
Copy link

Thanks, this is very useful information, worked for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants