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

ffmpeg-static does not seem to rebuild if the binary already exists at ./ffmpeg #136

Open
busterbogheart opened this issue Jul 17, 2024 · 0 comments

Comments

@busterbogheart
Copy link

ffmpeg-static version

5.2.0

Node.js version

v18.20.3

operating system and/or environment

MacOS 11.3.1
@electron-forge
electron/universal

What happened?

We are using ffmpeg-static in a build process which creates a universal Mac build, and it passes arch values for both Intel and M1: x64 and arm64. In the finished app build we noticed there was only ever one arch of the ffmpeg binary created. Digging deeper we found that if a binary already exists at ffmpeg-static/ffmpeg, it will not be rebuilt:

npm rebuild --arch=x64 -f ffmpeg-static
file node_modules/ffmpeg-static/ffmpeg

displays correctly "Mach-O 64-bit executable x86_64"
rebuilding for another arch:

npm rebuild --arch=arm64 -f ffmpeg-static
file node_modules/ffmpeg-static/ffmpeg

still shows "Mach-O 64-bit executable x86_64"
but removing the binary and rebuilding

rm node_modules/ffmpeg-static/ffmpeg
npm rebuild --arch=arm64 -f ffmpeg-static
file node_modules/ffmpeg-static/ffmpeg

shows correctly "Mach-O 64-bit executable arm64"

mnvr added a commit to ente-io/ente that referenced this issue Aug 27, 2024
mnvr added a commit to ente-io/ente that referenced this issue Aug 27, 2024
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

1 participant