packager: Packaging darwin build on Windows results in blocked folder (access denied)
Hi there, I’ve just started using the packager, and it works pretty well. Thanks for the great work and the efforts here 😃
I just have a problem with building for Mac on Windows. I use this line of code:
D:\work\www\droplet>electron-packager ./ Droplet --platform=darwin --arch=x64 -- version=0.33.9 --out=build
And the build was successful:
Packaging app for platform darwin x64 using electron v0.33.9
Wrote new app to build\Droplet-darwin-x64
But here comes the problem - I cannot archive or copy this build. When archiving with WinRAR, I get the following error:
! D:\work\www\droplet\build\Droplet-darwin-x64.rar: Cannot open D:\work\www\droplet\build\Droplet-darwin-x64\Droplet.app\Contents\Frameworks\Electron Framework.framework\Libraries
Access is denied.
! D:\work\www\droplet\build\Droplet-darwin-x64.rar: Cannot open D:\work\www\droplet\build\Droplet-darwin-x64\Droplet.app\Contents\Frameworks\Electron Framework.framework\Resources
Access is denied.
Followed by a 5 seconds wait time, and another like 10 errors for maybe all things in Frameworks folder.
I’ve managed to copy it through cmd, using xcopy, BUT the build was 50% larger (don’t know why), and does not run on Mac: The application “Droplet.app” can’t be opened.
Do you have any ideas why this happens? Using Windows builds (on any arch) works like a charm! Any ideas will be appreciated!
About this issue
- Original URL
- State: open
- Created 11 years ago
- Reactions: 10
- Comments: 45 (17 by maintainers)
For me, I just fix the problem by compressing it to a 7Zip archive (.7zip) and then uncompress it somewhere else. Note that compressing in a zip archive (.zip) with 7zip doesn’t work (same access problem).
I haven’t found a solution, but I’ve found a way to make my life a bit easier: Build a package using Mac. For your next releases you can use WinRAR or similar to update the source/asar.
@Bobavince I can’t believe that actually works. Thank you.
My point was that there are a lot of cross-operating-system packaging bugs, so my default stance is to suggest to people that they don’t use it unless they can’t build on multiple OSes, and they’re willing to deal with bugs such as this one, because I can’t debug them and no one in the community with this problem has gone into a deep dive to figure out the root cause. (I do appreciate it a lot when community members do this, for example what has transpired in the past week regarding #544.)