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 compile error when targeting macOS version earlier and macOS 10.12 #478

Merged
merged 1 commit into from
Mar 21, 2021

Conversation

SamWindell
Copy link
Contributor

Description

Doctest does not compile if you are targeting a macOS version earlier than 10.12. This patch fixes that.

std::uncaught_exceptions only available on 10.12 and above (despite it being in the standard library). It results in the compiler sending an error. Targeting an earlier version of macOS is done with the flag -mmacosx-version-min=x, where x is something like 10.9.

When you use the -mmacosx-version-min flag, a define is set: __MAC_OS_X_VERSION_MIN_REQUIRED. The patch checks against this number.

GitHub Issues

Closes #466

@onqtam
Copy link
Member

onqtam commented Mar 21, 2021

Thanks!

@onqtam onqtam merged commit 2492389 into doctest:dev Mar 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants