On 07.12.2009, at 18:08, <joerg-cyril.hoe...@t-systems.com> 
<joerg-cyril.hoe...@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

Attachment: smime.p7s
Description: S/MIME cryptographic signature



Reply via email to