Local Development#
This page is the reference for building, testing, packaging and documenting ovclash from a source
checkout. Run every command on this page from ovclash/.
If you use a released package instead, start with the consumer pages: the Python package guide, the C/C++ Quickstart and Samples. Contributing describes how to propose a change and which validation each kind of change needs.
Building ovclash from a source checkout#
ovclash has its own CMake-script build system. Do not use the build commands of the other projects of this repository on it: the PhysX SDK, NVIDIA’s physics SDK, or Omni PhysX, the PhysX integration of Kit.
The engine sources are under source/usdclash/, and ovclash does not modify them. The explicit
inventory in scripts/usdclash_sources.cmake lists the compiled inputs.
Prerequisites#
A Windows x86-64 host, or a Linux x86-64 or aarch64 host.
Network access for the first build. It downloads the build dependencies, including CMake and Python, into
_build/deps/; see Dependency sources. No system CMake is needed.On Windows, a build from the public source needs the installed Visual Studio 2022, or its Build Tools with the x64 C++ tools, and a Windows SDK. “Public source builds” in the repository
README.mddescribes the toolchain selection. The wrappers use the packaged vswhere and Ninja.On Linux, a public source export builds on the host with the system’s GCC, and its output must meet the ELF baseline; see Wrapper flags.
Dependency sources#
The first build stages everything it needs below _build/deps/. Later builds reuse it.
Dependency |
Staged in |
Overrides |
|---|---|---|
The packages that |
|
|
The pinned wheel of ovstage, the runtime through which ovclash reads USD, version |
Downloaded with pip from pip’s configured package index into |
|
The pip packages of the Python test environments and of the wheel build environment |
|
pip’s own configuration selects the index. |
A public source build on Windows uses the installed Visual Studio 2022 and Windows SDK named in Prerequisites; the public manifests pin no compiler, Windows SDK or signing tool.
Both backends (the scene-reading implementation that a build
compiles in; Backends and trees) stage the ovstage wheel: the ovstage backend
builds against the ovstage SDK and runtime in it, and the
OpenUSD backend takes its ovx/ headers from it. The wrappers
never look for a sibling source checkout of ovstage or of any other project.
Unless an override names a wheel, the build runs
pip download --no-input --no-cache-dir --no-deps --only-binary=:all: --platform <tag> ovstage==<OVSTAGE_VERSION>
against the index pip is configured to use: public PyPI unless PIP_INDEX_URL,
PIP_EXTRA_INDEX_URL or a pip configuration file name another. The download is anonymous and
noninteractive: a credential, Poetry configuration or account is not required. pip keeps no copy in
its own cache: the build caches the wheel in the project-local _build/deps/downloads/ovstage
directory and stops unless the wheel matches its SHA-256 pin in OVSTAGE_SHA256SUMS. A failed
download stops the build with pip’s exit code and the variables that select the index. To build
offline, download the wheel yourself and set OVSTAGE_WHEEL_PATH to it, or put it in the
directory that OVCLASH_PIP_OVERRIDE_DIR names.
The ovRTX sample viewer setup installs the same pin: the wheel that an
ovstage build downloaded and verified, or else ovstage==<OVSTAGE_VERSION> from the same index.
It installs the pinned ovRTX wheel from NVIDIA’s public package index, which the PyPI ovrtx
release also installs from, and pip checks it against its SHA-256 pin. It is anonymous too; no
credential is required.
Dependency overrides lists every override and how the scripts read it. Dependency staging gives the order in which the build selects the ovstage wheel, and the checks of the include tree of the ovx headers.
Common tasks#
Before you begin: the host meets the Prerequisites, and it can reach the hosts that Dependency sources names, because the first step downloads the dependencies.
Run these in order for a first build. Each later command reuses what the earlier ones built. Use the Linux column on Linux and the Windows column on Windows.
Step |
Linux |
Windows |
Success |
|---|---|---|---|
1. Build the product backend into its install tree |
|
|
Exit code 0, and |
2. Run the packaged native tests |
|
|
Exit code 0 |
3. Run the full validation |
|
|
The run ends with |
4. Check the documentation links |
|
|
Two |
5. Package the wheel and SDK archive |
|
|
Exit code 0, and the wheel and the SDK archive are in |
A failing step stops with a nonzero exit code and names what failed. Troubleshooting lists the common build, download and validation failures, and Validation output shows how a failed validation step reads.
These programs answer a lone --help or --version before they do any work:
the build, documentation and packaging frontends, and those of Sentinel, the correctness campaign, and of KPI, the performance benchmark suite;
the C API samples and the native test programs;
the Sentinel helpers;
the
rtx_viewerdebugger host of the ovRTX sample viewer.
test_all prints its usage with --help but has no --version. Repository frontends report the
checkout’s VERSION, including any prerelease suffix. Native executables and the Python packages
report the numeric version of the compiled or loaded runtime. Native executables print their
banner on stderr, so their JSON or binary stdout keeps its format.
Backends and trees#
ovclash builds one backend per build tree. Each backend owns its own trees, so both can exist side by side for comparison.
Before you begin: the host meets the Prerequisites and can reach the hosts that Dependency sources names, because the first build of either backend downloads its dependencies.
On Linux:
./build_ovstage.sh --release # the product backend
./build_openusd.sh --release # the unpublished parity backend
On Windows:
build_ovstage.bat --release
build_openusd.bat --release
Each command prints ovclash build completed successfully., then
ovclash install tree assembled at <install-dir>, where <install-dir> is the backend’s install
tree in the table that follows, and exits with code 0. A failed configure stops with
CMake configuration failed (exit code: <n>), and a failed compile with
Build failed (exit code: <n>); both exit nonzero. Troubleshooting lists the
common build and download failures.
Backend |
Build tree |
Install tree |
Distribution output |
|---|---|---|---|
ovstage (Ninja, and all Linux builds) |
|
|
|
ovstage (Visual Studio, the Windows default) |
|
|
|
OpenUSD (Ninja, and all Linux builds) |
|
|
|
OpenUSD (Visual Studio) |
|
|
|
_build/ holds every generated output, but it is not a CMake build tree. Never configure
CMake directly in it. Besides the build, install and distribution trees of the backend table, it
holds these outputs:
Path |
Contents |
|---|---|
|
Shared dependency staging. It holds the Packman dependencies ( |
|
A validation run’s runtime evidence: task logs, the command log, sample outputs and timing caches. |
|
Native sample build trees ( |
|
Extracted SDK archive and wheel of the no-GPU smoke test of the SDK archive. |
|
C-consumer check trees. |
|
Test scratch files. |
|
Opt-in Python coverage data. |
|
Rendered documentation. |
|
Link-check stages. A passing check removes its stage; a failing one keeps it for inspection. |
|
Sentinel work areas; see the Sentinel guide. |
|
Default KPI outputs of the ovstage and OpenUSD backends; see the KPI guide. |
|
Compile output of the C++ benchmark launchers ( |
|
Default reports of the standalone benchmarks (the |
|
State and cache of the ovRTX sample viewer. |
Deleting _build/ removes every dependency, build, install and distribution tree. The next
build bootstraps from scratch.
On Linux, _build/ itself may be a symbolic link to another location, such as a larger drive.
On Windows, the packaged CMake cannot resolve a junction, so clean, install and packaging refuse
a junctioned _build/. Links further down, inside _build/, are refused wherever a generated
directory would be replaced or removed. To move only the dependencies, use the
dependency overrides, such as PM_PACKAGES_ROOT.
Install trees are per backend, not per configuration. The install step deletes the previous tree before it assembles a new one. A Debug install therefore replaces the Release install of the same backend, and an install from the Ninja tree replaces one from the Visual Studio tree. On Windows, close any process that holds files from an install tree before you rebuild it.
Builds assemble the install tree by default. Pass --no-install for a faster build-only
iteration.
--clean, and the clean step of --rebuild, removes:
the selected compile tree;
the backend’s install tree and its distribution directory (both generators share them);
that compile tree’s validation evidence for every configuration (
_build/validation/<backend>/<generator>/);the sample build root.
It keeps _build/deps, the other generator’s compile tree, the other backend’s trees and the
viewer state, _build/viewer/<backend>.
An explicit BUILD_DIR (a Linux -DBUILD_DIR=... option or a direct cmake -P call) under
_build must be one of the four compile trees of the backend table. Any other build tree must be
outside _build. Its validation evidence goes to _build/validation/<backend>/external-<id>/.
The distribution directory follows the install root alone, so the wheel and the SDK archive of one install land in one directory:
Install root |
Distribution directory |
|---|---|
|
|
An explicit |
|
Any other install root |
|
The install step recreates the chosen install root, so never point INSTALL_DIR at data you
need to keep.
Dependency staging describes how the build stages ovstage and the ovx headers for both backends.
Install step#
The install step, scripts/install.cmake, turns the build outputs into the relocatable install
layout. The install_sdk CMake target brings the library and the native tests up to date and
then runs it. The step does this:
It deletes the previous install tree and runs
cmake --installfor the selected configuration.It runs
scripts/package_deps.py, which writesdependency_audit.txt. For OpenUSD the script copies the namespaced OpenUSD dependency closure, andscripts/verify_pyless_closure.pythen checks that the closure is Python-free. For ovstage, CMake install rules select the closure.It assembles the license payload, the documentation and the agent skills.
On Linux it strips the ovclash-built ELF binaries of a Release install and enforces the GLIBC 2.35 / GLIBCXX 3.4.30 baseline.
On Windows, when code signing is enabled, it signs the binaries last. A
--validaterun whose plan has thesign_sdkstep signs in that step instead.
It compiles nothing, builds no wheel or archive and uploads nothing. The configuration selects only the ovclash-owned binaries: a Debug ovstage install holds Debug ovclash binaries and symbols over the published Release ovstage, OpenUSD and Carbonite closure.
Wrapper flags#
build_ovstage.* and build_openusd.* accept the flags of this table. Any other argument stops the
wrapper with Unknown option: before it builds.
Flag |
Meaning |
|---|---|
|
Configuration. Defaults to |
|
Delete this backend’s build, install and distribution trees, the build tree’s validation evidence and the sample build tree. Builds nothing. |
|
Delete the same trees, then build. |
|
Configure only; no compile. |
|
Build one CMake target. |
|
Assemble the install tree (the default), or skip it. |
|
Build, install and run the packaged native tests. |
|
Run the full validation flow for this backend; see Test and validate. |
|
Rebuild the Sentinel helpers with the tree’s compiler. Normal builds already include them. With |
|
Copy the SDK install tree, its Python runtime and the Sentinel helpers to |
|
In local-ovstage mode, stop when the local ovstage runtime is missing, or build it (the default). |
|
Print information and exit. Recognized only as the only argument. |
The Linux wrappers also accept short aliases (-r, -d, -c, -x, -g, -t NAME) and one
more flag:
Flag |
Meaning |
|---|---|
|
Pass a definition through to the CMake scripts. |
The Windows wrappers accept long flags only and reject -D options. Set the matching
environment variable instead. They add these flags:
Flag |
Meaning |
|---|---|
|
Visual Studio (the default) or Ninja generator. The |
|
Configure a Visual Studio tree only. Visual Studio solutions and F5 debugging describes how to use it. |
|
Build against a local ovstage checkout: |
|
Prepare the ovRTX sample viewer environment. |
|
Use a local checkout of ovui, the package that provides the viewer’s |
On Linux:
Set
OVCLASH_BUILD_LOCAL_OVSTAGE=ON, or pass-DOVCLASH_BUILD_LOCAL_OVSTAGE=ON, instead of--build-local-ovstage.OVCLASH_OVSTAGE_ROOTdefaults to anovstagedirectory beside the repository checkout.Run
setup_ovrtx_viewer.shinstead of--setup-ovrtx-viewer. It accepts--build-local-ovui.Ninja is the only generator.
Local-ovstage mode builds against an ovstage source checkout instead of the staged wheel. Packaging and publishing reject such builds. Local ovstage source builds describes the mode.
Rules for combining flags:
--prepare-sentineland--stage-inputscan follow--validatein the same invocation. After a passing validation, the wrapper only stages, and only with--stage-inputs: the validated build has already produced the Sentinel helpers.Neither
--prepare-sentinelnor--stage-inputscan be combined with--test,--generate,--clean,--rebuild,--target,--installor--no-install. On Windows, they also cannot be combined with--generate-vs. On Windows they cannot be combined with--setup-ovrtx-viewereither.--validatecannot be combined with--generateor--clean.
On Linux, the install step enforces an ELF release contract with the manylinux_2_35 baseline
(GLIBC <= 2.35, GLIBCXX <= 3.4.30). A host build on a newer distribution cannot meet it. A public
source export always builds on the host, so build on Ubuntu 22.04 or a compatible environment.
For a host build whose output you never publish, SKIP_GLIBC_CHECK=1 waives only the ABI
baseline check.
Test and validate#
Before you begin: the host meets the Prerequisites. Each command builds and
installs what it needs. The test_ovrtx_sample step of a validation also installs the viewer’s
Python packages from the package indexes; Validation steps shows how to drop
it offline.
On Linux:
./build_ovstage.sh --release --test # packaged native tests only
./build_ovstage.sh --release --validate # full validation, one backend
./test_all.sh --release # full validation, both backends
./test_all.sh --backend ovstage --release # full validation, one backend
./build_openusd.sh --release --target test_python_runtime # Python runtime suite only
On Windows:
build_ovstage.bat --release --test
build_ovstage.bat --release --validate
test_all.bat --release
test_all.bat --backend ovstage --release
build_openusd.bat --release --target test_python_runtime
Each command exits with code 0 when everything it ran passed. Every --validate run, including
each backend run of test_all, ends with All validation checks passed! No bugs, only features...; Validation output shows a passing and a failing run, and
Troubleshooting lists the common failures.
test_all validates both backends by default (--backend both, or --both):
It prints its plan.
It runs each selected backend wrapper, OpenUSD first, with your other options followed by
--validate.After both backends pass, it checks the two installs’
ovclash-build-provenance.jsonfiles. Both must be source-verified and record the same source revision, source tree, build type and ovclash version.
test_all rejects --rebuild, --target, --static-carb and --dynamic-carb.
test_all.sh also rejects the Windows-only generator flags.
An install built from a Git checkout records the working tree it was built from: HEAD and, with local changes, the tree of every staged, unstaged and untracked, not ignored file. Both installs of a two-backend run must be built from the same working tree, so do not edit sources between the two builds.
To run one native test or one Python test module instead of a whole step, see Run focused tests. Contributing lists the validation each kind of change requires.
Validation steps#
Each --validate run first builds and installs (build, install_sdk). A public source build
has no signing step unless OVCLASH_CODESIGN is on, which needs a staged signing tool; then a
sign_sdk step signs the install right after install_sdk.
Code signing describes when signing runs. The run
then executes these steps in order:
Step |
What it does |
|---|---|
|
Compiles, links and runs a C consumer against the install tree. |
|
Runs the packaged native tests. |
|
Runs the sharded Python runtime tests. |
|
Builds the wheel ( |
|
Runs the ovRTX sample viewer’s one-shot smoke against the install tree. It renders only when |
|
Checks the sample result counts, IDs, ordered pairs and mesh CRCs. |
|
Checks that nothing references the Kit clash extension sources. |
|
Checks ovx package coherence with synthetic header layouts. |
The steps named in |
Run in the order given; the table of opt-in steps in this section lists them. |
|
Packages the SDK archive ( |
A signing failure stops the run before the tests and packaging.
A full run writes both a wheel and an SDK archive to _build/dist/<backend>. Debug and
Release, and the Visual Studio and Ninja trees, share that directory, so the latest run
replaces the earlier artifacts. Runtime evidence stays apart per tree and configuration. For
the ovstage archive, test_c_compat_sdk_archive first installs the archive’s
requirements.txt offline, from the ovstage wheel the build staged, into a separate
environment. It then checks the installed native files against the archive’s
ovclash-runtime-closure.json inventory.
--validate builds the Sentinel executables but runs neither Sentinel nor its checker tests, and
it runs no KPI workloads.
OVCLASH_VALIDATE_EXTRA_TARGETS appends opt-in steps:
Step |
What it runs |
|---|---|
|
The documentation render. A public source build renders the public site as a gate only; otherwise the render is staged into the install tree’s |
|
The Sentinel controller and checker tests. |
|
The packaging of the SDK archive as an explicit step. Every run packages anyway, so this does not package twice. |
|
The ovRTX sample-app Python suite under |
An unknown extra name is fatal. OVCLASH_VALIDATE_EXCLUDE_TARGETS drops steps. An unknown
exclude name only warns. Both take a ;- or space-separated list. Set them as environment
variables, or, on Linux and in direct validate_all.cmake calls, as -D options.
For example, on Linux:
OVCLASH_VALIDATE_EXTRA_TARGETS=build_docs ./build_ovstage.sh --release --validate
On Windows, in PowerShell:
$env:OVCLASH_VALIDATE_EXTRA_TARGETS = "build_docs"
.\build_ovstage.bat --release --validate
Remove-Item Env:OVCLASH_VALIDATE_EXTRA_TARGETS
Without OVCLASH_TEST_OVRTX the test_ovrtx_sample step only detects and needs no GPU, but it
installs the viewer’s Python packages from the package indexes. Drop it where that is not
possible. On Linux:
OVCLASH_VALIDATE_EXCLUDE_TARGETS=test_ovrtx_sample ./build_ovstage.sh --release --validate
On Windows, in PowerShell:
$env:OVCLASH_VALIDATE_EXCLUDE_TARGETS = "test_ovrtx_sample"
.\build_ovstage.bat --release --validate
Remove-Item Env:OVCLASH_VALIDATE_EXCLUDE_TARGETS
Validation output#
Validation first prints a numbered plan. Each row names a step and what it checks. A step that needs a prerequisite script lists it:
-- Validation plan (11 steps):
-- 1. build Build the native runtime (initial)
-- 2. install_sdk Assemble and harden the installed SDK
-- 3. test_c_compat Compile, link and run a C consumer against the installed SDK
-- 4. test_cpp Run the packaged native tests, with a result for every test
-- 5. test_python_runtime Run sharded Python runtime tests against the installed SDK
-- 6. test_python_wheel Check wheel payload and docs, install offline, and run Python API smoke checks
-- Prerequisite: build_wheel (reused after the first run)
-- 7. test_ovrtx_sample Run the ovRTX validation app one-shot smoke
-- 8. test_samples Check sample result counts, IDs, ordered pairs and mesh CRCs
-- 9. test_no_clash_dependency Check for references into the Kit clash extension sources
-- 10. test_ovx_package_coherence Check OVX package coherence with synthetic header layouts
-- 11. test_c_compat_sdk_archive Compile, link and run a C consumer against the SDK archive
-- Prerequisite: package_sdk (reused after the first run)
With OVCLASH_CODESIGN on, the plan has sign_sdk (Prepare the signing tool and sign the installed SDK when enabled) as step 3, and the later steps are numbered one higher.
Each step then prints a banner (Step <n>/<count>: <name>), its command, and a closing status
line. A test step also prints Total tests run: <n>. The run ends with a summary table and the
verdict. <time> stands for each measured duration:
-- ========================================================================
-- Validation summary: ovstage backend, Release, passed after <time>
-- Timings cover this validation invocation only.
-- ========================================================================
-- STATUS ELAPSED STEP
-- OK <time> 1. build (initial)
-- OK <time> 2. install_sdk
-- OK <time> 3. test_c_compat
-- OK <time> 4. test_cpp
-- OK <time> 5. test_python_runtime
-- OK <time> 6. Build Python wheel (build_wheel)
-- OK <time> 6. Validate Python wheel (test_python_wheel)
-- OK <time> 7. test_ovrtx_sample
-- OK <time> 8. test_samples
-- OK <time> 9. test_no_clash_dependency
-- OK <time> 10. test_ovx_package_coherence
-- OK <time> 11. Package SDK archive (package_sdk)
-- OK <time> 11. Validate SDK archive C consumer (test_c_compat_sdk_archive)
--
-- Task logs: <validation-dir>/run_parallel_logs/<suite>/<task>.log
-- Commands: <validation-dir>/validation_commands.log
--
-- All validation checks passed! No bugs, only features...
The verdict line is the last line validation prints. The wrapper then prints its total time.
How to read the table:
Status |
Meaning |
|---|---|
|
The step passed. |
|
|
|
The step failed. The row ends with |
|
The run stopped before this step. |
A prerequisite script shares its target’s step number and has its own timer. Step 6 separately builds and validates the Python wheel; step 11 separately packages the SDK archive and validates its C consumer. These display labels keep the original target names in parentheses.
The build row reads
build (initial), orbuild (incremental)when the build tree was already configured.Timings cover only this invocation. An incremental run excludes the earlier build, install and documentation time, and says so under the summary heading.
A failed run prints the same table, with FAILED in the summary heading. The table shows the
failed step and every step the run did not reach:
-- Validation summary: ovstage backend, Release, FAILED after <time>
...
-- OK <time> 4. test_cpp
-- FAILED <time> 5. test_python_runtime (exit code: 1)
-- NOT RUN - 6. Validate Python wheel (test_python_wheel)
-- NOT RUN - 7. test_ovrtx_sample
...
It then prints the failed command with its working directory, and stops with
<target> failed in <script>.cmake (exit code: <n>).
The output is colored. A non-empty NO_COLOR or TERM=dumb turns the colors off. On Windows
the colors follow whether the output is a console: redirected to a file or piped to another
program, it is plain. Elsewhere colors also reach redirected output, so set either variable for
plain logs.
Validation evidence#
Compiler output, the build provenance and validation_receipt.json stay in the compile tree.
The C-consumer checks build in _build/c_compat_<leg>. The run’s other runtime evidence goes
to the tree’s validation directory, <validation-dir>:
_build/validation/<backend>/<generator>/<configuration>, for example
_build/validation/ovstage/vs/Release.
File |
Contents |
|---|---|
|
Each step’s command, with credentials and known secret values masked. Masking is best effort. When you rerun a step from the log, supply the masked values yourself. |
|
The output of each parallel task; see Parallel tests and shard planning. |
|
The plan, each step’s status and elapsed time and, at the end, SHA-256 digests of the installed native libraries and the packaged artifacts. KPI preparation reads it; Supported workflows in the KPI contracts defines each field with its type and values. |
Sentinel, the engine-correctness and serialization-equivalence workflow, is separate. The
Sentinel guide covers test_sentinel.*, automatic input preparation and
the checker tests.
Other validation runs#
Before you begin: the host meets the Prerequisites. On Linux, the ELF release
contract in install.cmake also needs a build environment whose glibc is no newer than the
manylinux_2_35 baseline (the Python platform tag for Linux binaries that need at most glibc 2.35);
see Wrapper flags.
To validate every backend and configuration that CI builds on your platform, run each wrapper
with --validate. On Linux:
./build_ovstage.sh --release --validate
./build_ovstage.sh --debug --validate
./build_openusd.sh --release --validate
./build_openusd.sh --debug --validate
On Windows:
build_ovstage.bat --release --validate
build_ovstage.bat --debug --validate
build_openusd.bat --release --validate
build_openusd.bat --debug --validate
Each run passes when it ends with All validation checks passed! No bugs, only features... and
exits with code 0. A failing run prints FAILED in its summary table, as
Validation output shows; Troubleshooting lists the
common build and download failures.
Add the opt-in steps you need, and quote the semicolon-separated values. On Linux:
OVCLASH_VALIDATE_EXTRA_TARGETS="build_docs;package_sdk" \
./build_ovstage.sh --release --validate
On Windows, in PowerShell:
$env:OVCLASH_VALIDATE_EXTRA_TARGETS = "build_docs;package_sdk"
.\build_ovstage.bat --release --validate
Remove-Item Env:OVCLASH_VALIDATE_EXTRA_TARGETS
Add the ovRTX sample-app suite the same way. On Linux:
OVCLASH_VALIDATE_EXTRA_TARGETS="test_python_sample_app;build_docs;package_sdk" \
./build_ovstage.sh --release --validate
On Windows, in PowerShell:
$env:OVCLASH_VALIDATE_EXTRA_TARGETS = "test_python_sample_app;build_docs;package_sdk"
.\build_ovstage.bat --release --validate
Remove-Item Env:OVCLASH_VALIDATE_EXTRA_TARGETS
Run the ovRTX rendering smoke on a machine with a GPU and Vulkan, the Khronos graphics API; see
OVCLASH_TEST_OVRTX in Build and test environment variables.
Python coverage. The opt-in test_python_coverage target reruns the Python runtime suite
under coverage.py and writes _build/coverage/python_tests/coverage.json.
scripts/parse_coverage.py reports it per shipped package and exits with status 1 when a package
falls below the minimum. Build the ovstage backend first, then run, on Linux:
cmake -DBUILD_DIR=_build/compile/ovstage/ninja -DTARGET=test_python_coverage -DCONFIG=Release -P scripts/build_target.cmake
python3 scripts/parse_coverage.py _build/coverage/python_tests/coverage.json
On Windows:
.\_build\deps\target-deps\cmake\bin\cmake.exe -DBUILD_DIR=_build/compile/ovstage/vs -DTARGET=test_python_coverage -DCONFIG=Release -P scripts/build_target.cmake
python scripts\parse_coverage.py _build/coverage/python_tests/coverage.json
Use the packaged CMake under _build/deps/target-deps/cmake/bin when no system CMake is on the
path. Without the ovstage build, build_target.cmake stops with
No configured build tree at <path> (CMakeCache.txt is missing); a failing test stops it with
Build failed (exit code: <n>). Python coverage describes
the gate.
Sentinel and KPI inputs. To stage the inputs that a local Sentinel or KPI run reads, add
--stage-inputs to the Release validation, for example
./build_ovstage.sh --release --validate --stage-inputs. Staging copies the validated SDK
install tree, its Python runtime and the Sentinel helpers into
_build/portable-inputs/<backend>/Release without compiling. run_kpi and test_sentinel
prepare these inputs themselves when they are missing; see
Automatic preparation and the
Sentinel guide.
Local Windows validation usually skips Authenticode signing (Microsoft’s code-signing format); the
KPI quick start gives the commands that
prepare Release inputs by hand, and
automatic preparation sets OVCLASH_CI_REF_PROTECTED
itself. OVCLASH_CI_REF_PROTECTED=false records the unprotected development ref in the validation
receipt, which KPI preparation requires before it accepts that ovstage skip. An OpenUSD skip does
not depend on the ref; see Supported workflows.
Source exports. Git is optional for the local build, packaging, KPI and baseline workflows. The build provenance contract describes the content fingerprints used when Git metadata is unavailable.
Parallel tests and shard planning#
--validate runs native test groups, Python shards and sample checks concurrently. It uses at
most min(task count, CPU count, 16) workers. The validation steps themselves run one after
another.
Setting |
Effect |
|---|---|
|
Caps the workers at |
|
Forces one worker. |
validate_all.cmake reads both from -D or the environment; -D takes precedence. Called
directly, test_cpp.cmake, test_python_runtime.cmake and test_samples.cmake run one task
at a time unless OVCLASH_PARALLEL_TESTS=ON. test_samples.cmake reads it only from -D.
Before you reproduce a failure with one worker: the host meets the
Prerequisites. The rerun is a full --validate run, which builds and installs
what it needs, as Test and validate describes.
On Windows, in PowerShell, use the environment, because the Windows wrapper rejects -D
options:
$env:OVCLASH_PARALLEL_JOBS = "1"
.\build_ovstage.bat --release --validate
Remove-Item Env:OVCLASH_PARALLEL_JOBS
On Linux, pass the option to the wrapper:
./build_ovstage.sh --release --validate -DOVCLASH_PARALLEL_JOBS=1
The validation header then reads Parallel tests: ON (max workers = 1). The rerun passes as any
--validate run does: it ends with All validation checks passed! No bugs, only features... and
exits with code 0. When a task fails again, the console prints its output, which also stays in
<validation-dir>/run_parallel_logs/<suite>/<task>.log; Validation output
shows how a failed step reads, and Troubleshooting lists the common failures.
When you call scripts/validate_all.cmake directly, add -DOVCLASH_PARALLEL_JOBS=1 to the
same backend and build options. One worker runs the same shards one after another. It does not
limit the native libraries’ own threads.
Python shards come from the current unittest discovery, so adding, renaming or removing tests needs no maintained test-name list:
Every run recalculates the shard count from the test inventory, the worker count and the per-test durations cached under
<validation-dir>/python_test_durations/<suite>/.PYTHON_TEST_SHARD_SIZEandPYTHON_TEST_SHARD_SECONDSoverride the derived shard size and time target.A module’s literal
PYTHON_TEST_MIN_SHARDS = Nraises its minimum shard count.The derived time target is a planning goal, not a timeout. More shards cannot shorten a single slow test, so measure by test ID rather than by shard number.
Ordinary python_tests shards have no default timeout, including coverage runs. A positive
PYTHON_TEST_TIMEOUT_SECONDS=N, given as -DPYTHON_TEST_TIMEOUT_SECONDS=N or as an environment
variable, sets a per-shard timeout; the -D value wins for a direct test_python_runtime.cmake
call and for --validate, which forwards it to test_python_runtime and prints it in its
header as Python timeout: <N>s per shard, or Python timeout: none. An explicit value
also replaces the 1860-second default of the KPI reference-fixture suite. The
test_python_runtime and test_python_coverage CMake targets inherit the environment form; they
do not forward a PYTHON_TEST_TIMEOUT_SECONDS cache value.
The ovRTX sample_app_tests shards have no default timeout either, and
--validate also forwards the value to test_python_sample_app.
Each task’s full output is saved to <validation-dir>/run_parallel_logs/<suite>/<task>.log. A
failed task also prints it on the console. Each Python test result line ends with its duration
in seconds, such as ... ok [0.123].
The opt-in test_sentinel_checkers step uses the same planner.
Checker tests in the Sentinel guide describes its workers and
evidence.
Test environment and fixtures#
The native, Python runtime and smoke test drivers put temporary files under
_build/test_tmp:
Outside Windows, the native driver instead uses a per-checkout
/dev/shm/ovclash-test-<hash>directory. It does so when/dev/shmis a tmpfs with at least 48 MiB free and the directory is private to the current user. The storage tests of the Suite API sync every record and SQLite commit, so a memory-backed directory is faster.Set
OVCLASH_TEST_TEMP_ROOTto choose another writable parent. Direct calls toscripts/test_cpp.cmake,scripts/test_python_runtime.cmakeand the other test drivers also accept-DOVCLASH_TEST_TEMP_ROOT=PATH, which takes precedence. Relative values are anchored to the ovclash checkout.The drivers set
TMP,TEMPandTMPDIRonly for their own process tree. Each fixture owns a private child directory, and no driver deletes the shared parent.
The drivers also keep many concurrent test processes from oversubscribing the host, unless you export your own value:
The native driver sets
PXR_WORK_THREAD_LIMIT=2. Set0to restore OpenUSD’s one worker per hardware thread.The Python runtime driver sets
OPENBLAS_NUM_THREADS=1. Otherwise numpy’s OpenBLAS starts a worker per logical CPU in every test process, and on Windows each worker commits a large buffer up front.
Rules for test fixtures:
Keep regression fixtures just large enough to exercise their boundary.
Fixtures that fake optional modules must import native dependencies such as NumPy before patching
sys.modules. Restoring that dictionary must not unload a newly imported extension.Give synthetic GUI gestures explicit modifier state, so the host keyboard cannot affect unrelated tests.
Redaction fixtures use only synthetic secret values.
The Suite API migration test (test_suite_legacy_migration.py) needs no OpenUSD Python bindings.
It runs in every validation on both backends.
Packaging and publishing#
Before you begin: the host meets the Prerequisites. Packaging reuses an existing build and install, and it never rebuilds, so the first command of each pair builds and installs. On Linux:
./build_ovstage.sh --release
./build_packages.sh --backend ovstage --release
On Windows:
build_ovstage.bat --release
build_packages.bat --backend ovstage --release
build_packages writes the Python wheel and this platform’s SDK archive to
_build/dist/<backend>/ and exits with code 0; the two files appearing there is the success
check. Every --validate run already writes both. When the build fails, or packaging finds no
matching install, the command stops with a nonzero exit code; Troubleshooting
lists the common build and download failures.
Option |
Meaning |
|---|---|
|
The install to package. Defaults to |
|
The configuration of the installed build. Defaults to |
|
Windows: the build tree to package, Visual Studio by default. |
|
Print information and exit. Use them alone. |
build_packages accepts no native build flags and no -D settings.
--backend openusd produces developer artifacts that are not a product. That wheel bundles
its own OpenUSD closure, declares no ovstage dependency and carries openusd in its local version.
Publishing rejects it.
Packaging reads the install’s ovclash-build-provenance.json:
It warns when the install records
source_verified: false. It then cannot detect source edits made after the install. Rebuild and reinstall after editing sources.It rejects an install built against a local ovstage source checkout (
--build-local-ovstageon Windows,OVCLASH_BUILD_LOCAL_OVSTAGE=ONon Linux). The pinnedovstageversion does not identify that build.
It also warns about other ovclash archives left in _build/dist/<backend>; remove the ones that
do not belong to this build.
Artifact names carry the version:
Build |
Version |
|---|---|
A |
The bare |
Any other branch |
The PEP 440 local version (the |
No branch name |
|
The OpenUSD backend |
The same, with |
Wheels are tagged win_amd64, manylinux_2_35_x86_64 or manylinux_2_35_aarch64, for example
ovclash-<version>-py3-none-win_amd64.whl. SDK archives are ovclash-<version>-<platform>.zip
on Windows and ovclash-<version>-<platform>.tar.gz on Linux. <platform> is
windows-x86_64, linux-x86_64 or linux-aarch64.
To package only the SDK archive, name the backend install tree explicitly. Use the packaged
CMake under _build/deps/target-deps/cmake/bin, or any CMake 3.19 or newer. The script reads
the backend and build type from the install’s provenance:
cmake -DINSTALL_DIR=_build/install/ovstage -P scripts/package_sdk.cmake
Without INSTALL_DIR, it packages _build/install/openusd, or _build/install/ovstage only
when -DOVCLASH_OVSTAGE_ONLY=ON is passed.
No SDK archive ships the native test programs (ovclash.<suite>.test, .exe on Windows) or their
symbols; the install tree keeps them for test_cpp, Sentinel and the debugger.
The ovstage archive leaves ovstage out:
Packaging copies the install tree into a disposable staging directory. The install tree keeps the full runtime.
It removes the ovstage loader and runtime, their native closure and
plugins/from that copy.It adds
requirements.txt(exactlyovstage==<pin>),ovclash-runtime-dependencies.jsonand theovclash-runtime-closure.jsonchecksum inventory of the removed native files. The inventory is taken from the ovstage wheel the build staged. When that wheel is missing, packaging stops before it replaces anything in the distribution directory.
A consumer installs the requirement separately, as Installing the ovstage runtime describes. The OpenUSD developer archive keeps the rest of its install tree. SDK install tree describes how packaging builds the archive.
Building this documentation#
Before you begin: the render needs an install tree of the backend it renders against, the ovstage one by default, so build and install that backend first; the link check needs no build.
build_docs.sh / build_docs.bat runs two gates:
The render,
repo docs --project <project> --warn-as-error=1, rendersdocs/to HTML with Sphinx, the documentation generator, and Doxygen, the C/C++ documentation generator. It fails on a broken cross-reference, a page that no{toctree}(the page list of a root page’s table of contents) lists, or a Doxygen parse error. In a public source export the project isovclash-public: the public site rooted atdocs/index_public.md, with the public pages only.The link check,
scripts/check_docs_links.cmake, checks the Markdown that ships. It builds one stage for the wheel and one for the SDK archive:docs/consumer/in the SDK archive stage only, and the package’s README, staged the way that package stages them;skills/andsamples/, copied from the checkout. They include the ovRTX sample’s README, which neither package ships.
It then runs
documentation_payload_smoke.pyover each stage. The check fails when a relative link in any staged Markdown file does not resolve inside that stage; in the wheel stage, which has nodocs/, a link intodocs/passes only with the(SDK archive):label and only when it names a page ofdocs/consumer/. It also fails when the SDK archive stage’sdocs/consumer/and the sourcedocs/consumer/differ, or when a page lies elsewhere under itsdocs/. Links resolve case-sensitively, so a link that works only on a case-insensitive filesystem fails on Windows too.
On Linux:
./build_ovstage.sh --release
./build_docs.sh
On Windows:
build_ovstage.bat --release
build_docs.bat
The run passes when build_docs ends with SUCCESS: build_docs completed and exits with code 0;
the link check also prints two documentation payload OK lines. Without an install tree the
render stops first: build_docs.sh prints No installed library at <path>., and build_docs.bat
prints FAILED: installed runtime check. No library at "<path>".. A broken link fails the link
check with Documentation link check failed for the <layout> layout. When the build itself fails,
Troubleshooting lists the common causes.
Option |
Meaning |
|---|---|
|
The install tree to render against. Defaults to |
|
Build and install that backend ( |
|
Render the public site, the |
|
Skip the render and run only the link check. It needs no build tree and takes seconds. Run it after every docs edit. |
|
Render only. |
The render needs an install tree:
Sphinx autodoc imports
ovclashandovclash_suitefor real, rather than mocking their hand-writtenctypesbindings.The native library loads only from the install tree, where
install.cmakestages its ovstage dependency closure. The wrapper pointsOVCLASH_SUITE_LIBat the installed library. It stops when there is none, rather than rendering an empty API reference.Before rendering, it generates
docs/consumer/CHANGELOG.mdfromCHANGELOG.md, because the toctree of each root page names that untracked file.
repo.sh / repo.bat keep the Packman cache in _build/deps/packman-cache and the overrides
in _build/deps/packman-override. An explicit PM_PACKAGES_ROOT or
OVCLASH_PACKMAN_OVERRIDE_DIR wins.
build_docs writes the public site to _build/docs/ovclash-public/latest. It clears
_build/docs/ovclash-public before it renders, so a page that has left the site leaves no HTML
behind, and refuses to clear a linked output directory. An SDK archive built from the public source
carries the Markdown documentation only, never a rendered docs/html: neither the install step nor
the build_docs validation step stages one.
Under --validate, the link check runs inside test_python_wheel. The render runs only as the
opt-in build_docs step (OVCLASH_VALIDATE_EXTRA_TARGETS=build_docs). That step renders
against the installed runtime into an emptied _build/docs/<project>; in a public source build
it is a gate only.
docs/README.md indexes every page and states which set it belongs to.
Contributing summarizes the documentation rules, and AGENTS.md
(“Doc authoring conventions”) has them in full.
Doxygen generates the C API reference from the checked-in public headers under
include/ovclash/ and include/ovclash_suite/, listed as doxygen_input in repo.toml.
OVCLASH_STANDALONE=1 is predefined for that run. Without it, the reference would silently
omit the standalone entry points that ovclash.h fences behind the define.
ovRTX sample viewer#
The ovRTX sample viewer, the ovRTX clash sample app, is an optional developer viewer. It renders
the stage with ovRTX, NVIDIA’s RTX rendering runtime,
outside Kit and runs and lists queries. It is not part of the product or of either
package. samples/ovrtx_clash_sample_app/README.md covers its dependencies, controls and
environment variables, and ovRTX Clash Sample App its internals.
Before you begin:
Build and install the backend you launch, with
build_ovstage --releaseorbuild_openusd --release. The launchers do not build ovclash.Rendering needs an NVIDIA RTX GPU with a supported driver.
The first launch installs the viewer’s Python packages from public package indexes, so it needs network access.
Launch one backend’s viewer. On Linux:
./launch_rtx_viewer_ovstage.sh
./launch_rtx_viewer_openusd.sh
On Windows:
launch_rtx_viewer_ovstage.bat
launch_rtx_viewer_openusd.bat
A launcher that starts the viewer prints Launching ovclash ovRTX viewer: and the viewer
command, and the viewer window opens. Without the backend’s install tree it stops with
ovstage ovclash native library not found: <path> (OpenUSD ovclash native library not found
for OpenUSD) and the build command to run. A failed package install during setup stops with
pip’s error; Troubleshooting lists the hosts that the downloads need.
The launchers run the viewer’s Python from source and load the installed native library through
OVCLASH_LIB, so rebuilding the matching backend picks up C++ changes.On first use they create the backend’s viewer environment,
_build/deps/venv/ovrtx_viewer_<backend>, and they set it up again when an installed ovRTX, ovstage or ovui has another version than the checkout pins.setup_ovrtx_viewer.sh --backend ovstage|openusd, orsetup_ovrtx_viewer.bat, prepares or refreshes it explicitly.Setup installs the pinned ovRTX wheel,
ovuiand ovstage, all from public package indexes and without a credential. The ovRTX wheel comes from NVIDIA’s public package index, which the PyPIovrtxrelease also installs from, and pip installs it only when its SHA-256 matches the pin;OVRTX_WHEEL_PATHor an override directory names a local copy instead.ovuiand ovstage come from pip’s configured index, public PyPI by default. The defaultovui==0.2.0needs CPython 3.12. UnlessOVSTAGE_WHEEL_PATH, an override directory orOVSTAGE_PIP_REQUIREMENTnames another ovstage, setup installs the wheel that an ovstage build downloaded and verified againstOVSTAGE_SHA256SUMS, or elseovstage==<OVSTAGE_VERSION>, the pin the backend builds use. Only the OpenUSD environment installsusd-core.The one-shot smoke without
OVCLASH_TEST_OVRTXdoes not render.OVCLASH_SETUP_HEARTBEAT_SECONDSsets the interval of setup progress lines for commands without their own progress (default30;0turns them off). Pip installs use their native output without setup heartbeats.
Building against a local install tree#
The consumer pages describe building against a released SDK archive: Linking in the C/C++ Quickstart, with every consumer CMake variable. This section covers what differs for a local install tree.
Local install trees and the OpenUSD SDK archive#
A local install tree, _build/install/<backend> in a source checkout, and the unpublished OpenUSD
SDK archive keep the complete runtime closure beside libovclash.so. They need neither the separate
ovstage install nor Python at configure time. They still need the ovx headers, which they do not
ship: their include/ovx holds only dlpack. Add -DOVCLASH_OVX_INCLUDE_DIR=<ovstage>/include to
the configure command, where <ovstage> is the ovstage package directory. In a source checkout that
is _build/deps/pip-deps/ovstage/ovstage under ovclash/. With an installed ovstage wheel it is
<site-packages>/ovstage. Without it, the configure stops with
ovx/string_types.h (or ovx/types.h) was not found; see
The ovx include tree.
For example, from your project directory, against a checkout’s ovstage install tree:
cmake -S . -B _build \
-Dovclash_DIR=<ovclash>/_build/install/ovstage/lib/cmake/ovclash \
-DOVCLASH_OVX_INCLUDE_DIR=<ovclash>/_build/deps/pip-deps/ovstage/ovstage/include
cmake --build _build --config Release
<ovclash> is the ovclash/ directory of the checkout. Both commands exit with code 0 when the
configure and the build succeed, and the build directory _build of your project then holds
your program.
To run such a program, put the runtime directories of the install tree <install>, such as
<ovclash>/_build/install/ovstage, on the loader path of its process. Windows has no run path: put
<install>\bin and <install>\plugins on PATH. On Linux, a CMake program started from its build
tree has a run path to <install>/lib; a program linked through pkg-config, or moved out of its
build tree, needs <install>/lib and <install>/plugins on LD_LIBRARY_PATH. Otherwise it exits
with 0xc0000135 (Windows) or 127 (Linux) before main. The run_*_cpp sample launchers set
these paths themselves.
The ovx include tree#
<ovclash/ovclash.h> includes <ovx/string_types.h>, or the older <ovx/types.h> when that
header is absent. ovclash does not ship either header. ovstage produces them, in the include/
directory of the installed ovstage wheel or of the ovstage SDK. Every ovclash install tree
ships exactly one ovx header, ovx/dlpack/dlpack.h, in its own include tree.
The CMake config of the product SDK archive finds the headers in the installed ovstage package. A
local install tree has no such package, so name the ovx include directory yourself:
Setup |
|
|---|---|
Source checkout |
|
pip-installed ovstage wheel |
|
The exported config validates the directory: one without ovx/string_types.h or ovx/types.h
is a fatal configure error. Linking gives the full lookup
order and OVCLASH_ALLOW_MISSING_OVX.
pkg-config consumers set the directory through the ovx_includedir variable of ovclash.pc. In
a local install tree and the OpenUSD SDK archive, ovx_includedir defaults to the ovclash include
directory, whose only ovx header is ovx/dlpack/dlpack.h. A local tree’s ovclash.pc has no
ovstage_root variable, so point ovx_includedir at the ovstage include directory.
Before you begin: the install tree <install> exists, built as
Backends and trees describes, and <ovstage> is the ovstage package
directory of
Local install trees and the OpenUSD SDK archive.
On Linux, from the directory that holds your C program app.c:
gcc app.c -o app $(PKG_CONFIG_PATH=<install>/lib/pkgconfig \
pkg-config --define-variable=ovx_includedir=<ovstage>/include \
--cflags --libs ovclash)
The command exits with code 0 and writes the executable app. When ovx_includedir names no ovx
headers, the compile stops at #error "ovclash requires ovx/string_types.h or ovx/types.h". The
link may also need -Wl,-rpath-link,<install>/lib, where the install tree keeps the ovstage
libraries. The CMake config adds that option for you; ovclash.pc does not. Run app with the
loader path that
Local install trees and the OpenUSD SDK archive
gives for a program linked through pkg-config.
On Windows, use the CMake config instead, with -DOVCLASH_OVX_INCLUDE_DIR as the example in
Local install trees and the OpenUSD SDK archive
shows.
Running the module from a source checkout#
To run the module against a local install tree, put ovclash/python/ on PYTHONPATH. Then set
OVCLASH_LIB or OVCLASH_SUITE_LIB to the absolute path of the installed native library.
A relative path fails at import with
OVCLASH_SUITE_LIB/OVCLASH_LIB must be an absolute trusted native library path. On Windows, also
set OVCLASH_DLL_DIRS when the runtime dependency directories are not on the DLL search path.
From ovclash/, after ./build_ovstage.sh --release, with any Python 3.10 or newer. On Linux:
export PYTHONPATH="$PWD/python"
export OVCLASH_LIB="$PWD/_build/install/ovstage/lib/libovclash.so"
python -m ovclash --stage tests/data/mesh_mesh_overlapping.usda \
--scope-a /World/Objects/meshA --scope-b /World/Objects/meshB
On Windows, in PowerShell:
$env:PYTHONPATH = "$PWD\python"
$env:OVCLASH_LIB = "$PWD\_build\install\ovstage\bin\ovclash.dll"
python -m ovclash --stage tests\data\mesh_mesh_overlapping.usda --scope-a /World/Objects/meshA --scope-b /World/Objects/meshB
The version header goes to stderr. Stdout holds only the JSON summary; Command line in the Python package guide defines each of its fields with its type and values:
{
"duplicate_count": 0,
"duplicates": [],
"overlap_count": 1,
"overlaps": [
{
"name0": "/World/Objects/meshA",
"name1": "/World/Objects/meshB",
"nb_elements": 52,
"time": 0.0,
"type": 0
}
],
"pipeline_steps": [
"Releasing previous data...",
"Finding meshes...",
"Computing initial mesh data...",
"Finding shared meshes...",
"Cooking meshes...",
"Computing global mesh data...",
"Building BVH...",
"Running broad-phase...",
"Purging duplicates...",
"Running narrow-phase...",
"Processing results..."
],
"stage": "tests/data/mesh_mesh_overlapping.usda"
}
In Git Bash on Windows, set MSYS_NO_PATHCONV=1 for this command. Otherwise Git Bash rewrites
/World/... into a Windows path, and the query fails with Invalid prim path in scope.
Command line in the Python package guide lists the module’s
options.
Samples in a source checkout#
Samples describes the shipped samples and their launchers in the wheel and
the SDK archive, and Building the C++ samples
the build_samples options. A source checkout behaves differently, as
Building the shipped samples and
Sample launchers in a source checkout describe.
Building the shipped samples#
samples/build_samples.sh (samples\build_samples.bat on Windows) builds every sample against
a local install tree as well as against an SDK archive:
Without
--install-rootorOVCLASH_INSTALL_ROOT, the script uses the first directory that holdslib/cmake/ovclash/ovclashConfig.cmake: the root that containssamples/, then_build/install/openusd, then_build/install/ovstageunder it. With both backends installed, pass--install-rootto choose one.The default build root is
_build/samplesunder the ovclash root, with one child directory per sample.When
OVCLASH_OVX_INCLUDE_DIRis unset, the script takes the first of these directories that holdsovx/string_types.horovx/types.h:_build/deps/pip-deps/ovstage/ovstage/includeunder the root that containssamples/, then the same path under the directory above that root, thenovstage/includebeside the root, thenovstage/includeone level higher, and last the staged tree of the checkout that built the selected_build/install/<backend>. Set the variable when anovstagedirectory beside the root, such as a sibling checkout, must not be used.Local install trees configure without Python.
The script copies the install’s
ovclash-build-provenance.jsoninto each sample tree and configures a tree from scratch when its copy differs. A sample tree therefore starts fresh after an install with new provenance, such as a build of a new commit.
Sample launchers in a source checkout#
Before you begin: the host meets the Prerequisites. A launcher builds a missing install tree itself, so the first run of each backend takes as long as its build.
The clash_api and clash_suite_api launchers in a source checkout default to
--backend both: they run the OpenUSD backend against _build/install/openusd, then the ovstage
backend against _build/install/ovstage, and build a missing install tree first; a failed build
stops the launcher, and Troubleshooting lists the common causes. An explicit
--backend (or --openusd / --ovstage) or OVCLASH_BACKEND selects one backend, and
OVCLASH_INSTALL_ROOT is ignored when they run both. With --backend both, --output-dir DIR
writes the OpenUSD outputs under DIR/openusd and the ovstage outputs under DIR/ovstage.
With the default --backend both, a launcher prints === Running OpenUSD backend === and
=== Running ovstage backend === as it starts each backend, and exits with code 0 when both runs
pass. Without --output-dir, each run
writes its results to _build/<sample>_<language> for OpenUSD and
_build/<sample>_<language>_ovstage for ovstage, such as _build/clash_suite_api_cpp and
_build/clash_suite_api_cpp_ovstage for run_clash_suite_api_cpp.
Source-checkout launchers use the checkout’s staged Python and skip the sample runtime helper
samples/sample_python.py.
To pass your own processor arguments through a launcher, select one backend and put the
arguments after --:
On Linux:
./samples/clash_suite_api/run_clash_suite_api_cpp.sh --backend ovstage -- --stage tests/data/time_sampled.usda --num-tasks 8
On Windows:
samples\clash_suite_api\run_clash_suite_api_cpp.bat --backend ovstage -- --stage tests/data/time_sampled.usda --num-tasks 8
The launcher exits with code 0 when the processor does, and writes only the outputs that your arguments name.
samples/legacy_clash_detection/ has its own run_legacy_clash_detection_cpp and
run_legacy_clash_detection_python launchers, without a backend selector. From a source
checkout they use _build/install/openusd unless --install-root selects another tree.
samples/clash_suite_api/run_custom_clash.{sh,bat} runs the Clash Processor, the sample program
that runs one query on a USD stage from command-line arguments and saves the results;
samples/clash_suite_api/clash_processor.md is its guide. In a source checkout it uses a built
_build/install/<backend> of the checkout before it falls back to the published wheel, so after
./build_ovstage.sh --release a plain run_custom_clash runs your build. --backend openusd
builds a missing _build/install/openusd. The wheel fallback installs into
_build/deps/venv/custom_clash, and runs the checkout’s processor against the published wheel,
which can lack newer API.
Configuration reference#
The consumer pages document the variables of an installed package: Linking the CMake variables a consumer sets, and Environment variables the runtime variables.
Dependency overrides#
These variables select the build dependencies; Dependency sources explains
what each one replaces. The wrappers and the cmake -P scripts read them from the environment.
When a cmake -P script or a Linux wrapper also receives a -D definition of the same name, the
definition wins. A relative path is anchored to the checkout.
Variable |
Effect |
|---|---|
|
ovstage wheel version of the default download. The pin in the |
|
Local ovstage wheel used instead of any download. The file must exist. |
|
Directories searched for the ovstage wheel, and by the ovRTX viewer setup also for the pinned ovRTX wheel. |
|
pip requirement or wheel path that replaces the default download, for both backends and the ovRTX viewer setup. |
|
Packman cache and override directories. Default |
|
CMake definitions only: the target and host dependency roots. Default |
|
|
|
ovstage source checkout for local mode. In that mode the wrappers and a direct CMake configure default it to an |
|
ovstage build tree for local mode. Defaults to |
|
|
|
|
|
OpenUSD runtime root for ovstage builds, tests and launchers. The default is the Packman OpenUSD package under |
Build and test environment variables#
These variables control the source-checkout build and test tooling described on this page.
Variable |
Values |
Required |
Default |
Effect |
See |
|---|---|---|---|---|---|
|
A CMake true value, such as |
No |
Unset: the check runs |
Waives only the Linux ELF ABI baseline check, for builds that are never published. |
|
|
|
No |
|
Windows default generator for the build wrappers and |
|
|
|
No |
|
|
“Public source builds” in |
|
Directory paths |
No |
The Developer Command Prompt’s |
Roots of the installed Visual Studio and Windows SDK. A relative root, from |
“Public source builds” in |
|
An installed Windows SDK version |
No |
The newest one with complete x64 |
Installed Windows SDK version to use. |
“Public source builds” in |
|
Path of a CMake executable |
No |
The packaged CMake under |
CMake executable for |
|
|
A CMake true or false value, such as |
No |
Unset: signs only on Windows, and only when a staged signing tool can authenticate |
A true value requires code signing of the Windows install; a false value skips it. |
|
|
Step names, |
No |
Empty |
Add or drop |
|
|
A positive integer |
No |
Unset: |
Caps the test workers. |
|
|
|
No |
|
|
|
|
A non-negative integer |
No |
Unset: derived from the test inventory and durations |
Overrides the derived Python shard size. |
|
|
A positive number of seconds |
No |
Unset: derived |
Overrides the derived Python shard time target. |
|
|
A positive number of seconds |
No |
Unset: no timeout; 1860 for the KPI reference-fixture suite |
Per-shard Python test timeout. |
|
|
A CMake true value, such as |
No |
Unset: every module runs |
Leaves the modules that test the publishing of the source tree, such as |
|
|
A writable directory path |
No |
|
Parent directory for test scratch files. |
|
|
A directory path |
Only for Python test modules run outside the test drivers |
|
Test fixture directory. |
|
|
Environment: any non-empty value, |
No |
Unset: the step detects only and does not render |
Makes |
|
|
A CMake true value, from |
No |
Unset: the test fails |
Makes |
|
|
A number of seconds; |
No |
|
Interval of the ovRTX viewer setup progress lines for commands without their own progress. Pip installs use native output without setup heartbeats. |
In a source checkout the sample launchers and build_samples also read the consumer variables
OVCLASH_BACKEND, OVCLASH_INSTALL_ROOT, OVCLASH_SAMPLE_BUILD_ROOT and
OVCLASH_OVX_INCLUDE_DIR; Samples in a source checkout gives
their checkout defaults.
Troubleshooting#
Troubleshooting lists loader, version-mismatch and package configuration failures by their exact messages. These cases are specific to a source checkout:
Unknown option: <flag>from a build wrapper. The backend wrappers accept a fixed flag set and stop before building on anything else. The Windows wrappers also reject-Doptions. Wrapper flags lists the flags each platform accepts.ELF strip/GLIBC baseline contract failedduring a Linux install. The build ran on a host whose glibc or libstdc++ is newer than the manylinux_2_35 baseline. Delete the build tree (_build/compile/<backend>/ninja), whose cached compiler and objects are the host toolchain’s, and rebuild on Ubuntu 22.04 or another manylinux_2_35 compatible environment. For local work that will never be published, setSKIP_GLIBC_CHECK=1instead; it waives only this check. See Wrapper flags.error: ovstage install source_verified must be true for a dual gate(oropenusd) at the end of a two-backendtest_all. A Git command failed, or the index file thatgit rev-parse --git-path indexnames was missing, when that install was built, so its source is unknown. Check that Git works in the checkout (git resetrebuilds a missing index from HEAD) and run again. See Test and validate.The source identity changed since the last successful native buildduring--validate, an install or packaging. The source identity covers every file of the Git repository that no ignore rule excludes, not onlyovclash/. Something edited a file, created a new untracked file, rangit add, or committed or checked out after the build. While a validation runs, do none of these anywhere in the checkout, and keep editors and other tools from writing files there that are not ignored. The message lists the changed fields and the paths that differ. When it reportssource_verified: true -> falseinstead, a Git command failed and the sources may be unchanged: run again oncegit statusshows a settled checkout. A missing index file, the onegit rev-parse --git-path indexnames, also reports it;git resetrebuilds the index from HEAD and leaves the working tree as it is. Build provenance explains each field.The selected OVX include directory has no ovx/dlpack/dlpack.h, which the public <ovclash/ovclash.h> requires: <dir>when you configure ovclash itself.<ovclash/ovclash.h>includes<ovx/dlpack/dlpack.h>, and the install rule copies that header fromOVCLASH_OVX_INCLUDE_DIRinto the ovclashinclude/tree. PointOVCLASH_OVX_INCLUDE_DIRat a complete ovx include directory. A consumer that fails to compile that include has a different problem; see Troubleshooting.Could not find the ovclash suite shared library: neither OVCLASH_LIB nor OVCLASH_SUITE_LIB is set, ...withPYTHONPATHpointing atpython/. The checkout’spython/directory holds no build output beside the packages. SetOVCLASH_LIBto the absolute path of the install tree’s library, as Running the module from a source checkout shows.A consumer program exits with
0xc0000135(Windows) or127(Linux) beforemainwhile OpenUSD Python tests run. Those test runs temporarily replace the install tree’s OpenUSD library with a Python-enabled one. That library needspython312.dll(libpython3.12.so.1.0on Linux), so a native consumer started during the swap cannot load it. A*.ovclash_pyless_backupfile beside the OpenUSD library means that an interrupted run left the swap in place. Rerun those tests, which restore the backup first, or rename the backup over the swapped file.A Packman download fails with HTTP 403, and the
cloudfront.netURL it names answers with a page that reads403 ERROR,The request could not be satisfiedandRequest blocked(Generated by cloudfront (CloudFront)). The content delivery network that serves the packages refused the request, for example while its firewall limits anonymous downloads. The package is not missing and the checkout is not misconfigured. Wait and run the build again: it continues from the packages already in the Packman cache (PM_PACKAGES_ROOT, by default_build/deps/packman-cache; see Dependency sources), which are not downloaded again. If the block lasts for hours, report it with the URL that the error names.A Packman or pip download fails with a connection error, a proxy error or a timeout. The build then stops with
Failed to download <dependencies> (exit code: <n>)after Packman’s own error, or, for the ovstage wheel, withFailed to materialize ovstage from <source kind>: <source> (pip exit code <n>)after pip’s. The network blocks a host that the build needs. Allow HTTPS to these hosts:d4i3qtqj3r0z5.cloudfront.netandd2cerybs4newgl.cloudfront.netfor the Packman packages (the first redirects the PhysX SDK, the OpenUSD packages and the documentation tools to the second, so allowing only the first is not enough);bootstrap.packman.nvidia.comfor Packman and the Python it runs on, on the first run; andpypi.organdfiles.pythonhosted.orgfor the pinnedovstagewheel and the Python packages that the build and its tests install.
See also:
Backends: where the two backends differ.
Sentinel: how to read a failed correctness run.
Run KPI: KPI run failures, and KPI CPU admission for CPU placement and recovery.