Skip to content

build: Repo-root include paths in groups, precompiled headers and implementation files - #1208

Merged
zackees merged 1 commit into
masterfrom
build/repo-root-includes
Oct 17, 2026
Merged

zackees merged 1 commit into
masterfrom
build/repo-root-includes

Conversation

@zackees

@zackees zackees commented Oct 17, 2026

Copy link
Copy Markdown
Member

This switches every BUILD.md file to repo-root include paths. That covers groups, precompiled headers, implementation files and forwarding files: 486 files, includes only.

Before and after:

#include "../obs-ffmpeg-formats.h"          ->  #include "plugins/obs-ffmpeg/obs-ffmpeg-formats.h"
#include "build/obs-ffmpeg.pch.h"           ->  #include "plugins/obs-ffmpeg/build/obs-ffmpeg.pch.h"

Other changes:

  • cmake/common/groups.cmake makes the repo root an include directory of every target, and reads group files against it.
  • ci/test_build_groups.py has a new check that fails any include written relative to its file. A planted relative include confirmed it catches one.
  • BUILD.md states the rule.
  • validate.sh, the platform ratchet's no-op check and the C oracle's include directories use the new form.

Verification:

  • ./lint passes.
  • The full Linux build has 0 failed edges.
  • ctest: all 277 C tests pass except three that also fail without this change:
    • test_ws_batch_order fails because of my stale local obs-websocket checkout;
    • test_deinterlace_2x_field_order fails only under parallel load and passes alone;
    • test_x11_hotkey_layout depends on the desktop keyboard layout and passes under Xvfb.
  • soldr cargo test -p obs-c-oracle -p obs-nvenc -p obs-util passes.
  • cmake/cross/docker.sh mac-arm64 win-x64 passes.

…lementation files

Every quoted include of a repo file in a unity group, a precompiled header,
an implementation file or a forwarding file is now a repo-root path
("plugins/obs-ffmpeg/build/obs-ffmpeg.pch.h") instead of one relative to
the file ("../obs-ffmpeg-formats.h", "build/obs-ffmpeg.pch.h").
cmake/common/groups.cmake makes the repo root an include directory of every
target and reads group files against it; ci/test_build_groups.py fails a
relative include; BUILD.md describes the rule. validate.sh, the platform
ratchet's no-op check and the C oracle's include directories follow.
@zackees
zackees merged commit 36b9cea into master Oct 17, 2026
zackees added a commit that referenced this pull request Oct 17, 2026
…builds (#1214)

The x64/x86 helper builds of an ARM64 or x64 Windows build configure only
libobs and win-capture's/win-dshow's helpers and never load groups.cmake, so
after #1208 graphics-hook couldn't open shared/ipc-util/build/
ipc-util-windows.pch.h (C1083). The top-level CMakeLists.txt now adds the
repo root right after project(), before that branch.
zackees added a commit that referenced this pull request Oct 17, 2026
#1208 made unity-group includes repo-root paths ("libobs/util/foo.c.h"),
but validate.sh still matched "../foo.c.h", derived 0 ported objects and
failed every Tier 2 Linux run since. Match the new form (46 objects).
@zackees
zackees deleted the build/repo-root-includes branch October 26, 2026 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant