libc:libcxx: add support for libcxxabi.

libcxxabi is either-or select with glibcxx.

Change-Id: I4fbea19f0648ddc318379dd43bac8406f7c86927
This commit is contained in:
zhuyanlin 2021-08-19 17:13:43 +08:00 committed by Xiang Xiao
parent 7f48d13c47
commit f2fe51c22d

View File

@ -40,9 +40,15 @@ distclean::
$(Q) $(DIRUNLINK) $(TOPDIR)/include/libcxx
$(call DELDIR, libcxx)
CXXFLAGS += ${shell $(DEFINE) "$(CC)" __GLIBCXX__}
CXXFLAGS += ${shell $(DEFINE) "$(CC)" _LIBCPP_BUILDING_LIBRARY}
ifeq ($(CONFIG_LIBCXXABI), y)
CXXFLAGS += ${shell $(DEFINE) "$(CC)" LIBCXX_BUILDING_LIBCXXABI}
CXXFLAGS += -I $(TOPDIR)/libs/libxx/libcxxabi/include
else
CXXFLAGS += ${shell $(DEFINE) "$(CC)" __GLIBCXX__}
endif
# Workaround the following warning with "c++ (Ubuntu 9.3.0-10ubuntu2) 9.3.0"
#
# libcxx/src/barrier.cpp: In constructor 'std::__1::__barrier_algorithm_base::__barrier_algorithm_base(ptrdiff_t&)':