From owner-svn-soc-all@FreeBSD.ORG Sun Jun 3 23:54:21 2012 Return-Path: Delivered-To: svn-soc-all@FreeBSD.org Received: from socsvn.FreeBSD.org (unknown [IPv6:2001:4f8:fff6::2f]) by hub.freebsd.org (Postfix) with SMTP id 1BB10106567B for ; Sun, 3 Jun 2012 23:54:19 +0000 (UTC) (envelope-from emc2@FreeBSD.org) Received: by socsvn.FreeBSD.org (sSMTP sendmail emulation); Sun, 03 Jun 2012 23:54:19 +0000 Date: Sun, 03 Jun 2012 23:54:19 +0000 From: emc2@FreeBSD.org To: svn-soc-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Message-Id: <20120603235419.1BB10106567B@hub.freebsd.org> Cc: Subject: socsvn commit: r237023 - soc2012/emc2/experimental X-BeenThere: svn-soc-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the entire Summer of Code repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 03 Jun 2012 23:54:21 -0000 Author: emc2 Date: Sun Jun 3 23:54:18 2012 New Revision: 237023 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=237023 Log: Results of some exploration. The end result of this is a better understanding of how to build EFI applications using the build tools. I've also done a fair amount of exploring the EFI API, though that can't be reflected in actual code changes. Modified: soc2012/emc2/experimental/Makefile soc2012/emc2/experimental/helloworld.c Modified: soc2012/emc2/experimental/Makefile ============================================================================== --- soc2012/emc2/experimental/Makefile Sun Jun 3 22:40:32 2012 (r237022) +++ soc2012/emc2/experimental/Makefile Sun Jun 3 23:54:18 2012 (r237023) @@ -6,13 +6,19 @@ all: helloworld.efi +clean: + rm -f helloworld.o helloworld helloworld.efi start.o + +start.o: start.S + ${CC} -c ${CFLAGS} start.S + helloworld.o: helloworld.c ${CC} -c ${CFLAGS} helloworld.c -helloworld: helloworld.o - ${LD} -T ${LDSCRIPT} -shared -symbolic -o helloworld helloworld.o +helloworld: helloworld.o start.o + ${CC} -nostdlib -o helloworld -Wl,-T ${LDSCRIPT} -shared -symbolic helloworld.o start.o helloworld.efi: helloworld ${OBJCOPY} -j .data -j .dynamic -j .dynstr -j .dynsym -j .hash \ -j .rel.dyn -j .reloc -j .sdata -j .text -j set_Xcommand_set \ - --target=${EFIFORMAT} ${.ALLSRC} helloworld.efi \ No newline at end of file + --target=${EFIFORMAT} ${.ALLSRC} helloworld.efi Modified: soc2012/emc2/experimental/helloworld.c ============================================================================== --- soc2012/emc2/experimental/helloworld.c Sun Jun 3 22:40:32 2012 (r237022) +++ soc2012/emc2/experimental/helloworld.c Sun Jun 3 23:54:18 2012 (r237023) @@ -1,6 +1,6 @@ #include -unsigned short str[] = +static unsigned short str[] = { 'H', 'e', 'l', 'l', 'o', ' ', 'w', 'o', 'r', 'l', 'd', '\n', '\r', 0 }; EFI_STATUS efi_main(EFI_HANDLE image, EFI_SYSTEM_TABLE* systab)