From: softworkz <softwo...@hotmail.com> This applies the same change for libavfilter as commit e743e7ae6ee7e535c4394bec6fe6650d2b0dbf65 did for the other libraries.
Original commit message: Add one copy of the function into each of the libraries, similarly to what we do for log2_tab. When using static libs, only one copy of the file_open.o object file gets included, while when using shared libraries, each of them get a copy of its own. This fixes DLL builds with a statically linked C runtime, where each DLL effectively has got its own instance of the C runtime, where file descriptors can't be shared across runtimes. On systems not using msvcrt, the function is not duplicated. Based-on-patch-by: Martin Storsjö <mar...@martin.st> Signed-off-by: softworkz <softwo...@hotmail.com> --- libavfilter/Makefile | 1 + libavfilter/file_open.c | 1 + 2 files changed, 2 insertions(+) create mode 100644 libavfilter/file_open.c diff --git a/libavfilter/Makefile b/libavfilter/Makefile index ee2ea51e69..78ccfa37d3 100644 --- a/libavfilter/Makefile +++ b/libavfilter/Makefile @@ -23,6 +23,7 @@ OBJS = allfilters.o \ version.o \ video.o \ +OBJS-$(HAVE_LIBC_MSVCRT) += file_open.o OBJS-$(HAVE_THREADS) += pthread.o # subsystems diff --git a/libavfilter/file_open.c b/libavfilter/file_open.c new file mode 100644 index 0000000000..494a5d37a4 --- /dev/null +++ b/libavfilter/file_open.c @@ -0,0 +1 @@ +#include "libavutil/file_open.c" -- ffmpeg-codebot _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".