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

LibMPV DLL with LGPL license #586

Open
Dingo64 opened this issue Jan 4, 2024 · 13 comments
Open

LibMPV DLL with LGPL license #586

Dingo64 opened this issue Jan 4, 2024 · 13 comments

Comments

@Dingo64
Copy link

Dingo64 commented Jan 4, 2024

Can you make a DLL for Windows compiled with -Dgpl=false so it is LGPL and not GPL?

@zhongfly
Copy link
Contributor

zhongfly commented Jan 4, 2024

I'm full of questions about compatibility between licences, does lgpl mean no gpl dependencies?

I find someone said need to disable gpl dependencies like libx264 #12 (comment)
I have download lgpl ffmpeg from https://github.com/BtbN/FFmpeg-Builds, and find it still have libx264 encoder.But libx264 is GNU General Public License v2.0 or later

@Dingo64
Copy link
Author

Dingo64 commented Jan 4, 2024

But does it have --enable-libopenh264? Support for h264 is quite important nowadays

@zhongfly
Copy link
Contributor

zhongfly commented Jan 4, 2024

I have find https://www.gnu.org/licenses/gpl-faq.html#AllCompatibility
Lgpl means no gpl dependencies.

It looks like this is very cumbersome needing to check all dependencies and disable them, which sometimes means having to find other lgpl packages to replace them or lose the ability to decode some formats.

@Dingo64
Copy link
Author

Dingo64 commented Jan 4, 2024

Seems ffmpeg compiled without gpl code supports pretty much everything. It doesn't have x264 but have other h264 decoders. And the list what should be disabled is already made:
#12

@zhongfly
Copy link
Contributor

zhongfly commented Jan 4, 2024

Seems ffmpeg compiled without gpl code supports pretty much everything. It doesn't have x264 but have other h264 decoders. And the list what should be disabled is already made: #12

I'm talking about this repo.For example,this repo only have x264.cmake (this).So if you want lgpl, you need disable x264 and create cmake files for other h264 encoders by yourself if ffmpeg need external libs to encode h264.

@zhongfly
Copy link
Contributor

zhongfly commented Jan 5, 2024

Made a patch to remove following packages incompatible with lgpl and set (lib)mpv as lgpl license:
rubberband xvidcore x264 x265 libdvdcss libdvdread libdvdnav avisynth-headers libssh libsrt davs2 openal-soft
https://gist.github.com/zhongfly/3b8335ebc0db52f061bec4692fd3efa0

Note:ffmpeg is LGPL3 and (lib)mpv is LGPL2.1+

@Dingo64
Copy link
Author

Dingo64 commented Jan 5, 2024

@zhongfly
Sounds great, thanks! Will there be a LGPL DLL in your repo?

@hooke007
Copy link
Contributor

hooke007 commented Jan 6, 2024

Seems ffmpeg compiled without gpl code supports pretty much everything. It doesn't have x264 but have other h264 decoders.

No one use x264 as a decoder.

@zhongfly
Copy link
Contributor

zhongfly commented Jan 6, 2024

Will there be a LGPL DLL in your repo?

The next daily build will have libmpv under the LGPL licence, but I can't guarantee that I've disabled all LGPL-incompatible packages, use at your own risk.
You can find out which packages are disabled in this patch.

update: https://github.com/zhongfly/mpv-winbuild/releases provides LGPL libmpv now

@hooke007
Copy link
Contributor

hooke007 commented Jan 6, 2024

@zhongfly
Copy link
Contributor

zhongfly commented Jan 6, 2024

https://github.com/zhongfly/mpv-winbuild/blob/84fdcd005745fea86da4b1a1475f4996dff9a9ee/compile-lgpl-libmpv.patch#L60

Are you sure it's compatible with lgpl2.1 of mpv?

https://www.gnu.org/licenses/gpl-faq.en.html#AllCompatibility
When libmpv is LGPLv2.1+,it can use a library under LGPLv3.

@Dingo64
Copy link
Author

Dingo64 commented Jan 6, 2024

@zhongfly Thank you very much. This DLL is great thing for all non-C programmers.

@adlerzei
Copy link
Contributor

@zhongfly you're a hero, many thanks.

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

4 participants