Skip to content

Fix missing macro definitions in apple-apple-apple build.#590

Closed
iamleeg wants to merge 1 commit intognustep:masterfrom
iamleeg:iamleeg/fix-macos-build
Closed

Fix missing macro definitions in apple-apple-apple build.#590
iamleeg wants to merge 1 commit intognustep:masterfrom
iamleeg:iamleeg/fix-macos-build

Conversation

@iamleeg
Copy link
Copy Markdown
Contributor

@iamleeg iamleeg commented Mar 19, 2026

Some GNUstep-specific macros like GS_FOR_IN and GS_FOR_END were defined in Foundation headers, like Foundation/NSEnumerator.h. On macOS, these headers don't get found because they shadow the Apple headers with the same name, so the build fails. This PR pulls those macros into files in GNUstepBase and imports the new files from their old locations.

The base additions library didn't build on macOS (26.3.1 with Xcode 26.3) before these changes, and now does.

Signed-off-by: Graham Lee <grahamlee@acm.org>
@iamleeg iamleeg requested a review from rfm as a code owner March 19, 2026 12:08
Copy link
Copy Markdown
Member

@fredkiefer fredkiefer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@rfm
Copy link
Copy Markdown
Contributor

rfm commented Mar 30, 2026

Thanks, I've gone a different way because the fast enumeration changes were really a much more extensive work in progress, and I hadn't realised that I'd left the OSX base additions build in a broken state.
The code changes as a whole are supposed to make fast enumeration available on all platforms (using native compiler/runtime support where possible) and to make it possible to write portable code (using the macros) without having to include additional headers.
I hope that's all working now, and in particular that it is working on OSX and windows. At least the OSX code built for me last time I tried (though I didn't actually run tests).

@rfm rfm closed this Mar 30, 2026
@rfm
Copy link
Copy Markdown
Contributor

rfm commented Mar 30, 2026

I forgot to say: thanks very much for spotting the issue, and pointing it out. If you hadn't done that I might have completely forgotten it and left it for ages.

@iamleeg
Copy link
Copy Markdown
Contributor Author

iamleeg commented Mar 30, 2026

Great, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants