-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
libc: update macOS headers to macOS 12.0 Monterey #10202
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
updates libc headers for macos to reflect the latest version present on macOS 12 Monterey This is the result of running the following after ziglang/fetch-them-macos-headers#15: ``` rm -rf lib/libc/include/any-macos-any lib/libc/include/x86_64-macos-gnu lib/libc/include/aarch64-macos-gnu fetch_them_macos_headers generate ``` Fixes #10200 Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
Although I am confident this PR does what it describes, I wanted to call out a question: is this the right solution? #10200 makes a clear case for why we need the latest macOS libc headers (without them, we cannot link frameworks from the latest macOS SDK when cross compiling, only when building natively as Zig uses the system libc in that case I think) At the same time Andrew makes a case in this issue for why we should only use the minimum supported macOS version's headers. A different solution might be to say something like this:
|
I believe I no longer need this change for my work, I can stick on the older version of the macOS SDK I believe, so we can defer making a decision here. I think the issue is still valid and worth figuring out, however. I see these potential paths forward:
|
Thanks for the PR and issue @slimsag. I am fine with trying to keep macOS libc headers at the latest version given that Apple encourages their users to update their OSes to the latest possible version every year. That said, this means the libc headers we ship will be incompatible with anything but the latest sysroot (well, they might work with the previous sets but we can never guarantee that I guess?). I think I am still fine with that personally. Also, if anyone would like to target an older version of macOS from a foreign host they'd just need to provide the entire sysroot including the libc headers (which are part of every macOS SDK anyhow). Finally, as you already pointed out, targeting the latest macOS version is the simplest thing to maintain on our side too. I'd like to hear @andrewrk's opinion on this before committing to any one particular strategy. |
Oh and also, sticking to the latest libc headers would go hand-in-hand in us tracking the latest LLVM release I guess. |
Conversation shifted to over here: ziglang/fetch-them-macos-headers#15 (comment) |
Superseded by #10215, closing. |
updates libc headers for macos to reflect the latest version present on macOS 12 Monterey
This is the result of running the following after ziglang/fetch-them-macos-headers#15:
Fixes #10200
Signed-off-by: Stephen Gutekanst stephen@hexops.com