如何确认emacs支持svg呢?

emacs 编译参数

In GNU Emacs 29.0.60 (build 2, x86_64-apple-darwin21.6.0, NS
 appkit-2113.60 Version 12.6.2 (Build 21G320)) of 2023-01-13 built on
 192.168.0.102
Windowing system distributor 'Apple', version 10.3.2113
System Description:  macOS 12.6.2

Configured using:
 'configure --enable-locallisppath=/usr/local/share/emacs/site-lisp
 --infodir=/usr/local/Cellar/emacs-head@29/29.0.60_1/share/info/emacs
 --prefix=/usr/local/Cellar/emacs-head@29/29.0.60_1 --without-x
 --without-dbus --with-imagemagick --with-modules --without-pop
 --with-gnutls --with-rsvg --with-xml2 --with-xwidgets --with-ns
 --disable-ns-self-contained 'CFLAGS=-DFD_SETSIZE=10000
 -DDARWIN_UNLIMITED_SELECT''

Configured features:
ACL GIF GMP GNUTLS IMAGEMAGICK JPEG JSON LCMS2 LIBXML2 MODULES NOTIFY
KQUEUE NS PDUMPER PNG SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS
TREE_SITTER WEBP XIM XWIDGETS ZLIB

我编译的这个版本,configure 有 --with-rsvg, features 也包括 svg, 可是

image-types
=> (heic imagemagick webp png gif tiff jpeg xpm xbm pbm) 却不包括 svg

(image-type-available-p 'svg)
=> nil 

这是为什么呢?而且我更新前的emacs29好像支持svg,现在突然又失灵了,真的奇怪,是更新了什么东西吗,现在 acm 的图标显示失效了?

所以,你装了 librsvg 么?

装了,绝对装了,我brew里面有三个都依赖librsvg。 还是说编译的时候它没有识别到呢?我试一下重装librsvg和emacs试试看。

找到 Emacs 的二进制,用 otool -L 看有没有链接到 librsvg

是 emacs-head brew源的问题,好像是这个 recommend keyword 之后的问题,我改用emacs-plus 就ok。