Make the build more clang friendly
This commit is contained in:
@@ -593,7 +593,7 @@ BEGIN_AS_NAMESPACE
|
||||
template<typename T>
|
||||
asUINT asGetTypeTraits()
|
||||
{
|
||||
#if defined(_MSC_VER) || defined(_LIBCPP_TYPE_TRAITS) || (__GNUC__ >= 5)
|
||||
#if defined(_MSC_VER) || defined(_LIBCPP_TYPE_TRAITS) || (__GNUC__ >= 5) || defined(__clang__)
|
||||
// MSVC, XCode/Clang, and gnuc 5+
|
||||
// C++11 compliant code
|
||||
bool hasConstructor = std::is_default_constructible<T>::value && !std::is_trivially_default_constructible<T>::value;
|
||||
|
||||
@@ -35,7 +35,11 @@ else
|
||||
CXXFLAGS += -DNDEBUG
|
||||
endif
|
||||
ifndef NLTO
|
||||
ifeq (,$(findstring g++, $(CC)))
|
||||
CXXFLAGS += -flto=6
|
||||
else
|
||||
CXXFLAGS += -flto=thin
|
||||
endif
|
||||
else
|
||||
CXXFLAGS += -fno-lto
|
||||
endif
|
||||
|
||||
Reference in New Issue
Block a user