Please Review - Revised OS X Application Bundle patch

Mike Kronenberg mike.kronenberg at kronenberg.org
Mon Dec 7 11:46:13 CST 2009


On 07.12.2009, at 18:08, <Joerg-Cyril.Hoehle at t-systems.com> <Joerg-Cyril.Hoehle at t-systems.com> wrote:

> .png are created today in ~/.local/share/icons/ by Wine on Mac and
> Linux.  (It used to be .xpm in the past and configure must detect
> libpng).  Note that .png is mere *output* from Wine because that's
> what FreeDesktop wants as input (and .xpm). 
> Judging from the .icns size, this looks like a non-compressed format.
> There should be enough code in Wine or MacOS to turn the installer
> submitted raw icon data into whatever Mac's icon resource fork requires.
> windowscodecs need not be beinvolved IMHO (I mean it should need
> nothing that was not already present in 0.9.x).


This can be easily done, I've integrated lately similar functionality in WineBottler.
If You already have the png only the sipping part of this little script is needed.

createIconsFromExe.sh

#!/usr/bin/env bash
PATH_TO_EXECUTABLE=$(echo "$PATH_TO_EXECUTABLE" | sed s'/\\/\//g')
MAINICON=$(echo $(wrestool -l --type=group_icon "$PATH_TO_EXECUTABLE") | awk '{print $2}' | sed 's/--name=//')
MAINICON=$(echo $MAINICON | sed s/\'//g)
rm /tmp/MAINICON.ico &> /dev/null
wrestool -x --type=group_icon --output=/tmp/MAINICON.ico --name=$MAINICON "$PATH_TO_EXECUTABLE" &> /dev/null
sips -s format icns /tmp/MAINICON.ico --out "$PATH_TO_ICON" &> /dev/null
rm /tmp/MAINICON.ico &> /dev/null

Mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3410 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20091207/e549d0a2/attachment.bin>


More information about the wine-devel mailing list