Dimitry Andric <d...@freebsd.org> writes: > Author: dim > Date: Tue Sep 21 21:41:45 2010 > New Revision: 212979 > URL: http://svn.freebsd.org/changeset/base/212979 [...] > Modified: head/gnu/lib/libobjc/Makefile > ============================================================================== > --- head/gnu/lib/libobjc/Makefile Tue Sep 21 21:07:46 2010 > (r212978) > +++ head/gnu/lib/libobjc/Makefile Tue Sep 21 21:41:45 2010 > (r212979) > @@ -16,9 +16,7 @@ SRCS= archive.c class.c encoding.c gc.c > selector.c sendmsg.c thr.c thr-objc.c exception.c > > # XXX: clang cannot compile libobjc yet > -.if ${CC:T:Mclang} == "clang" > -CC=gcc > -.endif > +CC:=${CC:C/^(.*\/)?clang$/gcc/1}
How about clearing some user-defined variable together with the substitution CLANG_FLAGS = # set to empty value CC := ${CC:C/^(.*\/)?clang$/gcc/1} in which user can store clang-specific flags (via src.conf), e.g. CC = clang ${CLANG_FLAGS} CLANG_FLAGS = -Qunused-arguments # too much noise for `make -s' build or CPUTYPE ?= native CLANG_FLAGS = -mno-sse4 # don't feed as(1) unknown opcodes Otherwise, substitution occurs too late and gcc(1) chokes on unknown options. _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"