-
Notifications
You must be signed in to change notification settings - Fork 43
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
Detected file that's the same in both x64 and arm64 builds #51
Comments
I have the same problem with 7zip-bin, which is pulled in by electron-updater. The simple fix in @electron/universal would be to detect if the two files are identical (e.g., sha check) prior to calling lipo, and if they are, just copy the first file. I don't think there is any work around for this just now. (Updated: the copy in fact happens, all that's require is to catch the lipo error, check error.stderr for 'have the same architecture', rethrow if not present). |
Any resolution for this issue? I am using electron forge. |
Same issue appears to happen when building a universal app that uses
|
I'm also getting the fsevents file detected as duplicate when including chokidar. Any direction on how to resolve this? |
This comment was marked as off-topic.
This comment was marked as off-topic.
@navdeepm20 I hid your comment as it is incorrect and will result in folks having broken apps. The issue here folks is that you are packaged a "universal" app but the In some cases (like in the original issue's case) this is expected behavior and requires you to allowlist the file as the path In the |
I think moving |
Hello @MarshallOfSound how do we tell to build for each architecture? I created yesterday the issue #76 and I believe it is more or less the same problem. In my case drivelist seems to be built for x86 and I have arm64. So how should I tell electron/universal to build for x86 and arm64? Thank you in advance and regards |
@MarshallOfSound I don't think that's what the problem is; fsevents.node is a universal binary so it's same for both x86 and arm64. lipo -create can't be called on universal binaries (no point), and if you do, it errors with 'the same architectures' error. It unhelfully only reports the first architecture in the universal binary, so it's not immediately obvious it is actually two identical universal binaries you are trying to combine. The fix for this would be to check if the file is a univeral binary (lipo -archs) before trying to combine it. |
Running universal via
electron-forge package --arch=universal
results in the following error message:An unhandled rejection has occurred inside Forge:
Error: Detected file "Contents/Resources/app/node_modules/lzma-native/prebuilds/darwin-arm64/electron.napi.node" that's the same in both x64 and arm64 builds and not covered by the x64ArchFiles rule: "undefined"
Any thoughts on how to handle this? Appreciate the help.
The text was updated successfully, but these errors were encountered: