Skip to content

Add C11 compiler detection (optional) and <stdatomic.h> detection - #989

Open
NWilson wants to merge 2 commits into
mainfrom
user/niwilson/add-c11-detection
Open

NWilson wants to merge 2 commits into
mainfrom
user/niwilson/add-c11-detection

Conversation

@NWilson

@NWilson NWilson commented Sep 16, 2026

Copy link
Copy Markdown
Member
  • The minimum C level remains C99, but C11 is detected and used if available. Both CMake and Autoconf detect it. Bazel cannot detect it, so assumes it. Zig forces use of C11, which is safe as it is modern.
  • stdatomic.h is detected in CMake and Autoconf, and assumed to be available on non-Windows platforms by Bazel and Zig.
  • Autoconf minimum version is raised to 2.71 (Ubuntu 22.04!). This should not impact downstream clients, since the tarballs and release tags have the Autoconf output included, and clients have never needed to run Autoconf themselves.

I am expecting in future to make (conditional!) use of some C11 features, so I'd like to get this change in, while it's a no-op, in order to probe and validate for support.

NWilson and others added 2 commits September 16, 2026 11:20
* The minimum C level remains C99, but C11 is detected and used if
  available. Both CMake and Autoconf detect it. Bazel cannot detect it,
  so assumes it. Zig forces use of C11, which is safe as it is modern.
* stdatomic.h is detected in CMake and Autoconf, and assumed to be
  available on non-Windows platforms by Bazel and Zig.
* Autoconf minimum version is raised to 2.71 (Ubuntu 22.04!). This
  should not impact downstream clients, since the tarballs and release
  tags have the Autoconf output included, and clients have never needed
  to run Autoconf themselves.
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