SDL: add audio/video dummies if nothing else available II.

From a633a3c33ef9a82e73ff1242466b8f84a00045e2 Mon Sep 17 00:00:00 2001
From: pionere <[EMAIL REDACTED]>
Date: Thu, 13 Jan 2022 09:33:20 +0100
Subject: [PATCH] add audio/video dummies if nothing else available II.

---
 configure    | 16 ++++++++++++++++
 configure.ac | 12 ++++++++++++
 2 files changed, 28 insertions(+)

diff --git a/configure b/configure
index 75f8fdef45e..6603cd91825 100755
--- a/configure
+++ b/configure
@@ -26893,6 +26893,22 @@ INSTALL_SDL2_CONFIG=$enable_sdl2_config
 
 # Verify that we have all the platform specific files we need
 
+if test x$have_audio != xyes; then
+    if test x$enable_audio = xyes; then
+
+$as_echo "#define SDL_AUDIO_DRIVER_DUMMY 1" >>confdefs.h
+
+    fi
+    SOURCES="$SOURCES $srcdir/src/audio/dummy/*.c"
+fi
+if test x$have_video != xyes; then
+    if test x$enable_video = xyes; then
+
+$as_echo "#define SDL_VIDEO_DRIVER_DUMMY 1" >>confdefs.h
+
+    fi
+    SOURCES="$SOURCES $srcdir/src/video/dummy/*.c"
+fi
 if test x$have_misc != xyes; then
     if test x$enable_misc = xyes; then
 
diff --git a/configure.ac b/configure.ac
index c70a1edeb8c..0391c67b463 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4567,6 +4567,18 @@ AC_SUBST([INSTALL_SDL2_CONFIG], [$enable_sdl2_config])
 
 # Verify that we have all the platform specific files we need
 
+if test x$have_audio != xyes; then
+    if test x$enable_audio = xyes; then
+        AC_DEFINE(SDL_AUDIO_DRIVER_DUMMY, 1, [ ])
+    fi
+    SOURCES="$SOURCES $srcdir/src/audio/dummy/*.c"
+fi
+if test x$have_video != xyes; then
+    if test x$enable_video = xyes; then
+        AC_DEFINE(SDL_VIDEO_DRIVER_DUMMY, 1, [ ])
+    fi
+    SOURCES="$SOURCES $srcdir/src/video/dummy/*.c"
+fi
 if test x$have_misc != xyes; then
     if test x$enable_misc = xyes; then
         AC_DEFINE(SDL_MISC_DUMMY, 1, [ ])