From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60142) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YOnR3-0003tu-OI for qemu-devel@nongnu.org; Fri, 20 Feb 2015 08:16:02 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YOnQy-0008KW-MS for qemu-devel@nongnu.org; Fri, 20 Feb 2015 08:16:01 -0500 Received: from smtp5-g21.free.fr ([212.27.42.5]:57107) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YOnQy-0008JY-GM for qemu-devel@nongnu.org; Fri, 20 Feb 2015 08:15:56 -0500 Message-ID: <54E73386.3000105@free.fr> Date: Fri, 20 Feb 2015 14:15:50 +0100 From: =?ISO-8859-1?Q?Fran=E7ois_Revol?= MIME-Version: 1.0 References: <24F20DD4-DD6D-4071-B45F-3CFF81AB419C@gmail.com> <54E5B33D.4000803@redhat.com> <54E72A54.9040807@redhat.com> In-Reply-To: <54E72A54.9040807@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [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: Paolo Bonzini Cc: Peter Maydell , qemu-devel qemu-devel , Programmingkid On 20/02/2015 13:36, Paolo Bonzini wrote: >=20 >=20 > On 20/02/2015 13:18, Peter Maydell wrote: >> Why not just use the sips --out option to specify a different >> output file? That way we automatically put the current icon >> into the executable, and don't have to update a hand-created >> qemu.rsrc file in git if we change the icon in future (and I >> bet if we don't have the rules for doing this in the makefile >> then nobody will remember how to do it). >=20 > I suspect the Windows icon is not a great match for Mac OS X which like= s > to have big sizes (48x48 or 128x128). If you want to generate the .rsr= c > file automatically, the right source probably would be the .svg file, > and doing the conversion in the Makefile probably isn't entirely > feasible. It would need extra build dependency and rounding errors > would make it harder to achieve reproducible builds. And depending on the complexity of the SVG not all methods produce the same result. Although it was years ago I recall having a hard time getting gradients to render correctly with ImageMagick. You'll want to compare the ImageMagick/GraphicsMagick and rsvg (apt:librsvg2-bin on Debian) outputs. Although the current ImageMagick seems to work fine on the logo here. But you'll have to find how to properly specify the size of the SVG (and not use -scale since it'll resize the bitmap, and make it 128x127). OTOH: rsvg-convert -w 128 -h 128 ./pc-bios/qemu_logo_no_text.svg > qemu-r.png seems to generate a proper png with transparency. It seems inkscape can do it as well, but it's probably a larger dependenc= y: http://stackoverflow.com/questions/9853325/how-to-convert-a-svg-to-a-png-= with-image-magick Fran=E7ois.