From 829455187c5ec75bd139a9d6c04399548f733237 Mon Sep 17 00:00:00 2001 From: Nikolai Lifanov Date: Fri, 22 Feb 2019 13:16:28 -0800 Subject: [PATCH] specify -stdlib=libc++ for darwin It's not the default with older Apple clang builds and without it c++11 features don't work on at least OS X 10.7: ./src/core/lib/gprpp/ref_counted.h:28:10: fatal error: 'atomic' file not found #include ^~~~~~~~ I manually tested it on macOS 10.11 image and there was not a regression. This should fix the "Artifact Build MacOS (internal CI)" test failure. --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 1992976198d..db6e2173da3 100644 --- a/setup.py +++ b/setup.py @@ -159,7 +159,7 @@ if EXTRA_ENV_COMPILE_ARGS is None: elif "linux" in sys.platform: EXTRA_ENV_COMPILE_ARGS += ' -std=gnu99 -fvisibility=hidden -fno-wrapv -fno-exceptions' elif "darwin" in sys.platform: - EXTRA_ENV_COMPILE_ARGS += ' -fvisibility=hidden -fno-wrapv -fno-exceptions' + EXTRA_ENV_COMPILE_ARGS += ' -stdlib=libc++ -fvisibility=hidden -fno-wrapv -fno-exceptions' EXTRA_ENV_COMPILE_ARGS += ' -DPB_FIELD_32BIT' if EXTRA_ENV_LINK_ARGS is None: