Skip to content

Recognize the Darwin platform alias as macOS - #4

Merged
riccardobl merged 1 commit into
NostrGameEngine:masterfrom
toaster0123:fix/darwin-platform-detection-20261005
Oct 5, 2026
Merged

riccardobl merged 1 commit into
NostrGameEngine:masterfrom
toaster0123:fix/darwin-platform-detection-20261005

Conversation

@toaster0123

Copy link
Copy Markdown
Contributor

Problem

The Windows check uses contains("win"), which also matches darwin. Both the runtime loader and core Gradle native-project selection therefore take the Windows branch for the Darwin alias, making the subsequent explicit Darwin/macOS branch unreachable.

Change

Use startsWith("win") in both selectors and add a regression covering Linux, Windows 11, Mac OS X, and Darwin. The regression restores all changed system properties.

Scope and severity

This is a compatibility-alias correction. The usual Mac OS X value already worked; this review did not demonstrate a supported macOS JVM reporting Darwin. It should not be described as a general macOS loading failure.

Validation

  • Original selector reproduced Darwin -> windows
  • New JUnit platform-detection regression passes all four labels
  • Benign locally compiled fixture library passes bundled resource/JAR loading, explicit file/directory overrides, java.library.path fallback, and normal-exit extraction cleanup on Linux
  • Java source/target 8 compilation and git diff --check passed

Limits

The Gradle selector was source-reviewed, not executed with Gradle. Full Gradle/CMake and platform CI were not run locally. No macOS or Windows runtime was available; mocked system properties exercise classification only.

@riccardobl
riccardobl marked this pull request as ready for review October 5, 2026 20:04
@riccardobl
riccardobl merged commit 273a92b into NostrGameEngine:master Oct 5, 2026
14 of 18 checks passed
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.

2 participants