diff --git a/src/sound/CMakeLists.txt b/src/sound/CMakeLists.txt
index 35f65d1205..24a38e409f 100644
--- a/src/sound/CMakeLists.txt
+++ b/src/sound/CMakeLists.txt
@@ -11,6 +11,12 @@ if (NOT OPTION_DEDICATED)
         CONDITION SDL_FOUND
     )
 
+    add_files(
+        sdl2_s.cpp
+        sdl_s.h
+        CONDITION SDL2_FOUND
+    )
+
     add_files(
         cocoa_s.cpp
         cocoa_s.h