summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Kangas <stefan@marxist.se>2022-07-14 14:02:27 +0200
committerStefan Kangas <stefan@marxist.se>2022-07-14 14:02:27 +0200
commit35238c4fc020baccc1de24b38fe7b69e97e22c69 (patch)
tree59cd9ce117ee90dfe2900dc1f0358748bf46cc89
parent2b869237cc1394a34619a28363050f7ee694a5f0 (diff)
downloademacs-35238c4fc020baccc1de24b38fe7b69e97e22c69.tar.gz
Pacify -Wunused-macros in --without-all builds
* src/image.c (IMAGE_TYPE_INIT): Make conditional on image support.
-rw-r--r--src/image.c13
1 files changed, 10 insertions, 3 deletions
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
};