https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=216229
Dimitry Andric <d...@freebsd.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |d...@freebsd.org Assignee|freebsd-toolchain@FreeBSD.o |d...@freebsd.org |rg | Status|New |In Progress --- Comment #1 from Dimitry Andric <d...@freebsd.org> --- (In reply to Mark Millard from comment #0) > So the lines from /usr/src/lib/clang/llvm.build.mk for CFLAGS: > > CFLAGS+= -I${SRCTOP}/lib/clang/include > CFLAGS+= -I${LLVM_SRCS}/include > CFLAGS+= -DLLVM_ON_UNIX > CFLAGS+= -DLLVM_ON_FREEBSD > CFLAGS+= -D__STDC_LIMIT_MACROS > CFLAGS+= -D__STDC_CONSTANT_MACROS > #CFLAGS+= -DNDEBUG > . . . > CFLAGS+= -DLLVM_DEFAULT_TARGET_TRIPLE=\"${TARGET_TRIPLE}\" > CFLAGS+= -DLLVM_HOST_TRIPLE=\"${BUILD_TRIPLE}\" > CFLAGS+= -DDEFAULT_SYSROOT=\"${TOOLS_PREFIX}\" > > do not contribute to the C++ compiles for libllvmminimal. This is incorrect: in share/mk/sys.mk, CXXFLAGS are derived from CFLAGS, with the following rule: CXXFLAGS ?= ${CFLAGS:N-std=*:N-Wnested-externs:N-W*-prototypes:N-Wno-pointer-sign:N-Wold-style-definition} E.g. -std flags and some others are filtered out. > The lack of -I definitions for C++ ends up with build failures > such as below (from a first-time kernel-toolchain example): I have seen such failures before, and they were almost always caused by setting CFLAGS or CXXFLAGS incorrectly in /etc/make.conf, e.g. doing: CFLAGS= -DFOO CXXFLAGS= -DBAR while one should use the += operator instead, e.g.: CFLAGS+= -DFOO CXXFLAGS+= -DBAR Can you please post your make.conf? -- You are receiving this mail because: You are the assignee for the bug. _______________________________________________ freebsd-toolchain@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-toolchain To unsubscribe, send any mail to "freebsd-toolchain-unsubscr...@freebsd.org"