From bbc6d2e1e4f06c7a799e89319975c46ddfdfd28d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Sun, 25 Oct 2026 22:09:25 +0100 Subject: [PATCH] CMake: Put the bundled FFmpeg's headers first on the include path On macOS a newer FFmpeg's headers (Homebrew's) came first through another library's include directory, and AVIDump.cpp failed to build against them. Co-Authored-By: Claude Opus 5.5 (1M context) --- CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2d7952afea..f5e95a3b1a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -224,6 +224,9 @@ endif() # FFMPEG_DIR is asked for. if(USE_FFMPEG AND NOT USE_SYSTEM_FFMPEG AND NOT FFMPEG_DIR) set(BUILD_BUNDLED_FFMPEG ON) + # First on the include path, ahead of any other FFmpeg's headers that come along with another + # library's include directory (Homebrew's, for one). + include_directories(BEFORE ext/ffmpeg) else() set(BUILD_BUNDLED_FFMPEG OFF) endif()