Skip to content

Don't impose example-only conan deps (opengl/cimg/spdlog) on consumers - #253

Merged
garyo merged 1 commit into
mainfrom
conan/gate-example-deps
Jul 22, 2026
Merged

Don't impose example-only conan deps (opengl/cimg/spdlog) on consumers#253
garyo merged 1 commit into
mainfrom
conan/gate-example-deps

Conversation

@garyo

@garyo garyo commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

Follow-up to #246 / #238. The in-repo conan recipe required opengl, cimg, and spdlog for everyone and attached them to the HostSupport/Support components — but those are used only by the example plugins. Verified: no source file or packaged header outside Examples/ and Support/Plugins/*.cpp references them.

  • Consumers of the libraries now depend on expat only, matching the ConanCenter recipe's dependency set (this lets CCI drop the requirements half of its disable-example-requirements patch at the next release).
  • New build_examples option (default False) gates the extra requirements and drives BUILD_EXAMPLE_PLUGINS via the toolchain.
  • The top-level find_package(opengl_system/cimg/spdlog) calls are gated on BUILD_EXAMPLE_PLUGINS, so a library-only CMake build no longer needs them.
  • CI passes -o build_examples=True so all examples still build and run in CI.

Tested locally (macOS, apple-clang 21): conan create both with and without build_examples; the default package contains only headers + libs and its consumer graph shows just expat/2.7.1, while the examples variant builds all .ofx plugins and pulls cimg/spdlog/opengl as before.

🤖 Generated with Claude Code

The conan recipe unconditionally required opengl, cimg, and spdlog and
attached them to the HostSupport/Support components, but those packages
are used only by the example plugins — nothing in the libraries or
packaged headers references them. Consumers of the libraries now pull
in just expat, matching the trimmed dependency set the ConanCenter
recipe already uses.

Example builds move behind a new build_examples option (default False)
which drives BUILD_EXAMPLE_PLUGINS and the extra requirements; CI passes
-o build_examples=True to keep building and testing the examples. The
top-level find_package calls for the example deps are likewise gated on
BUILD_EXAMPLE_PLUGINS so a library-only CMake build doesn't need them.

Refs #238.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Signed-off-by: Gary Oberbrunner <garyo@darkstarsystems.com>
@garyo
garyo merged commit 8467f40 into main Jul 22, 2026
11 checks passed
@garyo
garyo deleted the conan/gate-example-deps branch July 22, 2026 12:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant