--- CMakeLists.txt.orig	2023-11-03 06:08:34 UTC
+++ CMakeLists.txt
@@ -87,6 +87,11 @@ add_executable(moonlight ${SRC_LIST})
 target_link_libraries(moonlight m)
 target_link_libraries(moonlight gamestream)
 
+if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD")
+  set(ALSA_FOUND FALSE)
+  target_sources(moonlight PRIVATE ./src/audio/oss.c)
+endif()
+
 if (CEC_FOUND)
   list(APPEND MOONLIGHT_DEFINITIONS HAVE_LIBCEC)
   list(APPEND MOONLIGHT_OPTIONS CEC)
