Received: from eggs.gnu.org ([2001:4830:134:3::10]:58339) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YOBsG-0005TQ-Nc for qemu-devel@nongnu.org; Wed, 18 Feb 2015 16:09:37 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YOBsD-0006F7-HM for qemu-devel@nongnu.org; Wed, 18 Feb 2015 16:09:36 -0500 Received: from mail-qa0-x22c.google.com ([2607:f8b0:400d:c00::22c]:57105) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YOBsD-0006Et-D8 for qemu-devel@nongnu.org; Wed, 18 Feb 2015 16:09:33 -0500 Received: by mail-qa0-f44.google.com with SMTP id n8so2780144qaq.3 for ; Wed, 18 Feb 2015 13:09:32 -0800 (PST) From: Programmingkid Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Date: Wed, 18 Feb 2015 16:09:27 -0500 Message-Id: <24F20DD4-DD6D-4071-B45F-3CFF81AB419C@gmail.com> Mime-Version: 1.0 (Apple Message framework v1084) Subject: [Qemu-devel] [PATCH] Makefile.target: set icon for binary file on Mac OS X List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel qemu-devel Cc: Peter Maydell This patch adds the instruction to have the build commands give QEMU an = icon. This code runs on Mac OS X.=20 Signed-off-by: John Arbuckle --- Makefile.target | 21 ++++++++++++++++++++- 1 files changed, 20 insertions(+), 1 deletions(-) mode change 100644 =3D> 100755 Makefile.target diff --git a/Makefile.target b/Makefile.target old mode 100644 new mode 100755 index e9ff1ee..e3679b4 --- a/Makefile.target +++ b/Makefile.target @@ -75,7 +75,7 @@ else stap: endif =20 -all: $(PROGS) stap +all: $(PROGS) stap give_icon =20 # Dummy command so that make thinks it has done something @true @@ -208,3 +208,22 @@ endif =20 GENERATED_HEADERS +=3D config-target.h Makefile: $(GENERATED_HEADERS) + +# Set the icon for QEMU on Macintosh +give_icon: + ifdef CONFIG_DARWIN + # Take an image and make the image its own icon: + sips -i ../pc-bios/qemu-nsis.ico + + # Extract the icon to its own resource file: + DeRez -only icns ../pc-bios/qemu-nsis.ico > tmpicns.rsrc + + # append this resource to the file you want to icon-ize. + Rez -append tmpicns.rsrc -o $(QEMU_PROG) + + # Use the resource to set the icon. + SetFile -a C $(QEMU_PROG) + + # clean up. + rm tmpicns.rsrc + endif --=20 1.7.5.4