Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: support macos minimum version #377

Merged
merged 1 commit into from
May 10, 2024

Conversation

ruwi-next
Copy link
Contributor

Hi,

Summary

When building for macOS it is often required to set --macos_minimum_os to specify the minimum os version to build for. Running a binary on an os built for a later os could mean it could crash when trying to resolve symbols not in this os release. Not setting this will default to the build machine's os version.

Using this with rules_graalvm does not work as you can see when setting --macos_minimum_os=11.0 and running otool -l ./bin | grep -B1 -A3 MIN_MAC.

The solution is to set env var MACOSX_DEPLOYMENT_TARGET for xcode to pick up as documented here https://github.com/clj-easy/graal-docs?tab=readme-ov-file#targeting-a-minimum-macos-version

Thanks

@ruwi-next ruwi-next requested a review from sgammon as a code owner April 29, 2024 08:17
Signed-off-by: Ruairidh Williamson <ruairidh.williamson@nextdlp.com>
Copy link

sonarcloud bot commented Apr 29, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

Copy link
Owner

@sgammon sgammon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @ruwi-next, Thank you for the clear explanation and PR! 👍

@sgammon sgammon added bug Something isn't working platform:darwin Issues relating to macOS labels May 10, 2024
@sgammon sgammon merged commit a5c9142 into sgammon:main May 10, 2024
75 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working platform:darwin Issues relating to macOS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants