From: Stefan Kangas Date: Thu, 14 Jul 2022 12:02:27 +0000 (+0200) Subject: Pacify -Wunused-macros in --without-all builds X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~16^2~1886^2~942 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=35238c4fc020baccc1de24b38fe7b69e97e22c69;p=emacs.git Pacify -Wunused-macros in --without-all builds * src/image.c (IMAGE_TYPE_INIT): Make conditional on image support. --- diff --git a/src/image.c b/src/image.c index aa7bb3ba667..cc6f27612b9 100644 --- a/src/image.c +++ b/src/image.c @@ -1071,9 +1071,16 @@ struct image_type libraries on Windows), or NULL if none. */ bool (*init) (void); /* An initializer for the init field. */ -# define IMAGE_TYPE_INIT(f) f -#else -# define IMAGE_TYPE_INIT(f) +#endif +#if defined HAVE_RSVG || defined HAVE_PNG || defined HAVE_GIF || \ + defined HAVE_TIFF || defined HAVE_JPEG || defined HAVE_XPM || \ + defined HAVE_NS || defined HAVE_HAIKU || defined HAVE_PGTK || \ + defined HAVE_WEBP +# ifdef WINDOWSNT +# define IMAGE_TYPE_INIT(f) f +# else +# define IMAGE_TYPE_INIT(f) +# endif #endif };