From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-x236.google.com (mail-wm0-x236.google.com [IPv6:2a00:1450:400c:c09::236]) (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 821CF1A1E24 for ; Tue, 2 Aug 2016 07:39:45 -0700 (PDT) Received: by mail-wm0-x236.google.com with SMTP id o80so293757337wme.1 for ; Tue, 02 Aug 2016 07:39:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=8D7xELluCcxn6bvmx53DRIqz3mslUBXSDhkLQxf4jS0=; b=Di7KxdpGpZpDT67Bmid7BXy9NUI5xnnuL698BZ4NkX6slqz5Aat2UeCaFIFPlwkM1d A438cg3qowxx7svHkxLusYz40VYL0fFx/ajkRhGUa5EFjmdsBWA//TU+9J2oX5qP9zgg prrvCNJeUEpZoz/cCGRrYVONJ+i96btb/dE1Y= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=8D7xELluCcxn6bvmx53DRIqz3mslUBXSDhkLQxf4jS0=; b=IEiLA0mZWSOXJsVoc+mjVkfZw5DPGfSqdl5d9GElKQgA0hJtOe22VZ9sDP1zW/62cX nycgNNxZqlM6hYMFYAWU81JwiHKpKlrz61xLQiABuo5bu0zmf8Zeq7E6wljM0++llik7 816XO9Bd8Mh7rnN/bwzJYvyplT34+V6rfi260GGx2RvAmzLMDOfkdUMV57t19jmSqmRi TZwD6qMPs1iqVx1/Au86QESj50kdhw0um1np7hbY2cqy5/99X+FeWxQMOur+spQFVPh3 ixWRgPs0OVFuo3DSLMItQKnRunws9fFttT+WivYUf9FzlWH7gf0fW/pXK8iwHx1343zY jFVA== X-Gm-Message-State: AEkooutHWpNxFmCb3ZyRvX1l+wUU+GIczp8SBWCpPz7CKNQRYYhvnlZITIVWSS/moSgNJf2q X-Received: by 10.194.238.170 with SMTP id vl10mr57671831wjc.18.1470148784120; Tue, 02 Aug 2016 07:39:44 -0700 (PDT) Received: from localhost.localdomain (3.red-81-34-118.dynamicip.rima-tde.net. [81.34.118.3]) by smtp.gmail.com with ESMTPSA id v203sm3375254wmv.2.2016.08.02.07.39.42 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 02 Aug 2016 07:39:43 -0700 (PDT) From: Ard Biesheuvel To: yonghong.zhu@intel.com, liming.gao@intel.com, jordan.l.justen@intel.com, edk2-devel@lists.01.org, leif.lindholm@linaro.org Cc: sigmaepsilon92@gmail.com, Ard Biesheuvel Date: Tue, 2 Aug 2016 16:39:32 +0200 Message-Id: <1470148772-15712-4-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1470148772-15712-1-git-send-email-ard.biesheuvel@linaro.org> References: <1470148772-15712-1-git-send-email-ard.biesheuvel@linaro.org> Subject: [PATCH 3/3] BaseTools GCC: add the compiler flags to the linker command line 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 14:39:45 -0000 Now that we invoke GCC as the linker for the GCC toolchain family, we can pass the CC flags to the linker as well. This is only required for LTO (which may involve code generation during the link stage), but does not interfere with non-LTO builds. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel --- BaseTools/Conf/build_rule.template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/BaseTools/Conf/build_rule.template b/BaseTools/Conf/build_rule.template index 7d9f8ca075c2..ddeef59a9ec6 100644 --- a/BaseTools/Conf/build_rule.template +++ b/BaseTools/Conf/build_rule.template @@ -294,7 +294,7 @@ "$(DLINK)" /OUT:${dst} $(DLINK_FLAGS) $(DLINK_SPATH) @$(STATIC_LIBRARY_FILES_LIST) - "$(DLINK)" -o ${dst} $(DLINK_FLAGS) -Wl,--start-group,@$(STATIC_LIBRARY_FILES_LIST),--end-group $(DLINK2_FLAGS) + "$(DLINK)" -o ${dst} $(DLINK_FLAGS) -Wl,--start-group,@$(STATIC_LIBRARY_FILES_LIST),--end-group $(CC_FLAGS) $(DLINK2_FLAGS) "$(OBJCOPY)" $(OBJCOPY_FLAGS) ${dst} -- 2.7.4