Build fails on macOS 15 SDK: MTLGPUFamilyMetal4 undeclared
- Dominant language
- C
- Stars
- 2.7k
- Forks
- 211
- PR merge metrics
- No merged PRs in 30d
Description
h3_metal.m:43:51: error: use of undeclared identifier 'MTLGPUFamilyMetal4'; did you mean 'MTLGPUFamilyMetal3'?
43 | info->metal4 = [device supportsFamily:MTLGPUFamilyMetal4] ? 1 : 0;
| ^~~~~~~~~~~~~~~~~~
| MTLGPUFamilyMetal3
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Metal.framework/Headers/MTLDevice.h:222:5: note: 'MTLGPUFamilyMetal3' declared here
222 | MTLGPUFamilyMetal3 API_AVAILABLE(macos(13.0), ios(16.0)) = 5001,
| ^
1 error generated.
make: *** [h3_metal.o] Error 1
make: *** Waiting for unfinished jobs....
Please modify lines 42-44 of h3.c/h3_metal.m as follows:
#if defined(__MAC_26_0)
if (@available(macOS 26.0, *)) {
info->metal4 = [device supportsFamily:MTLGPUFamilyMetal4] ? 1 : 0;
}
#endif
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with lines 42-44 in h3.c and h3_metal.m, then inspect the surrounding Metal capability detection and the macOS SDK availability macros. Build h3.c on macOS 15 to confirm the undeclared-identifier error is gone, and verify that Metal4 detection remains guarded for SDKs that define it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, macos
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 88/100