add_library(libdos STATIC
		cdrom.cpp
		cdrom_image.cpp
		cdrom_ioctl_linux.cpp
		cdrom_win32.cpp
		dos.cpp
		dos_classes.cpp
		dos_devices.cpp
		dos_execute.cpp
		dos_files.cpp
		dos_ioctl.cpp
		dos_keyboard_layout.cpp
		dos_locale.cpp
		dos_memory.cpp
		dos_misc.cpp
		dos_mscdex.cpp
		dos_programs.cpp
		dos_tables.cpp
		drive_cache.cpp
		drive_fat.cpp
		drive_iso.cpp
		drive_local.cpp
		drive_overlay.cpp
		drive_virtual.cpp
		drives.cpp
		program_attrib.cpp
		program_autotype.cpp
		program_biostest.cpp
		program_boot.cpp
		program_choice.cpp
		program_help.cpp
		program_imgmount.cpp
		program_intro.cpp
		program_keyb.cpp
		program_loadfix.cpp
		program_loadrom.cpp
		program_ls.cpp
		program_mem.cpp
		program_mixer.cpp
		program_mode.cpp
		program_more.cpp
		program_more_output.cpp
		program_mount.cpp
		program_mount_common.cpp
		program_mousectl.cpp
		program_move.cpp
		program_placeholder.cpp
		program_rescan.cpp
		program_serial.cpp
		program_setver.cpp
		program_subst.cpp
		program_tree.cpp
)

target_link_libraries(libdos PRIVATE
		libhardware
		libdecoders
		$<IF:$<TARGET_EXISTS:SDL2::SDL2>,SDL2::SDL2,SDL2::SDL2-static>
)
