Skip to content

Switching to ninja generator#76

Open
dstover11 wants to merge 6 commits into
mainfrom
stover/builder-update-fix
Open

Switching to ninja generator#76
dstover11 wants to merge 6 commits into
mainfrom
stover/builder-update-fix

Conversation

@dstover11

Copy link
Copy Markdown
Contributor

Description

As of mid June, Windows builders for github actions now default to visual studio 2026. Switching to ninja generator to hopefully resolve the issues that stem from this.

dstover11 and others added 6 commits July 15, 2026 14:59
OpenUSD's build_usd.py vendors zlib 1.2.13, which fails to compile under
Clang 17 (Xcode 16.3+) due to a TARGET_OS_MAC macro bug. macOS-15 and
macos-26 runners only ship Xcode versions past that threshold, so
pre-seed a Homebrew-built zlib before build_usd.py runs; it skips
building its own zlib if include/zlib.h already exists in the install dir.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
boostorg.jfrog.io stopped serving release archives (returns JFrog's
marketing landing page with HTTP 200), causing build_usd.py to
download an unparsable "archive" and fail with "unrecognized archive
file type".

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Two toolchain-version failures where the newest CI runner images have
outrun USD 24.11's pinned dependencies:

- windows-2025: Boost 1.78.0's bootstrap.bat auto-detects the compiler
  via `vswhere -latest`, which now resolves to a VS 18 (2026) preview its
  build engine rejects ("Unknown toolset: vcunk"). Patch build_usd.py to
  force bootstrap.bat's toolset argument to vc143, matching the
  toolset=msvc-14.3 that b2 already uses.

- macOS-15 / macos-26: libpng 1.6.38's pngpriv.h includes the Classic
  Mac OS <fp.h> header when TARGET_OS_MAC is defined; the Xcode 26 /
  AppleClang 21 SDK defines it, but <fp.h> no longer ships, failing with
  "fatal error: 'fp.h' file not found". Append -D__MATH_H__ to libpng's
  CMAKE_C_FLAGS so the include is skipped (genout.cmake forwards the flag
  to the preprocessing step that was failing).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The previous -D__MATH_H__ attempt skipped the missing <fp.h> include but
left png.c without math declarations: pngpriv.h only includes <math.h> in
the #else branch, which is unreachable when TARGET_OS_MAC is defined, so
modf/floor/pow/frexp became undeclared. Force-include <math.h> instead,
which (as pngpriv.h's own comment describes) defines the guard that skips
<fp.h> while supplying the math declarations png.c needs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The prior 'bootstrap.bat vc143' patch was ineffective: bootstrap.bat calls
build.bat with no arguments, so the b2 engine build always auto-detects.
Boost 1.78.0's vswhere_usability_wrapper.cmd queries "[18.0,19.0)" first and
short-circuits, so on windows-2025 (which ships both VS 2022 and VS 18/2026)
it finds VS 18, sets VSUNKCOMNTOOLS, and never sets VS170COMNTOOLS;
guess_toolset.bat then falls to B2_TOOLSET=vcunk and aborts.

guess_toolset.bat checks VS170COMNTOOLS before VSUNKCOMNTOOLS, so pre-seed it
with the installed VS 2022 path (located via vswhere) to make Boost pick
vc143 -- the toolset windows-2022 already builds Boost with and the one
build_usd.py drives b2 with. Also pin ilammy/msvc-dev-cmd to VS 2022 so cl.exe
is v143, matching that toolset. Replaces the ineffective bootstrap patch.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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