Add missing <cstdint> include in ClockDelta.h for GCC 15#9
Conversation
|
|
Verification on real GCC 15I reproduced the original failure from OpenMoonRay/openmoonray#230 and confirmed the fix in a clean Fedora 42 container (GCC 15.2.1), so the change is verified against the exact compiler version reported in the issue rather than just by inspection. Method
ResultGCC version Test 1 — ORIGINAL header (no The Test 2 — PATCHED header (this PR) — Only the stub-related Conclusion
|
ClockDelta.h uses uint64_t in the declaration of analyzeRoundTripTimeDelta() but does not include <cstdint>. This previously compiled because older libstdc++ leaked the definition transitively via other standard headers. GCC 15 / newer libstdc++ no longer does, so the build fails with: ClockDelta.h:60:44: error: 'uint64_t' has not been declared ClockDelta.h:61:44: error: 'uint64_t' has not been declared ClockDelta.h:62:44: error: 'uint64_t' has not been declared Fixes OpenMoonRay/openmoonray#230 Signed-off-by: William Reiske <wreiske@mieweb.com>
52e0432 to
94d2019
Compare
Summary
ClockDelta.husesuint64_tin the declaration ofanalyzeRoundTripTimeDelta()(lines 60–62) but does not include<cstdint>. This previously compiled because older libstdc++ leaked the definition transitively via other standard headers. GCC 15 / newer libstdc++ no longer does, so the build fails with:Fix
Add
#include <cstdint>toClockDelta.h. This is the canonically correct header for the fixed-width integer typedefs and makes the header self-contained.Testing
Before this change, on GCC 15 (e.g. Arch Linux, Fedora 41+):
After this change, the header compiles cleanly and the full OpenMoonRay build progresses past
mcrt_dataioon GCC 15.Related
Fixes OpenMoonRay/openmoonray#230
The header builds fine on the toolchains DreamWorks ships (older libstdc++) because they happen to leak
<cstdint>transitively; this change is a strict tightening that does not affect those builds.