http://ffmpeg.org/pipermail/ffmpeg-deve ... 40328.html
seems to talk about moving compilation of some CUDA related items to another mechanism, eg some filters.
andcompiling cuda kernels to the ptx format does not
introduce any non-free dependencies - the ptx files are an intermediate
assembly code format that is actually compiled to binary form at
runtime. With that understood, we just need to switch the remaining
users of the CUDA SDK to ffnvcodec and we will remove the non-free
entanglements from cuda.
So, for those of us that cross-compile ffmpeg but do not (yet) understand what is additionally needed to "cross compile" these filters, egThe use of nvcc to compile cuda kernels is distinct from the use of
cuda sdk libraries and linking against those libraries. We have
previously not bothered to distinguish these two cases because all
the filters that used cuda kernels also used the sdk. In the following
changes, I'm going to remove the sdk dependency from those filters,
but we need a way to ensure that nvcc is present and functioning, and
also a way to explicitly disable its use so that the filters are not
Note that, unlike the cuda_sdk dependency, using nvcc to compile
a kernel does not cause a build to become non-free. Although nvcc
is distributed with the cuda sdk, and is EULA encumbered, the
compilation process we use does not introduce any EULA covered
code or libraries into the build. In this sense, using nvcc is just
like using any other proprietary compiler like msvc - compiling free
code doesn't suddently make it non-free.
There was previously some confusion on this topic, but the important
distinction is that we use nvcc to generate ptx files - these are
not compiled GPU binaries, but rather an intermediate assembly
representation that is JIT compiled (and I think linked with certain
nvidia library code) when you actually try and run the kernel. nvidia
use this technique to relax machine code compatibility between
>From here, we can make two observations:
* The ptx files that we include in libavfilter are aggregated rather
than linked, from the perspective of the (L)GPL
* No proprietary code is included with the ptx files. That code is
only linked in at the final compilation step at runtime.
Does anyone know if it is possible to cross-compile the updated filters by somehow adding nvcc erg under ubuntu ?we need a way to ensure that nvcc is present and functioning
And, if one would be so kind, how ?
And, I hope finally, what if any files need to be copied before or during or after cross-compilation ?