From 2d368392a5d6b856d63959ae8bfd40dd598c27e7 Mon Sep 17 00:00:00 2001 From: Martin Storsjö Date: Fri, 18 Mar 2022 10:13:27 +0200 Subject: Keep including the full version.h when headers are included externally MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This avoids unnecessary churn and build breakage for users, by making sure the whole version.h is included like it has been so far, while keeping the benefit of not needing to rebuild most files in the ffmpeg tree on minor/micro bumps. Signed-off-by: Martin Storsjö --- libavformat/avformat.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'libavformat') diff --git a/libavformat/avformat.h b/libavformat/avformat.h index 03df76af92..f12fa7d904 100644 --- a/libavformat/avformat.h +++ b/libavformat/avformat.h @@ -320,6 +320,12 @@ #include "avio.h" #include "libavformat/version_major.h" +#ifndef HAVE_AV_CONFIG_H +/* When included as part of the ffmpeg build, only include the major version + * to avoid unnecessary rebuilds. When included externally, keep including + * the full version information. */ +#include "libavformat/version.h" +#endif struct AVFormatContext; struct AVStream; -- cgit v1.2.3