Resolve each dependency where it is linked, and prove plain CMake without ost - #230
Merged
Merged
Conversation
…hout ost The root CMakeLists.txt resolved all five usd-motion-plugins packages up front, so every configure required every package -- motionRecording included, which nothing here includes. Each member now resolves what it links through usdvrm_consume_package() (cmake/UsdVrmConsumedPackage.cmake), which promotes the targets it creates to IMPORTED_GLOBAL so a later member and a root-registered test reuse one definition. The root orchestrates and resolves nothing on a member's behalf. EDGES THAT WERE NEVER USED ARE GONE. execVrm linked, and its descriptor pinned, motionSampling and motionRecording since MIG-1 split motionRuntime, with no source including either. motion_retarget included motionCore/ headers through motionRetarget's link line and now links it by name. Measured: every member configures and builds standalone against a prefix holding only its own packages; usdVrmFileFormat, usdVrmPackageResolver, vrmSchema and vrmContainer need no motion package at all, and main's execVrm fails the same test on motionSampling. usdvrm_baseline asked whether motionCore's target was visible as a stand-in for "is this the root build", which would have silently unregistered the gate once the root stopped resolving packages. It asks USDVRM_COMPOSED_BUILD now. A CMAKE DEPENDENCY AUDIT, scripts/check_cmake_boundaries.py (workspace_cmake_boundaries + selftest): no source tree of another repository, no usd-motion-plugins identity built here, the root resolving nothing, each member's reachable packages within WORKSPACE.md section 2 (the VRM importer none; the .vrma importer neither vrmRig nor motionRetarget), resolved = linked = included per member, and descriptor = CMake. Given an installed motion include/ it also fails on code there that knows VRM. On main it reports 17 violations. A PLAIN-CMAKE LANE, .github/workflows/plain-cmake.yml: OpenUSD install + cmake --install of usd-motion-plugins -> cmake -> build -> ctest on Linux, refusing to run with ost on PATH. It copies no pin: scripts/plain_cmake_inputs.py fetches the Linux workspace cell's runtime archive and execVrm's execMotion bundle by digest, and builds usd-motion-plugins from the commit the pinned packages' SLSA provenance names. ITS FIRST RUN FOUND A DEFECT that ost's activation hid. The published libExecMotion.so carries the producer's CI checkout as its RUNPATH, so it opens only when LD_LIBRARY_PATH names OpenUSD; the suites only prepended PATH. Outside `ost test`, execVrm_diagnostics and workspace_exec_driver failed on Linux with the plugin never loaded. USDVRM_EXEC_MOTION_ENV (cmake/UsdVrmExecMotion.cmake) now carries the platform loader path, used by every suite that composes the bundle. Local: plain CMake 40/40 on Windows (VS 18, no ost) and 40/40 in an Ubuntu 24.04 container mirroring the workflow; `ost build` + `ost test` 40/40 on 0.23.6; graph valid, 13 library edges; package-consumer lane 3/3. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pxrConfig.cmake find_dependency's Python3 Development, and on the hosted runner FindPython3 looked for the headers and libpython under /usr instead of setup-python's interpreter, failing the usd-motion-plugins configure. The local container had one Python 3.13 and never saw it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The second hosted run failed where the first did, with Python3_EXECUTABLE passed: an OpenUSD install's CMake package names its build Python by absolute path. pxrConfig.cmake defaults Python3_LIBRARY/_INCLUDE_DIR to it, and pxrTargets.cmake bakes /usr/include/python3.13 into gf's, usd's and others' INTERFACE_INCLUDE_DIRECTORIES, which no Python3_* hint overrides -- the configure then fails at generate time. `ost` rewrites these paths when it materializes the runtime; the local container passed only because the builder image has that Python at those paths. So the lane installs deadsnakes' python3.13-dev on the runner instead of setup-python -- the Python the pinned runtime was built against, where it expects it, as someone who built OpenUSD on their own host has it. Measured in a clean ubuntu:24.04 container: 40/40. SUPPORTED_CONFIGURATIONS and the README state the constraint. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR makes plain CMake a proven build contract.
usd-motion-pluginsis consumed only as an installed package, each member declares exactly the packages it uses, and a CI lane with noostin it builds and tests the workspace.Dependency boundary
find_packageall five motion packages, so every configure required every package, includingmotionRecording, which nothing here includes. Each member now resolves what it links throughusdvrm_consume_package()(cmake/UsdVrmConsumedPackage.cmake). The function runsfind_packagein function scope, so pxrConfig's Python3 clobbering does not leak, and it promotes the targets it created toIMPORTED_GLOBAL, so later members and root tests reuse one definition.execVrmlinkedmotionSamplingandmotionRecording, and its descriptor pinned them, from MIG-1 on, but no source includes either.motion_retargetincludedmotionCore/headers without linkingmotionCore.motionRecordingis no longer consumed at all. The graph drops from 15 to 13 library edges.usdvrm_baselineasksUSDVRM_COMPOSED_BUILD. It used to ask whethermotionCore's target was visible, and once the root stopped resolving packages that test would have unregistered the gate silently.vrmContainer,vrmSchema,usdVrmFileFormat,usdVrmPackageResolvervrmRig,usdVrmaFileFormatmotionCoreexecVrmmotionCore,motionRetargetmotion_retargetmotionCore,motionRetarget,motionSampling,motionUsdEnforcement:
scripts/check_cmake_boundaries.pyThe script is static and needs no build. It is registered as
workspace_cmake_boundariesplus a self-test (18 cases). It fails on:add_subdirectoryleaving the repo,FetchContent, orExternalProjectusd-motion-pluginsidentity built hereforeachloop.vrmaimporter may reach neithervrmRignormotionRetarget.requires.librariesdisagrees with its CMakeinclude/: any code there that knows VRMRun against
main, it reports 17 violations.CI:
.github/workflows/plain-cmake.ymlThe lane runs OpenUSD install +
cmake --installof usd-motion-plugins →cmake→ build →ctestonubuntu-24.04, and fails ifostis onPATH. It copies no pin.scripts/plain_cmake_inputs.pysupplies the inputs:usd-motion-pluginsfrom the commit that the pinned packages' SLSA provenance names. It checks that every pin agrees on that commit, which today is v0.5.19256f93.execMotionfromexecVrm's pin.Fix found by the new lane
libExecMotion.soas published carries its producer's CI checkout as itsRUNPATH, so it opens only whenLD_LIBRARY_PATHnames OpenUSD.ost testsets that variable. The suites only prependedPATH, so on Linux outsideost,execVrm_diagnosticsandworkspace_exec_driverfailed with the plugin never loaded. The failure was bisected withLD_DEBUG, and a C++20 build and a build against the published motion libraries were both ruled out.USDVRM_EXEC_MOTION_ENVnow carries the platform's loader variable, and every suite that composes the bundle uses it. Theostside is filed as a P3 in report 48 (#229).Verification (local)
ost): 40/40main'sexecVrmfails that test onmotionSampling.ost build+ost test(0.23.6): 40/40.ost plugin test --workspace --graph-only: valid. Package-consumer lane: 3/3 PASS.check_docs.py: OKThe new lane itself only runs on this PR.
🤖 Generated with Claude Code