feat(sys): allow relocating the CMake build dirs via environment variables - #183
Open
LeonarddeR wants to merge 1 commit into
Open
feat(sys): allow relocating the CMake build dirs via environment variables#183LeonarddeR wants to merge 1 commit into
LeonarddeR wants to merge 1 commit into
Conversation
…ables WXDRAGON_SYS_BUILD_DIR and WXWIDGETS_BUILD_DIR override the two build directories otherwise hardcoded at the profile level of the target directory, mirroring the existing WXWIDGETS_DIR override for the source. All three variables now emit rerun-if-env-changed so a change retriggers the build script. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UZyiWydqoemtUSY5ZryoFB
LeonarddeR
marked this pull request as ready for review
August 15, 2026 06:44
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.
Closes #182.
The build script compiles wxWidgets and the wrapper library through CMake. It writes both build trees to fixed directories at the profile level of cargo's target directory. The download location of the wxWidgets source is already configurable through the
WXWIDGETS_DIRenvironment variable, but the two build directories are not configurable at all.Continuous integration caches need these trees to be relocatable. The common Rust cache action cleans unrecognized directories out of the target directory before saving, so the fixed locations force a full wxWidgets rebuild on every CI run. Pointing the trees at a directory the cache preserves avoids that without consumers having to hard-code the crate's internal paths.
This change makes both directories configurable, following the pattern
WXWIDGETS_DIRalready established:WXDRAGON_SYS_BUILD_DIRoverrides the wrapper's build directory (default:wxdragon_sys_cmake_build).WXWIDGETS_BUILD_DIRoverrides the wxWidgets build directory (default:wxwidgets_cmake_build).When a variable is unset, the previous location is used, so existing builds are unaffected.
The build script now also emits
rerun-if-env-changedfor all three variables, including the pre-existingWXWIDGETS_DIR, so changing one of them retriggers the build script instead of silently reusing the old location.🤖 Generated with Claude Code
https://claude.ai/code/session_01UZyiWydqoemtUSY5ZryoFB