Skip to content

ci(publish): build, pack and publish cvcgl-examples - #213

Merged
transfix merged 1 commit into
masterfrom
feat/publish-cvcgl-examples
Aug 21, 2026
Merged

transfix merged 1 commit into
masterfrom
feat/publish-cvcgl-examples

Conversation

@transfix

Copy link
Copy Markdown
Owner

Why

The cvcgl-examples recipe has been in the tree since #204, but publish-cvcpkg.yml never knew about it — the workflow only referenced libcvc, libcvc-cuda, cvcgl and the pycvc* recipes. So the example commands (lsystem_forest, the nav demos, and the cvcgl-examples-web launcher) were buildable but never reached the catalog, and a cvcpkg install cvcgl-examples could not work no matter how many times libcvc was republished.

What

  • compute-revisions: a cvcgl_examples output, so its revision comes from cvcpkg next-revision like every other package rather than being hand-maintained.
  • A linux release step next to the cvcgl one. Nothing links the examples, so unlike cvcgl (which every pycvc column rebuilds for linking) this runs only in the pyver-311 column.

It calls the recipe's build.sh rather than repeating its cmake

Every other step here inlines cmake, but duplicating this one would create two sources of truth for flags like the -DCGAL_Boost_USE_STATIC_LIBS=OFF workaround from #207 — and a recipe drifting from what CI actually runs is precisely how a recipe passes cvcpkg validate while being broken. build.sh takes its prefixes from a single CVC_DEPS_PREFIX, and CMAKE_PREFIX_PATH is a list, so the three prefixes this job spreads its deps across ($STAGE;$PY;$DEPS) go over as one semicolon-separated value.

Verified that mechanism rather than assuming it — a probe requiring both cvc and Boost, with the real prefix sandwiched between two nonexistent ones, resolves through the same quoting build.sh uses:

-- LISTPROBE OK: cvc + Boost resolved from a multi-prefix list

The nav-demo dependency resolves itself here

The nav demos need cvc::nav, which exists only in libcvc >= the nav kernels (#198) — newer than the published 3.2.4+cvc.12, which ships no cvc/nav/ headers and zero nav symbols. Building the examples against the published SDK fails at link:

undefined reference to `cvc::nav::sim_thread::read() const'

That is a non-issue in this workflow because the job builds and installs libcvc from this tree into $STAGE before this step runs. Worth knowing for any other route: publishing the examples from elsewhere requires a libcvc republish first.

Not wired up: the wasm entry

The recipe also has a platform: wasm entry (the browser build under share/cvcgl-examples/web/). Publishing it needs emsdk, the wasm dependency closure, and a rendering-enabled wasm vtk on the catalog (libcvc-deps#517 is merged but not yet published). Deliberately left as a TODO in the step rather than added speculatively.

Checks

YAML parses; the step mirrors the cvcgl step's guards, DO_PUBLISH handling and dry-run behaviour. Note dry_run defaults to 'true' on manual dispatch, so a first run will pack without publishing — which is a reasonable way to smoke-test this before a real publish.

The cvcgl-examples recipe has been in the tree since #204 but was never
wired into publish-cvcpkg.yml, so the example commands never reached the
catalog: the workflow only knew about libcvc, libcvc-cuda, cvcgl and the
pycvc columns.

Add a linux release step alongside cvcgl, plus a cvcgl_examples output on
compute-revisions so the revision is chosen the same way as every other
package (`cvcpkg next-revision`).  Nothing links the examples, so unlike
cvcgl this runs only in the pyver-311 column rather than in every column.

The step invokes the recipe's own build.sh instead of repeating its cmake
in YAML.  Duplicating it would leave two sources of truth for flags like
the -DCGAL_Boost_USE_STATIC_LIBS=OFF workaround (#207) -- and a recipe
drifting from what CI actually runs is exactly how one passes `cvcpkg
validate` while being broken.  build.sh takes its prefixes from a single
CVC_DEPS_PREFIX, and CMAKE_PREFIX_PATH is a list, so the three prefixes
this job spreads its dependencies across are handed over as one
semicolon-separated value (verified: cvc + Boost both resolve from a
multi-prefix list passed through build.sh's quoting).

The nav demos need cvc::nav, which exists only in libcvc >= the nav
kernels (#198) -- newer than the published bundle.  That resolves itself
here because the job builds and installs libcvc from this tree into
$STAGE before this step runs; publishing the examples from anywhere else
needs a libcvc republish first.

The recipe's `platform: wasm` entry (the browser build under
share/cvcgl-examples/web/) is deliberately NOT wired up: it needs emsdk,
the wasm dependency closure, and a rendering-enabled wasm vtk on the
catalog.  Left as a TODO in the step.
@transfix
transfix merged commit bbd80e1 into master Aug 21, 2026
12 checks passed
@transfix
transfix deleted the feat/publish-cvcgl-examples branch August 21, 2026 23:04
transfix added a commit that referenced this pull request Sep 2, 2026
…cgl-examples (#312)

ImGuiOverlay's whole point is that "without CVC_ENABLE_IMGUI the whole class
compiles to inert stubs, so consumers never need an #ifdef" (its own file header).
Of the 15 methods the header declares, 14 had a stub. attachCamera did not.

The three nav demos take the class at its word and call it unguarded, so
nav_city_swarm, nav_fog_ghost and nav_finale all failed to link with

    undefined reference to
      cvc::gl::ImGuiOverlay::attachCamera(cvc::gl::CameraController&)

in the one configuration anybody builds without imgui: the cvcgl-examples publish
lane, where nothing installs imgui and src/cvcGL/CMakeLists.txt silently settles
on CVC_ENABLE_IMGUI OFF. lsystem_forest, lsystem_coast and bunny_shadow link
there because they wrap their overlay blocks in #ifdef — which is the noise this
class exists to remove.

Not a regression: the publish step that builds these demos landed in #213 about
three hours AFTER the last publish run, so the v3.3.0 tag was the first time it
ever executed, and it failed on first contact. The unguarded calls arrived
separately, in cb5dee0 and #215, and CI had never built them imgui-less.

Fixing the stub rather than the three call sites keeps the contract the header
advertises, so the next consumer — volrover3, pycvc_gl, a new demo — cannot trip
the same wire. With no imgui there is no input to hand off, so the camera never
needs telling about it and an empty body is the right behaviour.

Verified by compiling the TU exactly as that lane does (no CVC_ENABLE_IMGUI):
the symbol goes from 0 definitions on master to 1 here, matching the mangled
name in the link error. Audited the rest of the block at the same time — all 15
declared methods now have stubs.

Follow-up worth doing separately: the published demos currently ship with no UI
at all, since imgui is simply absent from the cvcgl-examples closure. imgui
1.92.9+cvc.1 is on the catalog for linux, but adding it needs care — cvcGL links
imgui by ABSOLUTE find_library path and exports that target, so letting the imgui
prefix reach the earlier cvcgl step would bake a builder path into the published
SDK (the trap the X11 comment in that CMakeLists documents).
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