From owner-svn-src-all@FreeBSD.ORG Mon Oct 4 21:42:03 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DF3181065698; Mon, 4 Oct 2010 21:42:02 +0000 (UTC) (envelope-from swell.k@gmail.com) Received: from mail-bw0-f54.google.com (mail-bw0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id DC0D28FC19; Mon, 4 Oct 2010 21:42:01 +0000 (UTC) Received: by bwz15 with SMTP id 15so5410246bwz.13 for ; Mon, 04 Oct 2010 14:42:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:references :date:message-id:user-agent:mime-version:content-type; bh=1O29XTtDXksbvNthZs/2FSBGOx6/e6IXAfxS7qrqq04=; b=dqF9WqR4RlJfrIRPtcxsb0rkT1wfl0ZIdBqBmRzYLXQd4WdIyOl+Yyf3SIoy61EjeZ DrTgANI3GDt2Lqs1KYdqR4q7SqnwoMbesjkaqaZ9tpQVTSmdTz6PZ/oHBqJ9X15DavMQ Putc2osT1aZsJ7ZUVQiUK1OpHdVONYX8yhkak= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:message-id:user-agent :mime-version:content-type; b=K73fvtRKJ4BlJzcW33giBZDSvXjqnNRKuQPws7+482MXchPCismX8TyIL7be1vrBZz iJuFlfxy58fJCMaKdolyTFLYzVSl6XvCBEZRd5ZvzL3ALpsshJ9F9fK5eJqYWoaGMH4n TipMUk4Wg3LcfFxn0wDrMrUQaxWQAFJcIzErI= Received: by 10.204.51.67 with SMTP id c3mr7533282bkg.69.1286228520675; Mon, 04 Oct 2010 14:42:00 -0700 (PDT) Received: from localhost (tor-proxy.trit.net [208.75.88.34]) by mx.google.com with ESMTPS id f18sm4217358bkf.3.2010.10.04.14.41.46 (version=SSLv3 cipher=RC4-MD5); Mon, 04 Oct 2010 14:41:58 -0700 (PDT) From: Anonymous To: Dimitry Andric References: <201009212141.o8LLfjHX007646@svn.freebsd.org> <86mxqx7q9o.fsf@gmail.com> <4CA64BF1.9080401@FreeBSD.org> Date: Tue, 05 Oct 2010 01:39:31 +0400 Message-ID: <8639sl7i3w.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r212979 - in head: gnu/lib/libobjc sys/boot/i386/boot2 sys/boot/pc98/boot2 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Oct 2010 21:42:03 -0000 Dimitry Andric writes: > The particular case of libobjc is special, because it is the only > Makefile that both modifies CC, and takes the default CFLAGS from > make.conf. The only other cases where we *must* compile with gcc for > now, are boot2 for i386 and pc98, but these set their CFLAGS to a > hardcoded value. > > A solution could be to always use hardcoded CFLAGS for libobjc. > Otherwise, we could check for a GCC_CFLAGS in libobjc's Makefile, and > substitute these for the regular CFLAGS, iff clang is used to build > world. Does that sound acceptable? What are GCC_CFLAGS and "regular CFLAGS"? And note, you haven't explained why CLANG_FLAGS is bad. I've compiled the world with below src.conf a few times without issues >> CC = clang ${CLANG_FLAGS} >> CLANG_FLAGS = -Qunused-arguments # too much noise for `make -s' build No need to document the variable, it's temporary as the workaround. %% diff --git a/gnu/lib/libobjc/Makefile b/gnu/lib/libobjc/Makefile index 80d0240..b61bf91 100644 --- a/gnu/lib/libobjc/Makefile +++ b/gnu/lib/libobjc/Makefile @@ -16,6 +16,7 @@ SRCS= archive.c class.c encoding.c gc.c hash.c init.c linking.m misc.c \ selector.c sendmsg.c thr.c thr-objc.c exception.c # XXX: clang cannot compile libobjc yet +CLANG_FLAGS= # clear clang-specific user cflags CC:=${CC:C/^(.*\/)?clang$/gcc/1} INCS= encoding.h hash.h objc-api.h objc-decls.h objc-list.h objc.h runtime.h \ diff --git a/sys/boot/i386/boot2/Makefile b/sys/boot/i386/boot2/Makefile index b91a43b..ed5727e 100644 --- a/sys/boot/i386/boot2/Makefile +++ b/sys/boot/i386/boot2/Makefile @@ -3,6 +3,7 @@ .include # XXX: clang can compile the boot code just fine, but boot2 gets too big +CLANG_FLAGS= # clear clang-specific user cflags CC:=${CC:C/^(.*\/)?clang$/gcc/1} FILES= boot boot1 boot2 diff --git a/sys/boot/pc98/boot2/Makefile b/sys/boot/pc98/boot2/Makefile index dfd8607..e605c8a 100644 --- a/sys/boot/pc98/boot2/Makefile +++ b/sys/boot/pc98/boot2/Makefile @@ -3,6 +3,7 @@ .include # XXX: clang can compile the boot code just fine, but boot2 gets too big +CLANG_FLAGS= # clear clang-specific user cflags CC:=${CC:C/^(.*\/)?clang$/gcc/1} FILES= boot boot1 boot2 %%