From patchwork Fri May 13 09:50:42 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laszlo Ersek X-Patchwork-Id: 67745 Delivered-To: patch@linaro.org Received: by 10.140.92.199 with SMTP id b65csp173999qge; Fri, 13 May 2016 02:50:54 -0700 (PDT) X-Received: by 10.66.246.228 with SMTP id xz4mr21310591pac.139.1463133054024; Fri, 13 May 2016 02:50:54 -0700 (PDT) Return-Path: Received: from ml01.01.org (ml01.01.org. [2001:19d0:306:5::1]) by mx.google.com with ESMTPS id n5si23819966pax.112.2016.05.13.02.50.53 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 May 2016 02:50:53 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) client-ip=2001:19d0:306:5::1; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) smtp.mailfrom=edk2-devel-bounces@lists.01.org Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 3DBBB1A1FD6; Fri, 13 May 2016 02:50:55 -0700 (PDT) X-Original-To: edk2-devel@ml01.01.org Delivered-To: edk2-devel@ml01.01.org Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 5FFF51A1E25 for ; Fri, 13 May 2016 02:50:54 -0700 (PDT) Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 3B5C13B714; Fri, 13 May 2016 09:50:52 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-113-23.phx2.redhat.com [10.3.113.23]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u4D9ojP4024394; Fri, 13 May 2016 05:50:51 -0400 From: Laszlo Ersek To: edk2-devel-01 Date: Fri, 13 May 2016 11:50:42 +0200 Message-Id: <1463133042-3402-3-git-send-email-lersek@redhat.com> In-Reply-To: <1463133042-3402-1-git-send-email-lersek@redhat.com> References: <1463133042-3402-1-git-send-email-lersek@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Fri, 13 May 2016 09:50:52 +0000 (UTC) Subject: [edk2] [PATCH 2/2] MdeModulePkg/BootMaintenanceManagerUiLib: hide library-internal symbol X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Eric Dong , Liming Gao , Ard Biesheuvel MIME-Version: 1.0 Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" Static storage duration objects that are internal to a library instance should: - either have internal linkage (i.e., be declared STATIC), - or, if they are referenced in multiple files of the library instance, prefixed with a word that is specific to the library instance, and minimizes namespace collisions. In this case, the "gHiiDriverList" variable (with static storage duration and external linkage) is defined in both BootMaintenanceManagerUiLib and UiApp. When these are linked together, GCC catches the multiple external definitions and aborts the build. (GCC notices this due to commit 214a3b79417f.) Fix the error by applying the first rule above. Cc: Ard Biesheuvel Cc: Eric Dong Cc: Liming Gao Fixes: a85be3ae48a8aaa40b755cd0ff7270c67cfed585 Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek --- MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerCustomizedUiSupport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 1.8.3.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel diff --git a/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerCustomizedUiSupport.c b/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerCustomizedUiSupport.c index 177b2498d3ec..fefb714b9166 100644 --- a/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerCustomizedUiSupport.c +++ b/MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerCustomizedUiSupport.c @@ -26,7 +26,7 @@ typedef struct { BOOLEAN EmptyLineAfter; } UI_HII_DRIVER_INSTANCE; -UI_HII_DRIVER_INSTANCE *gHiiDriverList; +STATIC UI_HII_DRIVER_INSTANCE *gHiiDriverList; /**