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

Pack opencv_ffmpeg310.dll #6

Closed
techtonik opened this issue Jul 16, 2016 · 12 comments
Closed

Pack opencv_ffmpeg310.dll #6

techtonik opened this issue Jul 16, 2016 · 12 comments

Comments

@techtonik
Copy link
Contributor

Build process downloads ffmpeg .dll, but fails to pack it into resulting wheel.

opencv/opencv#6803

@skvark
Copy link
Member

skvark commented Jul 16, 2016

If there's no licensing related issues, it can be added to the wheel.

@techtonik
Copy link
Contributor Author

I am not aware of any. Sources are available, so all GPL requirements are met.

@virtuald
Copy link

virtuald commented Sep 5, 2016

If it's GPL, that would be a problem for non-GPL projects if they didn't realize what they were using (as OpenCV is not GPL, so they normally wouldn't need to worry about that).

@skvark
Copy link
Member

skvark commented Sep 5, 2016

I'm going to leave this issue open for now. I'm not a lawyer so I'm not sure what consequences there are if the GPL licensed ffmpeg binary is distributed within this package.

@techtonik
Copy link
Contributor Author

@takluyver
Copy link

I'm not a lawyer either, but my understanding is that it would be OK to distribute a GPL component with OpenCV, but the whole package would then fall under the GPL, along with anything that uses it.

However, FFmpeg itself is LGPL, with optional GPL parts. If it is compiled without the --enable-gpl flag, the GPL should not apply, so it should be sufficient to include an appropriate copyright notice for FFmpeg and a copy of the LGPL document.

https://ffmpeg.org/legal.html

@skvark
Copy link
Member

skvark commented Sep 20, 2016

I think you are correct. On Windows this is easy to fix because the FFmpeg dlls are precompiled as LGPL (https://github.com/opencv/opencv/tree/master/3rdparty/ffmpeg) and can be easily copied to the wheel package during build. I guess that on OS X the situation is probably similar to Windows. On Linux it gets more complicated since FFmpeg has to be compiled separately as LGPL on the manylinux containers. However, it should not be a problem but requires some work.

I'll start working on this FFmpeg issue. Contributions are more than welcome. In the meantime, non-video features of the opencv-python wheels should work just fine.

techtonik added a commit to techtonik/opencv-python that referenced this issue Sep 21, 2016
This attempts to copy all .dll files in build directory,
where should be only ffmpeg .dll
@skvark skvark closed this as completed in 68fc11e Sep 24, 2016
@takluyver
Copy link

Thanks @techtonik and @skvark for the fix! Any chance of a new release on PyPI? @cachitas is making an example of bundling it into a windows installer (takluyver/pynsist#79), which should work neatly once the new wheel is available.

@skvark
Copy link
Member

skvark commented Sep 28, 2016

I can make the release. However, OS X / Linux builds are still missing ffmpeg support since it's a bit more complicated to enable it on them (especially on Linux due to the Cent OS 5 manylinux containers).

@takluyver
Copy link

For our example, it's only the Windows build that is necessary, so if it's easy to do a release, I wouldn't wait for a solution for the other platforms.

I've managed to get pygame plus its dependencies built and bundled in a manylinux container, though there were no license concerns to watch out for there. It was mostly a matter of compiling new versions of the dependencies from source to avoid the ancient versions available in CentOS 5's repos. http://www.pkgsrc.org/ might help there; I didn't know about it at the time.

@skvark
Copy link
Member

skvark commented Sep 28, 2016

Good to know. I'll make now the release.

@takluyver
Copy link

Thanks, I see it's up. :-)

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