Skip to content

Remove unnecessary build flags on windows. - #15

Merged
Morgan2010 merged 1 commit into
mainfrom
windows-flags
Nov 3, 2026
Merged

Morgan2010 merged 1 commit into
mainfrom
windows-flags

Conversation

@Morgan2010

Copy link
Copy Markdown
Contributor

This pull request simplifies the way the MachineGenerator executable target is defined in Package.swift. The previous approach used conditional compilation to define the target differently for Windows and other platforms. The new implementation unifies the target definition and uses the swiftSettings property to apply platform-specific compiler flags directly within the target declaration.

Target definition simplification:

  • Removed the use of #if os(Windows) conditional compilation for defining the MachineGenerator target, consolidating both Windows and non-Windows logic into a single target declaration.
  • Moved the swiftSettings for Windows (-parse-as-library) directly into the .executableTarget declaration using the .when(platforms: [.windows]) modifier, ensuring platform-specific flags are applied cleanly.

Codebase cleanup:

  • Removed redundant or unnecessary swiftSettings from the GeneratorCommands target, streamlining the configuration.

@Morgan2010
Morgan2010 merged commit b09e2c7 into main Nov 3, 2026
25 checks passed
@Morgan2010
Morgan2010 deleted the windows-flags branch November 3, 2026 23:27
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