mirror of
https://github.com/MultiMC/MultiMC5.git
synced 2024-12-27 12:15:26 +00:00
30 lines
598 B
CMake
30 lines
598 B
CMake
project(systeminfo)
|
|
|
|
find_package(Qt5Core)
|
|
|
|
set(systeminfo_SOURCES
|
|
include/sys.h
|
|
include/distroutils.h
|
|
src/distroutils.cpp
|
|
)
|
|
|
|
if (WIN32)
|
|
list(APPEND systeminfo_SOURCES src/sys_win32.cpp)
|
|
elseif (UNIX)
|
|
if(APPLE)
|
|
list(APPEND systeminfo_SOURCES src/sys_apple.cpp)
|
|
else()
|
|
list(APPEND systeminfo_SOURCES src/sys_unix.cpp)
|
|
endif()
|
|
endif()
|
|
|
|
add_library(systeminfo STATIC ${systeminfo_SOURCES})
|
|
target_link_libraries(systeminfo Qt5::Core Qt5::Gui Qt5::Network)
|
|
target_include_directories(systeminfo PUBLIC include)
|
|
|
|
include (UnitTest)
|
|
add_unit_test(sys
|
|
SOURCES src/sys_test.cpp
|
|
LIBS systeminfo
|
|
)
|