masm11 / emacs

Mirror of GNU Emacs
http://www.gnu.org/software/emacs/
GNU General Public License v3.0
198 stars 14 forks source link

No icon window available #76

Closed Vixeliz closed 3 years ago

Vixeliz commented 3 years ago

I have no idea why this is happening can't seem to find any info online. I just get this error message 'No icon window available' and it refuses to launch.

masm11 commented 3 years ago

Maybe, because emacs can't find emacs.svg or can't read it.

In my environment, it is installed in /usr/share/emacs/28.0.50/etc/images/icons/hicolor/scalable/apps/emacs.svg, and the data-directory variable is /usr/share/emacs/28.0.50/etc/.

Vixeliz commented 3 years ago

looking at an strace log it seems to find it

Vixeliz commented 3 years ago

If it is of help here is the strace log https://termbin.com/8morg.

Vixeliz commented 3 years ago

This can be fixed by changing the error messages in

src/w32fns.c
src/xfns.c
src/pgtkfns.c

to warning via printf or the likes.

masm11 commented 3 years ago

Thank you for the strace log.

You need svg support of gdk-pixbuf.

/usr/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache should contain:

"/usr/lib/gdk-pixbuf-2.0/2.10.0/loaders/libpixbufloader-svg.so"
"svg" 6 "gdk-pixbuf" "Scalable Vector Graphics" "LGPL"
"image/svg+xml" "image/svg" "image/svg-xml" "image/vnd.adobe.svg+xml" "text/xml-svg" "image/svg+xml-compressed" ""
"svg" "svgz" "svg.gz" ""
" <svg" "*    " 100
" <!DOCTYPE svg" "*             " 100

libpixbufloader-svg.so should load librsvg.

luna:~ % ldd /usr/lib/gdk-pixbuf-2.0/2.10.0/loaders/libpixbufloader-svg.so | grep svg
    librsvg-2.so.2 => /usr/lib/librsvg-2.so.2 (0x00007f75fa221000)
luna:~ % 
Vixeliz commented 3 years ago

I dont have rust on my system for librsvg :/. But its no worries when I packaged it I just replaced error with printf and it works fine for me now.

Would you be interested in doing this upstream? It will still warn the user but allow for people without svg support to be able to use this.

masm11 commented 3 years ago

pgtk emacs can be built without librsvg, but it fails to start. That is an issue.

I want pgtk emacs to work without librsvg before pushing to fsf's repository. I'll re-port X-code to handle icon images to pgtk.

masm11 commented 3 years ago

Could you try #77? It should fix this issue.