Open yuyichao opened 2 years ago
The executable is created by https://www.electron.build/, so this is probably a default from them. Does this only happen with the Linux builds, or with the Mac builds also? I wouldn't recommend running the aarch64
builds on Mac, as they're created specifically for Fedora/Arch/Manjaro -- there are dedicated builds available for Mac.
I don't know how to check it for the Mac build (I assume it's fine) since I'm not under macOS right now. This is on apple hardware but I'm not using the linux build on macOS. I'm running the archlinux build on archlinux running on m1.
Although it is worth noting that pre-19 electron doesn't really support non-4k pages on aarch64 due to chromium issue. Have anyone tested running notion with electron 19? If not, I might also have to do more patching/compile an electron 11 with backport ...
Gotcha, that makes sense. Over the coming months Notion and the notion-enhancer will hopefully be updating to newer versions of Electron, but for the time being, we are limited by the version the Notion app is built with.
While I was updating the wiki page for software that needs to be fixed, I just noticed that there is already a paragraph describing exactly this https://github.com/AsahiLinux/docs/wiki/Broken-Software#why-does-not-work-sometimes-mean-instantly-segfault and it mentioned that chrome/electron does apply non-default build flags that is causing the problem.
(Note that I'm not 100% sure if it's on the repackager or notion upstream since I don't know who created the executable file.)
What is happening?
The executable in the archlinux package (both the vanilla and enhanced version) for aarch64 has a load alignment of 0x1000 (4k). This prevents the executable from being loaded on systems with a large page size (e.g. Apple M1)
What should be happening?
The alignment should be 64k, as is the default for latest binutils. The alignment can be seen using
readelf -l <executable>
and the alignment for allLOAD
program headers should be0x10000
instead of0x1000
.Screenshots (if applicable):
Operating system/browser name & version:
ArchLinux, AArch64 on Apple M1 (or any other systems with a page size larger than 4k).
notion-enhancer and/or notion-repackaged version: Both
notion-enhancer configuration (enabled/disabled mods and their settings): N/A