diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 7d6daff9c..3ae7c297e 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -23,8 +23,6 @@ endif() add_executable(86Box 86box.c config.c - log.c - random.c timer.c io.c acpi.c @@ -41,15 +39,11 @@ add_executable(86Box pci.c mca.c usb.c - fifo.c - fifo8.c device.c nvr.c nvr_at.c nvr_ps2.c machine_status.c - ini.c - cJSON.c ) if(CMAKE_SYSTEM_NAME MATCHES "Linux") @@ -106,7 +100,7 @@ if(INSTRUMENT) endif() target_link_libraries(86Box cpu chipset mch dev mem fdd game cdrom zip mo hdd - net print scsi sio snd vid voodoo plat ui) + net print scsi sio snd utils vid voodoo plat ui) if(WIN32 AND ARCH STREQUAL "i386") if(MINGW) @@ -253,7 +247,9 @@ add_subdirectory(printer) add_subdirectory(sio) add_subdirectory(scsi) add_subdirectory(sound) +add_subdirectory(utils) add_subdirectory(video) + if (APPLE) add_subdirectory(mac) endif() diff --git a/src/utils/CMakeLists.txt b/src/utils/CMakeLists.txt new file mode 100644 index 000000000..1d4b1f73e --- /dev/null +++ b/src/utils/CMakeLists.txt @@ -0,0 +1,25 @@ +# +# 86Box A hypervisor and IBM PC system emulator that specializes in +# running old operating systems and software designed for IBM +# PC systems and compatibles from 1981 through fairly recent +# system designs based on the PCI bus. +# +# This file is part of the 86Box distribution. +# +# CMake build script. +# +# Authors: David Hrdlička, +# Jasmine Iwanek, +# +# Copyright 2020-2021 David Hrdlička. +# Copyright 2024 Jasmine Iwanek. +# + +add_library(utils OBJECT + cJSON.c + fifo.c + fifo8.c + ini.c + log.c + random.c +) diff --git a/src/cJSON.c b/src/utils/cJSON.c similarity index 100% rename from src/cJSON.c rename to src/utils/cJSON.c diff --git a/src/fifo.c b/src/utils/fifo.c similarity index 100% rename from src/fifo.c rename to src/utils/fifo.c diff --git a/src/fifo8.c b/src/utils/fifo8.c similarity index 100% rename from src/fifo8.c rename to src/utils/fifo8.c diff --git a/src/ini.c b/src/utils/ini.c similarity index 100% rename from src/ini.c rename to src/utils/ini.c diff --git a/src/log.c b/src/utils/log.c similarity index 100% rename from src/log.c rename to src/utils/log.c diff --git a/src/random.c b/src/utils/random.c similarity index 100% rename from src/random.c rename to src/utils/random.c