How does one comply with the GPL and LGPL with Wasm, other than a complete source dump?
How does one comply with the GPL and LGPL with Wasm, other than a complete source dump?
You may want to check with a lawyer, and/or read the ffmpeg FAQ about that, and/or recompile with --disable-gpl --disable-nonfree - and that only brings you to the point where you need to let people use their own ffmpeg.wasm (and not be obligated to provide your source code).
https://www.ffmpeg.org/legal.html is actually required reading for anyone who uses ffmpeg in a product, commercial, free/libre or free/gratis.
I have an acquaintance who's a lawyer specializing in these issues, and he's usually called in to put out (legal) fires because people ignored open source licenses in commercial products. Copyright infringement laws are crazy complicated and in many ways incompatible with the modern ways of software, but they are what they are, and must be considered.
Since you are distributing ffmpeg (as a wasm module), you are under obligations to give access to source code that do not apply to services that merely use ffmpeg within their own organization (even if for a service provided to third parties).
One typical work around for distribution of ffmpeg in a product is to simply use a standalone ffmpeg executable and provide all the source to the ffmpeg executable.
A wasm module is more akin to a library than a standalone executable and likely under stronger obligations. If you are only using LGPL code (it depends on how you compiled ffmpeg [See https://www.ffmpeg.org/legal.html -- "Compile FFmpeg without "--enable-gpl" and without "--enable-nonfree" ), giving access to only the ffmpeg code you used to build the module (and any modifications) would likely suffice for the source code obligation. If you are including any GPL code (because you didn't compile with the options needed to ensure only LGPL code is used), your entire project likely falls under GPL and you would probably need to share the source for the entire project to be compliant.
If another service is using ffmpeg as a wasm without providing a means of accessing the source code (to the wasm module if only using LGPL code, or the entire project if using any GPL code), they (too) are likely in violation of the ffmpeg license copyright and could be sued. Companies and projects can fly under the radar for some time before this happens, but it doesn't mean they are operating legally and will never be sued.
There are claims both for and against this being a derivative work; for “standalone” use, the test is usually something like “if you didn’t use ffmpeg, would the product be significantly less useful?”
MySQL used to claim that including MySQL.exe in a product, even if you don’t link to it, makes that product a derivative work. The generally accepted wisdom is that it’s not.
I don’t know if this was ever tested in court.