Skip to content

Add a check example using MacOSX11.3 SDK#1077

Open
remlapmot wants to merge 1 commit into
r-lib:v2-branchfrom
remlapmot:add-check-strict-includes-example
Open

Add a check example using MacOSX11.3 SDK#1077
remlapmot wants to merge 1 commit into
r-lib:v2-branchfrom
remlapmot:add-check-strict-includes-example

Conversation

@remlapmot
Copy link
Copy Markdown
Contributor

I recently took on maintaining an R package with some C++ code. I did some tinkering, all my checks using the existing r-lib/actions checked passed (and checks with rhub) but after being accepted onto CRAN I obtained installation errors on the r-release-macos-x86_64, r-oldrel-macos-arm64, and r-oldrel-macos-x86_64 CRAN machines.

It turns out those CRAN machines have this 11.3 SDK installed which has very strict rules about specifying #includes.

In this I have specified the macos-15/macos-15-intel runners because there is no macos-11 runner. Those CRAN machines don't run on macos 15 (I guess they have macOS 11) but that doesn't seem to matter - it's just the use of this older SDK. This workflow recreates the errors I received from those 3 CRAN machines for my slightly slack code.

Even if you don't take this, I thought this might be helpful in the history of the repo to others.

This SDK is installed on CRAN's r-release-macos-x86_64, r-oldrel-macos-arm64, r-oldrel-macos-x86_64 machines, where missing explicit C++ standard library includes cause build failures.
@codecov
Copy link
Copy Markdown

codecov Bot commented May 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.33%. Comparing base (2e3959d) to head (0ae1d51).

Additional details and impacted files
@@            Coverage Diff             @@
##           v2-branch    #1077   +/-   ##
==========================================
  Coverage      83.33%   83.33%           
==========================================
  Files              3        3           
  Lines             12       12           
==========================================
  Hits              10       10           
  Misses             2        2           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@gaborcsardi
Copy link
Copy Markdown
Member

gaborcsardi commented May 18, 2026

Thanks, it would be great to have this in some form!

I think it is not ideal to have a separate workflow for this, but it could be a separate action, or it could be an option for setup-r.

One issue is that we don't want to download the tools from an untrusted repository. Ideally we'd download them from the official Apple URL.

@gaborcsardi gaborcsardi added the feature a feature request or enhancement label May 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature a feature request or enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants