freebsd-dev/lib/libclang_rt/Makefile.inc
Dimitry Andric d65cd7a57b Merge llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp
llvmorg-10.0.1-rc1-0-gf79cd71e145 (aka 10.0.1 rc1).

MFC after:	3 weeks
2020-05-23 10:32:18 +00:00

45 lines
1.0 KiB
Makefile

# $FreeBSD$
.include <bsd.compiler.mk>
# armv[67] is a bit special since we allow a soft-floating version via
# CPUTYPE matching *soft*. This variant may not actually work though.
.if ${MACHINE_ARCH:Marmv[67]*} != "" && \
(!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "")
CRTARCH?= armhf
.else
CRTARCH?= ${MACHINE_ARCH:C/amd64/x86_64/}
.endif
CRTSRC= ${SRCTOP}/contrib/llvm-project/compiler-rt
.PATH: ${CRTSRC}/lib
CLANGDIR= /usr/lib/clang/10.0.1
LIBDIR= ${CLANGDIR}/lib/freebsd
SHLIBDIR= ${LIBDIR}
NO_PIC=
MK_PROFILE= no
WARNS?= 0
SSP_CFLAGS=
CFLAGS+= -DNDEBUG
CFLAGS+= -DHAVE_RPC_XDR_H=0
CFLAGS+= -DSANITIZER_SUPPORTS_WEAK_HOOKS=0
CFLAGS+= -DUBSAN_CAN_USE_CXXABI
CFLAGS+= ${PICFLAG}
CFLAGS+= -fno-builtin
CFLAGS+= -fno-exceptions
CXXFLAGS+= -fno-rtti
.if ${COMPILER_TYPE} == clang
CFLAGS+= -fno-sanitize=safe-stack
.endif
CFLAGS+= -fno-stack-protector
CFLAGS+= -funwind-tables
CXXFLAGS+= -fvisibility-inlines-hidden
CXXFLAGS+= -fvisibility=hidden
CFLAGS+= -I${CRTSRC}/include
CFLAGS+= -I${CRTSRC}/lib
CXXSTD= c++14