From 9c0d9f2ac18ab2c9e3b8e5b670baf2f97dc88e28 Mon Sep 17 00:00:00 2001 From: ZhilkinSerg Date: Fri, 28 Feb 2020 15:45:42 +0300 Subject: [PATCH] Revert "Allow using different standard library through USE_LIBCXX" --- Makefile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 416de9661421c..d4d87addffa76 100644 --- a/Makefile +++ b/Makefile @@ -219,12 +219,6 @@ ifneq ($(findstring BSD,$(OS)),) BSD = 1 endif -# Which standard library to use (e.g. libstdc++ or libc++) -ifdef USE_LIBCXX - OTHERS += -stdlib=$(USE_LIBCXX) - LDFLAGS += -stdlib=$(USE_LIBCXX) -endif - # This sets CXX and so must be up here ifdef CLANG # Allow setting specific CLANG version @@ -233,6 +227,13 @@ ifdef CLANG else CLANGCMD = $(CLANG) endif + ifeq ($(NATIVE), osx) + USE_LIBCXX = 1 + endif + ifdef USE_LIBCXX + OTHERS += -stdlib=libc++ + LDFLAGS += -stdlib=libc++ + endif ifdef CCACHE CXX = CCACHE_CPP2=1 ccache $(CROSS)$(CLANGCMD) LD = CCACHE_CPP2=1 ccache $(CROSS)$(CLANGCMD)