{"id":809887,"url":"http://patchwork.ozlabs.org/api/1.0/patches/809887/?format=json","project":{"id":18,"url":"http://patchwork.ozlabs.org/api/1.0/projects/18/?format=json","name":"U-Boot","link_name":"uboot","list_id":"u-boot.lists.denx.de","list_email":"u-boot@lists.denx.de","web_url":null,"scm_url":null,"webscm_url":null},"msgid":"<20170905011939.5794-3-xypron.glpk@gmx.de>","date":"2017-09-05T01:19:38","name":"[U-Boot,2/3] scripts/Makefile.lib: generalize building built in EFI app","commit_ref":null,"pull_url":null,"state":"superseded","archived":true,"hash":"75ea1246afbbe6159b31fa2bf456b207799b7583","submitter":{"id":61270,"url":"http://patchwork.ozlabs.org/api/1.0/people/61270/?format=json","name":"Heinrich Schuchardt","email":"xypron.glpk@gmx.de"},"delegate":{"id":3400,"url":"http://patchwork.ozlabs.org/api/1.0/users/3400/?format=json","username":"agraf","first_name":"Alexander","last_name":"Graf","email":"agraf@suse.de"},"mbox":"http://patchwork.ozlabs.org/project/uboot/patch/20170905011939.5794-3-xypron.glpk@gmx.de/mbox/","series":[{"id":1475,"url":"http://patchwork.ozlabs.org/api/1.0/series/1475/?format=json","date":"2017-09-05T01:19:36","name":"Clean up make process for EFI payload","version":1,"mbox":"http://patchwork.ozlabs.org/series/1475/mbox/"}],"check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/809887/checks/","tags":{},"headers":{"Return-Path":"<u-boot-bounces@lists.denx.de>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":"ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)","Received":["from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xmTTL6TbFz9s7f\n\tfor <incoming@patchwork.ozlabs.org>;\n\tTue,  5 Sep 2017 11:21:58 +1000 (AEST)","by lists.denx.de (Postfix, from userid 105)\n\tid A606BC21E52; Tue,  5 Sep 2017 01:21:12 +0000 (UTC)","from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 045A1C21F4A;\n\tTue,  5 Sep 2017 01:20:55 +0000 (UTC)","by lists.denx.de (Postfix, from userid 105)\n\tid A241EC21F1F; Tue,  5 Sep 2017 01:20:43 +0000 (UTC)","from mout.gmx.net (mout.gmx.net [212.227.15.19])\n\tby lists.denx.de (Postfix) with ESMTPS id 306CDC21F12\n\tfor <u-boot@lists.denx.de>; Tue,  5 Sep 2017 01:20:40 +0000 (UTC)","from laptop1.fritz.box ([94.197.121.125]) by mail.gmx.com (mrgmx001\n\t[212.227.17.184]) with ESMTPSA (Nemesis) id 0MJSx9-1dn6T40JiN-0032g9;\n\tTue, 05 Sep 2017 03:20:33 +0200"],"X-Spam-Checker-Version":"SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de","X-Spam-Level":"","X-Spam-Status":"No, score=-0.7 required=5.0 tests=FREEMAIL_FROM,\n\tRCVD_IN_DNSWL_LOW,\n\tRCVD_IN_MSPIKE_H2 autolearn=unavailable autolearn_force=no\n\tversion=3.4.0","From":"Heinrich Schuchardt <xypron.glpk@gmx.de>","To":"Alexander Graf <agraf@suse.de>","Date":"Tue,  5 Sep 2017 03:19:38 +0200","Message-Id":"<20170905011939.5794-3-xypron.glpk@gmx.de>","X-Mailer":"git-send-email 2.11.0","In-Reply-To":"<20170905011939.5794-1-xypron.glpk@gmx.de>","References":"<20170905011939.5794-1-xypron.glpk@gmx.de>","X-Provags-ID":"V03:K0:LczoANj9KgH9u+oY7Gn2TEpXn6qS1cyyNBswc5hhh9q+9kvR4Ib\n\tAVtSQQ2LizMlymFNYDRKYL7UyxPGyu5eRPzwkttdocw7JivnQj34k8/kUn607UnR/9/LJxV\n\toJ5iIJOliGpbo17y/L0Dtr07bIld2fs5lFm/IDOW4mQtbt9uORl7NmU3GuN///GzDUNG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y Shevchenko <andriy.shevchenko@linux.intel.com>, u-boot@lists.denx.de","Subject":"[U-Boot] [PATCH 2/3] scripts/Makefile.lib: generalize building\n\tbuilt in EFI app","X-BeenThere":"u-boot@lists.denx.de","X-Mailman-Version":"2.1.18","Precedence":"list","List-Id":"U-Boot discussion <u-boot.lists.denx.de>","List-Unsubscribe":"<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>","List-Archive":"<http://lists.denx.de/pipermail/u-boot/>","List-Post":"<mailto:u-boot@lists.denx.de>","List-Help":"<mailto:u-boot-request@lists.denx.de?subject=help>","List-Subscribe":"<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>","MIME-Version":"1.0","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"base64","Errors-To":"u-boot-bounces@lists.denx.de","Sender":"\"U-Boot\" <u-boot-bounces@lists.denx.de>"},"content":"Replace all occurences of helloworld by generalized forms.\nThis allows us to build additional EFI applications that are\nincluded into the U-Boot binary without loading\nscripts/Makefile.lib with specific filenames.\n\nSigned-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>\n---\n scripts/Makefile.lib | 28 +++++++++++++++-------------\n 1 file changed, 15 insertions(+), 13 deletions(-)","diff":"diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib\nindex 164c234b4c..c73464b854 100644\n--- a/scripts/Makefile.lib\n+++ b/scripts/Makefile.lib\n@@ -342,20 +342,22 @@ cmd_S_ttf=\t\t\t\t\t\t\\\n $(obj)/%.S: $(src)/%.ttf\n \t$(call cmd,S_ttf)\n \n-# EFI Hello World application\n+# EFI applications\n+# A Makefile target *.efi is built as EFI application.\n+# A Makefile target *_efi.S wraps *.efi as built-in EFI application.\n # ---------------------------------------------------------------------------\n \n # Generate an assembly file to wrap the EFI app\n-cmd_S_efi=\t\t\t\t\t\t\\\n-(\t\t\t\t\t\t\t\\\n-\techo '.section .rodata.efi.init,\"a\"';\t\t\\\n-\techo '.balign 16';\t\t\t\t\\\n-\techo '.global __efi_helloworld_begin';\t\t\\\n-\techo '__efi_helloworld_begin:';\t\t\\\n-\techo '.incbin \"$<\" ';\t\t\t\t\\\n-\techo '__efi_helloworld_end:';\t\t\t\\\n-\techo '.global __efi_helloworld_end';\t\t\\\n-\techo '.balign 16';\t\t\t\t\\\n+cmd_S_efi=\t\t\t\t\t\\\n+(\t\t\t\t\t\t\\\n+\techo '.section .rodata.$*.init,\"a\"';\t\\\n+\techo '.balign 16';\t\t\t\\\n+\techo '.global __efi_$*_begin';\t\t\\\n+\techo '__efi_$*_begin:';\t\t\t\\\n+\techo '.incbin \"$<\" ';\t\t\t\\\n+\techo '__efi_$*_end:';\t\t\t\\\n+\techo '.global __efi_$*_end';\t\t\\\n+\techo '.balign 16';\t\t\t\\\n ) > $@\n \n $(obj)/%_efi.S: $(obj)/%.efi\n@@ -366,7 +368,7 @@ cmd_efi_objcopy = $(OBJCOPY) -j .header -j .text -j .sdata -j .data -j \\\n \t\t.dynamic -j .dynsym  -j .rel* -j .rela* -j .reloc \\\n \t\t$(if $(EFI_TARGET),$(EFI_TARGET),-O binary) $^ $@\n \n-$(obj)/%.efi: $(obj)/%.so\n+$(obj)/%.efi: $(obj)/%_efi.so\n \t$(call cmd,efi_objcopy)\n \n quiet_cmd_efi_ld = LD      $@\n@@ -375,7 +377,7 @@ cmd_efi_ld = $(LD) -nostdlib -znocombreloc -T $(EFI_LDS_PATH) -shared \\\n \n EFI_LDS_PATH = $(srctree)/arch/$(ARCH)/lib/$(EFI_LDS)\n \n-$(obj)/helloworld.so: $(obj)/helloworld.o arch/$(ARCH)/lib/$(EFI_CRT0) \\\n+$(obj)/%_efi.so: $(obj)/%.o $(%_deps) arch/$(ARCH)/lib/$(EFI_CRT0) \\\n \t\tarch/$(ARCH)/lib/$(EFI_RELOC)\n \t$(call cmd,efi_ld)\n \n","prefixes":["U-Boot","2/3"]}