Skip to content

Fix warnings caused by not defining the feature macros.#2606

Merged
FranzBusch merged 1 commit intoapple:mainfrom
al45tair:musl-support
Dec 5, 2023
Merged

Fix warnings caused by not defining the feature macros.#2606
FranzBusch merged 1 commit intoapple:mainfrom
al45tair:musl-support

Conversation

@al45tair
Copy link
Copy Markdown
Contributor

@al45tair al45tair commented Dec 5, 2023

We should define _GNU_SOURCE for all of the C modules, really. Relying on features.h doesn't work for modular headers.

Motivation:

Unfortunately, the defaults in <features.h> don't really work for modular headers, so we need to define _GNU_SOURCE in a couple more places (mostly to avoid a compiler warning).

Modifications:

Add _GNU_SOURCE in a couple of places.

Result:

There shouldn't be a huge impact; we won't generate compiler warnings about <features.h> in a couple of places where we were doing before (assuming modular headers).

We should define `_GNU_SOURCE` for all of the C modules, really.
Relying on `features.h` doesn't work for modular headers.
@al45tair
Copy link
Copy Markdown
Contributor Author

al45tair commented Dec 5, 2023

@swift-server-bot test this please

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

Labels

🔨 semver/patch No public API change.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants