Skip to content

Mono compilation fails with Xcode 26 toolchain: gnu-folding-constant #120007

@vcsjones

Description

@vcsjones

On macOS 26 with Xcode 26 developer tools, run

./build.sh -s mono+libs+libs.tests -rc release /p:BundleXunitRunner=true

There are a few compilation warnings that get turned in to errors:

  In file included from /Users/vcsjones/Projects/runtime/artifacts/obj/mono/osx.arm64.Release/mono/mini/CMakeFiles/eventpipe-mono-objects.dir/Unity/unity_0_c.c:46:
  /Users/vcsjones/Projects/runtime/src/native/eventpipe/ep-session.c:770:25: error: variable length array folded to constant array as an extension [-Werror,-Wgnu-folding-constant]
    770 |         struct iovec static_io[max_static_io_capacity];
        |                                ^~~~~~~~~~~~~~~~~~~~~~
  /Users/vcsjones/Projects/runtime/src/native/eventpipe/ep-session.c:858:33: error: variable length array folded to constant array as an extension [-Werror,-Wgnu-folding-constant]
    858 |         uint8_t extension_activity_ids[extension_activity_ids_max_len];
        |                                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions