diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2022-02-13 14:05:12 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2022-02-13 18:50:06 +0000 |
commit | 782745a8ef207fdaaaa6020ed51aea65f0b17437 (patch) | |
tree | b6fdc7c4167f22e051c360894afeb02aed14a087 /devel | |
parent | cf8d1a0e6c06f75117f54eb9bf8a28b850537d90 (diff) | |
download | ports-782745a8ef207fdaaaa6020ed51aea65f0b17437.tar.gz ports-782745a8ef207fdaaaa6020ed51aea65f0b17437.zip |
Diffstat (limited to 'devel')
-rw-r--r-- | devel/creduce/Makefile | 10 | ||||
-rw-r--r-- | devel/creduce/files/builtin_is_constant_evaluated.h | 1 |
2 files changed, 10 insertions, 1 deletions
diff --git a/devel/creduce/Makefile b/devel/creduce/Makefile index d0cf2295c97f..ec9dfa3a841c 100644 --- a/devel/creduce/Makefile +++ b/devel/creduce/Makefile @@ -26,7 +26,7 @@ CONFIGURE_ENV= LLVM_CONFIG=${LOCALBASE}/bin/llvm-config${LLVM_VER} \ CXX=${LOCALBASE}/bin/clang++${LLVM_VER} \ CPP=${LOCALBASE}/bin/clang-cpp${LLVM_VER} -USES= autoreconf gmake libtool perl5 +USES= autoreconf compiler gmake libtool perl5 CFLAGS_powerpc64= -mabi=elfv2 @@ -36,4 +36,12 @@ CFLAGS_powerpc64= -mabi=elfv2 LLD_UNSAFE= yes .endif +.include <bsd.port.pre.mk> + +# Detect base system libc++ >= 14 by checking for COMPILER_VERSION. +# Not really the ideal way, but it should work. +.if ${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 140 +CXXFLAGS+= -include ${FILESDIR}/builtin_is_constant_evaluated.h +.endif + .include <bsd.port.mk> diff --git a/devel/creduce/files/builtin_is_constant_evaluated.h b/devel/creduce/files/builtin_is_constant_evaluated.h new file mode 100644 index 000000000000..2775e8fa1bf3 --- /dev/null +++ b/devel/creduce/files/builtin_is_constant_evaluated.h @@ -0,0 +1 @@ +constexpr bool __builtin_is_constant_evaluated() { return false; } |