From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-it0-x230.google.com (mail-it0-x230.google.com [IPv6:2607:f8b0:4001:c0b::230]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 2FB3D1A1DF4 for ; Tue, 2 Aug 2016 08:09:37 -0700 (PDT) Received: by mail-it0-x230.google.com with SMTP id f6so273627762ith.1 for ; Tue, 02 Aug 2016 08:09:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=yFQuUUi7fjORhmVvJNqJfhPq3xX5P/rXmjodZtezMuU=; b=iKlwQV5NJ0Wr1QkDN/0MqeqZx30RoCXTi9GH88GVM6iKL7/uW4+wN5V6HrFfLuCnEa EHuFFUbxjCfUgHUPoP5s9e5tq70s1VssparY0117Om+szN3e02/d13q22O+vPDDAsG/P /mUzeyHHCDHb8iBM9eI6Xs1Q+sPaHG+Us6dSw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=yFQuUUi7fjORhmVvJNqJfhPq3xX5P/rXmjodZtezMuU=; b=lcLWrNQ1PRZYeR6tgetWC3oDhF8QMXP7QplbeykHYt39QV8w/Uwkj7Syboj8nOTHpd Kn+RZc0oG1ILkpuos8bcqG4DvfD9W4B3mX5bcJIqZrawV/d8Ra4fxOWwS2WQEhmXoLO2 c5+IFBTZ3k06mNXL2QuXhoQT6iiH9UXTWZW7dej7oPGpQH4nU9Fi/0KsWMXVGLxhk9fi MAT9k0T4HBq7iMTdKwT2e6RY9m3mjRcorGKyqZim3M5CmZO1VeVV+pYNxeDFcheZ8aDm c7f3bK6GcwThTTUha6XvmXUlR1t0Pm3E80lPpG8gMxKXX4KVZc/DcS1EBLDW0aAE6iJq Bsgg== X-Gm-Message-State: AEkoous/bgr4IabS2weo0YnKI/ma+9jnpgscnXlHxZlCLPCRgDVg/Qn3PsPKWjX98PLkcrDwAGZ9agC5aq4srXRN X-Received: by 10.36.25.144 with SMTP id b138mr14508563itb.29.1470150576507; Tue, 02 Aug 2016 08:09:36 -0700 (PDT) MIME-Version: 1.0 Received: by 10.36.204.195 with HTTP; Tue, 2 Aug 2016 08:09:36 -0700 (PDT) In-Reply-To: References: <1470148772-15712-1-git-send-email-ard.biesheuvel@linaro.org> <1470148772-15712-2-git-send-email-ard.biesheuvel@linaro.org> <20160802150156.GW31760@bivouac.eciton.net> From: Ard Biesheuvel Date: Tue, 2 Aug 2016 17:09:36 +0200 Message-ID: To: Leif Lindholm Cc: "Zhu, Yonghong" , "Gao, Liming" , Jordan Justen , edk2-devel-01 , Michael Zimmermann Subject: Re: [PATCH 1/3] BaseTools GCC: move -c compiler flag to build rules X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Aug 2016 15:09:37 -0000 Content-Type: text/plain; charset=UTF-8 On 2 August 2016 at 17:02, Ard Biesheuvel wrote: > On 2 August 2016 at 17:01, Leif Lindholm wrote: >> On Tue, Aug 02, 2016 at 04:39:30PM +0200, Ard Biesheuvel wrote: >>> In order to be able to share the compiler flags with the linker (which >>> is required for LTO since it involves the linker doing code generation >>> based on the LTO bytecode), move the -c GCC argument to the build rules, >>> and drop it from the GCC CC_FLAGS definitions in tools_def. >>> >>> Contributed-under: TianoCore Contribution Agreement 1.0 >>> Signed-off-by: Ard Biesheuvel >>> --- >>> BaseTools/Conf/build_rule.template | 16 +++++++++------- >>> BaseTools/Conf/tools_def.template | 10 +++++----- >>> 2 files changed, 14 insertions(+), 12 deletions(-) >>> >>> diff --git a/BaseTools/Conf/build_rule.template b/BaseTools/Conf/build_rule.template >>> index 9adf3918e42e..7d9f8ca075c2 100644 >>> --- a/BaseTools/Conf/build_rule.template >>> +++ b/BaseTools/Conf/build_rule.template >>> @@ -130,7 +130,10 @@ >>> >>> "$(CC)" /Fo${dst} $(CC_FLAGS) $(INC) ${src} >>> >>> - >>> + >>> + "$(CC)" $(CC_FLAGS) -c -o ${dst} $(INC) ${src} >>> + >>> + >> >> Apart from the slightly larger patch set, is there any reason not to >> split out the RVCT handling here and fix up tools_def.template for it >> too? >> OK, i get it now. That actually simplifies the patch, since I don't need to split off RVCT in build_rules then