mirror of
https://git.freebsd.org/ports.git
synced 2025-06-16 10:10:31 -04:00
C-Reduce still depends on devel/llvm80, and this is no longer compatible
with libc++ 14 or higher, since libc++ now requires support for the
__builtin_is_constant_evaluated() builtin function (see
1123100a16
).
As a crutch, add a small header which defines a constexpr
__builtin_is_constant_evaluated() function, and include that at the top
of every compiled file, using -include, whenever the base system clang
version is 14 or higher.
Approved by: swills (maintainer)
MFH: 2022Q1
47 lines
1.4 KiB
Makefile
47 lines
1.4 KiB
Makefile
PORTNAME= creduce
|
|
DISTVERSION= 2.10.0
|
|
CATEGORIES= devel
|
|
MASTER_SITES= http://embed.cs.utah.edu/creduce/
|
|
|
|
MAINTAINER= swills@FreeBSD.org
|
|
COMMENT= Produces small test cases
|
|
|
|
LLVM_VER= 80
|
|
BUILD_DEPENDS= llvm-config${LLVM_VER}:devel/llvm${LLVM_VER}
|
|
RUN_DEPENDS= llvm-config${LLVM_VER}:devel/llvm${LLVM_VER} \
|
|
topformflat:devel/delta \
|
|
astyle:devel/astyle \
|
|
p5-Benchmark-Timer>=0:devel/p5-Benchmark-Timer \
|
|
p5-Exporter-Lite>=0:devel/p5-Exporter-Lite \
|
|
p5-File-Which>=0:sysutils/p5-File-Which \
|
|
p5-Regexp-Common>=0:textproc/p5-Regexp-Common \
|
|
p5-Sys-CPU>=0:devel/p5-Sys-CPU \
|
|
p5-Getopt-Tabular>=0:devel/p5-Getopt-Tabular
|
|
|
|
BROKEN_FreeBSD_12_powerpc64= fails to configure: cannot compile and link test program with selected LLVM
|
|
|
|
GNU_CONFIGURE= yes
|
|
CONFIGURE_ENV= LLVM_CONFIG=${LOCALBASE}/bin/llvm-config${LLVM_VER} \
|
|
CC=${LOCALBASE}/bin/clang${LLVM_VER} \
|
|
CXX=${LOCALBASE}/bin/clang++${LLVM_VER} \
|
|
CPP=${LOCALBASE}/bin/clang-cpp${LLVM_VER}
|
|
|
|
USES= autoreconf compiler gmake libtool perl5
|
|
|
|
CFLAGS_powerpc64= -mabi=elfv2
|
|
|
|
.include <bsd.port.options.mk>
|
|
|
|
.if ${ARCH} == powerpc
|
|
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>
|