2023-08-14 20:00:04 +08:00
cmake_minimum_required ( VERSION 3.12.0 ) # target_link_libraries with OBJECT libs & project homepage url
2021-02-18 22:25:36 +01:00
2022-03-20 13:16:04 +01:00
project ( fastfetch
2025-10-18 00:29:33 +08:00
VERSION 2.54.0
2022-03-20 13:16:04 +01:00
LANGUAGES C
2023-11-02 14:35:16 +08:00
DESCRIPTION "Fast neofetch-like system information tool"
2023-06-12 17:26:37 +02:00
HOMEPAGE_URL "https://github.com/fastfetch-cli/fastfetch"
2022-03-20 13:16:04 +01:00
)
2021-02-18 22:25:36 +01:00
2022-11-06 01:33:06 +08:00
set ( PROJECT_LICENSE "MIT license" )
2025-09-25 16:15:02 +08:00
if ( DEFINED CMAKE_SYSTEM_PROCESSOR_OVERRIDE ) # Used by github actions for i686 build
set ( CMAKE_SYSTEM_PROCESSOR ${ CMAKE_SYSTEM_PROCESSOR_OVERRIDE } CACHE INTERNAL "" )
endif ()
string ( TOLOWER "${CMAKE_SYSTEM_PROCESSOR}" CMAKE_SYSTEM_PROCESSOR )
if ( CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64" )
set ( CMAKE_SYSTEM_PROCESSOR "amd64" )
elseif ( CMAKE_SYSTEM_PROCESSOR STREQUAL "arm64" )
set ( CMAKE_SYSTEM_PROCESSOR "aarch64" )
endif ()
message ( STATUS "Build for system processor: ${CMAKE_SYSTEM_PROCESSOR}" )
2022-09-05 18:30:30 +02:00
###################
# Target Platform #
###################
2022-11-25 19:17:37 +08:00
if ( ANDROID )
set ( LINUX FALSE )
2024-05-26 07:50:30 +08:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "Linux" )
2022-09-19 22:23:31 +02:00
set ( LINUX TRUE CACHE BOOL "..." FORCE ) # LINUX means GNU/Linux, not just the kernel
2024-05-26 07:50:30 +08:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "FreeBSD" )
2024-08-05 08:54:25 +08:00
set ( FreeBSD TRUE CACHE BOOL "..." FORCE )
2024-10-04 15:58:17 +08:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "OpenBSD" )
set ( OpenBSD TRUE CACHE BOOL "..." FORCE )
2024-11-05 11:17:23 -05:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "MidnightBSD" )
set ( FreeBSD TRUE CACHE BOOL "..." FORCE )
set ( MidnightBSD TRUE CACHE BOOL "..." FORCE )
2024-10-27 11:43:36 +08:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "NetBSD" )
set ( NetBSD TRUE CACHE BOOL "..." FORCE )
2024-11-03 08:35:11 +08:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "DragonFly" )
set ( FreeBSD TRUE CACHE BOOL "..." FORCE )
set ( DragonFly TRUE CACHE BOOL "..." FORCE )
2024-06-16 01:02:48 +08:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "SunOS" )
set ( SunOS TRUE CACHE BOOL "..." FORCE )
2025-02-05 02:08:28 +01:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "Haiku" )
set ( Haiku TRUE CACHE BOOL "..." FORCE )
2025-05-19 15:07:46 +00:00
elseif ( "${CMAKE_SYSTEM_NAME}" STREQUAL "GNU" )
set ( GNU TRUE CACHE BOOL "..." FORCE )
2022-11-25 19:17:37 +08:00
elseif ( NOT APPLE AND NOT WIN32 )
2022-10-02 17:52:09 +08:00
message ( FATAL_ERROR "Unsupported platform: ${CMAKE_SYSTEM_NAME}" )
2022-09-05 18:30:30 +02:00
endif ()
2022-10-12 14:13:20 +08:00
#############################
# Compile time dependencies #
#############################
2022-10-13 18:12:54 +08:00
set ( THREADS_PREFER_PTHREAD_FLAG NOT WIN32 )
2022-10-12 14:13:20 +08:00
find_package ( Threads )
2022-11-24 18:10:49 +01:00
find_package ( PkgConfig )
if ( NOT PKG_CONFIG_FOUND )
message ( WARNING "pkg-config not found, library detection might be limited" )
endif ()
2022-10-12 14:13:20 +08:00
include ( CheckIncludeFile )
2022-06-08 16:25:14 +02:00
#####################
# Configure options #
#####################
2022-02-21 11:40:33 +05:00
2022-09-05 19:56:00 +02:00
include ( CMakeDependentOption )
2025-08-24 12:05:14 +01:00
cmake_dependent_option ( ENABLE_VULKAN "Enable vulkan" ON "LINUX OR APPLE OR FreeBSD OR OpenBSD OR NetBSD OR WIN32 OR ANDROID OR SunOS OR Haiku OR GNU" OFF )
cmake_dependent_option ( ENABLE_WAYLAND "Enable wayland-client" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR GNU" OFF )
2025-09-01 09:59:24 +08:00
cmake_dependent_option ( ENABLE_XCB_RANDR "Enable xcb-randr" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR ANDROID OR SunOS OR GNU" OFF )
cmake_dependent_option ( ENABLE_XRANDR "Enable xrandr" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR ANDROID OR SunOS OR GNU" OFF )
2025-08-24 12:05:14 +01:00
cmake_dependent_option ( ENABLE_DRM "Enable libdrm" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR SunOS OR GNU" OFF )
cmake_dependent_option ( ENABLE_DRM_AMDGPU "Enable libdrm_amdgpu" ON "LINUX OR FreeBSD OR GNU" OFF )
2025-09-01 09:59:24 +08:00
cmake_dependent_option ( ENABLE_GIO "Enable gio-2.0" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR ANDROID OR SunOS OR GNU" OFF )
cmake_dependent_option ( ENABLE_DCONF "Enable dconf" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR ANDROID OR SunOS OR GNU" OFF )
cmake_dependent_option ( ENABLE_DBUS "Enable dbus-1" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR ANDROID OR SunOS OR Haiku OR GNU" OFF )
2025-08-24 12:05:14 +01:00
cmake_dependent_option ( ENABLE_SQLITE3 "Enable sqlite3" ON "LINUX OR FreeBSD OR APPLE OR OpenBSD OR NetBSD OR SunOS OR GNU" OFF )
cmake_dependent_option ( ENABLE_RPM "Enable rpm" ON "LINUX OR GNU" OFF )
2025-09-01 09:59:24 +08:00
cmake_dependent_option ( ENABLE_IMAGEMAGICK7 "Enable imagemagick 7" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR APPLE OR ANDROID OR WIN32 OR SunOS OR Haiku OR GNU" OFF )
2025-08-24 12:05:14 +01:00
cmake_dependent_option ( ENABLE_IMAGEMAGICK6 "Enable imagemagick 6" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR APPLE OR SunOS OR GNU" OFF )
2022-09-05 19:56:00 +02:00
cmake_dependent_option ( ENABLE_CHAFA "Enable chafa" ON "ENABLE_IMAGEMAGICK6 OR ENABLE_IMAGEMAGICK7" OFF )
2025-08-24 12:05:14 +01:00
cmake_dependent_option ( ENABLE_EGL "Enable egl" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR ANDROID OR WIN32 OR SunOS OR Haiku OR GNU" OFF )
cmake_dependent_option ( ENABLE_GLX "Enable glx" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR ANDROID OR SunOS OR GNU" OFF )
cmake_dependent_option ( ENABLE_OPENCL "Enable opencl" ON "LINUX OR FreeBSD OR OpenBSD OR NetBSD OR WIN32 OR ANDROID OR SunOS OR Haiku OR GNU" OFF )
2022-09-26 23:07:18 +08:00
cmake_dependent_option ( ENABLE_FREETYPE "Enable freetype" ON "ANDROID" OFF )
2025-09-01 09:59:24 +08:00
cmake_dependent_option ( ENABLE_PULSE "Enable pulse" ON "LINUX OR ANDROID OR GNU" OFF )
2023-07-09 17:22:04 +08:00
cmake_dependent_option ( ENABLE_DDCUTIL "Enable ddcutil" ON "LINUX" OFF )
2023-09-20 23:55:36 +08:00
cmake_dependent_option ( ENABLE_DIRECTX_HEADERS "Enable DirectX headers for WSL" ON "LINUX" OFF )
2025-08-24 12:05:14 +01:00
cmake_dependent_option ( ENABLE_ELF "Enable libelf" ON "LINUX OR ANDROID OR DragonFly OR Haiku OR GNU" OFF )
2023-02-24 17:45:50 +08:00
cmake_dependent_option ( ENABLE_THREADS "Enable multithreading" ON "Threads_FOUND" OFF )
2024-08-31 12:34:36 +08:00
cmake_dependent_option ( ENABLE_LIBZFS "Enable libzfs" ON "LINUX OR FreeBSD OR SunOS" OFF )
2025-11-01 17:26:49 +08:00
cmake_dependent_option ( ENABLE_PCIACCESS "Enable libpciaccess" ON "GNU" OFF )
2022-09-05 19:56:00 +02:00
2025-09-01 09:59:06 +08:00
option ( ENABLE_ZLIB "Enable zlib" ON )
2023-11-18 15:18:09 +01:00
option ( ENABLE_SYSTEM_YYJSON "Use system provided (instead of fastfetch embedded) yyjson library" OFF )
2023-10-31 14:57:32 +08:00
option ( ENABLE_ASAN "Build fastfetch with ASAN (address sanitizer)" OFF )
2024-07-03 16:10:34 +08:00
option ( ENABLE_LTO "Enable link-time optimization in release mode if supported" ON )
2024-12-21 16:53:02 +01:00
option ( BUILD_FLASHFETCH "Build flashfetch" ON ) # Also build the flashfetch binary
2022-09-05 19:56:00 +02:00
option ( BUILD_TESTS "Build tests" OFF ) # Also create test executables
option ( SET_TWEAK "Add tweak to project version" ON ) # This is set to off by github actions for release builds
2024-04-16 22:58:06 +08:00
option ( IS_MUSL "Build with musl libc" OFF ) # Used by Github Actions
2024-05-30 21:36:57 +08:00
option ( INSTALL_LICENSE "Install license into /usr/share/licenses" ON )
2024-09-25 16:41:55 +08:00
option ( ENABLE_EMBEDDED_PCIIDS "Embed pci.ids into fastfetch, requires `python`" OFF )
2025-02-13 10:43:11 +08:00
option ( ENABLE_EMBEDDED_AMDGPUIDS "Embed amdgpu.ids into fastfetch, requires `python`" OFF )
2025-10-16 15:29:24 +08:00
option ( ENABLE_WORDEXP "Enable using of wordexp(3) if available, instead of glob(3)" ON )
2022-06-08 16:25:14 +02:00
2024-05-24 14:40:14 +08:00
set ( BINARY_LINK_TYPE_OPTIONS dlopen dynamic static )
set ( BINARY_LINK_TYPE dlopen CACHE STRING "How to link fastfetch" )
set_property ( CACHE BINARY_LINK_TYPE PROPERTY STRINGS ${ BINARY_LINK_TYPE_OPTIONS } )
if ( NOT BINARY_LINK_TYPE IN_LIST BINARY_LINK_TYPE_OPTIONS )
message ( FATAL_ERROR "BINARY_LINK_TYPE must be one of ${BINARY_LINK_TYPE_OPTIONS}" )
endif ()
2025-04-05 21:39:27 +05:45
set ( PACKAGE_MANAGERS AM APK BREW CHOCO DPKG EMERGE EOPKG FLATPAK GUIX LINGLONG LPKG LPKGBUILD MACPORTS NIX OPKG PACMAN PACSTALL PALUDIS PISI PKG PKGTOOL RPM SCOOP SNAP SOAR SORCERY WINGET XBPS )
2024-09-13 15:45:53 +08:00
foreach ( package_manager ${ PACKAGE_MANAGERS } )
if ( package_manager STREQUAL "WINGET" )
option ( PACKAGES_DISABLE_ ${ package_manager } "Disable ${package_manager} package manager detection by default" ON )
else ()
option ( PACKAGES_DISABLE_ ${ package_manager } "Disable ${package_manager} package manager detection by default" OFF )
endif ()
endforeach ()
2024-02-27 15:20:02 +08:00
if ( LINUX )
set ( CUSTOM_PCI_IDS_PATH "" CACHE STRING "Custom path to file pci.ids, defaults to `/usr/share/hwdata/pci.ids`" )
2024-05-04 10:01:29 +08:00
set ( CUSTOM_AMDGPU_IDS_PATH "" CACHE STRING "Custom path to file amdgpu.ids, defaults to `/usr/share/libdrm/amdgpu.ids`" )
2024-05-06 16:25:08 +08:00
set ( CUSTOM_OS_RELEASE_PATH "" CACHE STRING "Custom path to file os-release, defaults to `/etc/os-release`" )
2024-02-27 15:20:02 +08:00
endif ()
2022-06-08 16:25:14 +02:00
####################
# Compiler options #
####################
2021-10-20 08:12:15 +00:00
if ( NOT CMAKE_BUILD_TYPE )
2023-06-09 22:38:55 +08:00
set ( CMAKE_BUILD_TYPE RelWithDebInfo )
2021-10-20 08:12:15 +00:00
endif ()
2021-03-07 20:05:00 +01:00
2022-09-22 23:10:34 +02:00
message ( STATUS "Build type: ${CMAKE_BUILD_TYPE}" )
2022-10-12 14:13:20 +08:00
if ( ENABLE_THREADS )
2022-10-13 18:12:54 +08:00
if ( CMAKE_USE_WIN32_THREADS_INIT )
2022-10-12 14:13:20 +08:00
message ( STATUS "Threads type: Win32 thread" )
2022-10-13 18:12:54 +08:00
elseif ( CMAKE_USE_PTHREADS_INIT )
message ( STATUS "Threads type: pthread" )
2022-10-12 14:13:20 +08:00
endif ()
else ()
message ( STATUS "Threads type: disabled" )
endif ()
2022-09-22 23:10:34 +02:00
2025-01-14 10:05:38 +08:00
set ( WARNING_FLAGS "-Wall -Wextra -Wconversion -Werror=uninitialized -Werror=return-type -Werror=vla" )
2023-06-12 21:18:22 +08:00
2022-06-08 15:52:55 +02:00
set ( CMAKE_C_STANDARD 11 )
2023-10-28 13:12:04 +08:00
set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNING_FLAGS} -Werror=incompatible-pointer-types -Werror=implicit-function-declaration -Werror=int-conversion" )
2022-09-18 15:53:51 +02:00
2025-02-11 09:15:14 +08:00
if ( WIN32 OR Haiku OR ENABLE_DIRECTX_HEADERS )
2023-06-23 11:41:22 +08:00
enable_language ( CXX )
2024-06-11 16:41:57 +08:00
set ( CMAKE_CXX_STANDARD 17 )
2024-06-11 19:48:25 +08:00
set ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${WARNING_FLAGS}" )
2023-09-20 23:55:36 +08:00
endif ()
if ( WIN32 )
2023-01-11 09:37:00 +08:00
set ( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--tsaware -Wl,--build-id -Wl,--subsystem,console:6.1,--major-os-version,6,--minor-os-version,1" )
2024-05-19 21:46:34 +08:00
elseif ( APPLE AND CMAKE_C_COMPILER_ID MATCHES "Clang" )
2024-01-03 09:41:02 +08:00
set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fobjc-arc" )
2022-10-05 00:41:43 +08:00
endif ()
2022-10-02 17:52:09 +08:00
set ( FASTFETCH_FLAGS_DEBUG "-fno-omit-frame-pointer" )
2023-10-31 14:57:32 +08:00
if ( ENABLE_ASAN )
message ( STATUS "Address sanitizer enabled (DEBUG only)" )
2023-09-25 16:40:26 +08:00
set ( FASTFETCH_FLAGS_DEBUG "${FASTFETCH_FLAGS_DEBUG} -fsanitize=address" )
2022-10-02 17:52:09 +08:00
endif ()
2022-09-18 15:53:51 +02:00
set ( CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} ${FASTFETCH_FLAGS_DEBUG}" )
2024-03-01 10:27:25 +08:00
set ( CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} ${FASTFETCH_FLAGS_DEBUG} -fstack-protector-all -fno-delete-null-pointer-checks" )
2023-02-25 13:30:31 +08:00
if ( NOT WIN32 )
set ( CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} -rdynamic" )
endif ()
2024-07-03 16:10:34 +08:00
if ( ENABLE_LTO AND NOT CMAKE_BUILD_TYPE STREQUAL "Debug" )
2023-09-20 23:55:36 +08:00
message ( STATUS "Enabling LTO" )
2022-10-11 13:15:43 +08:00
include ( CheckIPOSupported )
check_ipo_supported ( RESULT IPO_SUPPORTED )
if ( IPO_SUPPORTED )
set ( CMAKE_INTERPROCEDURAL_OPTIMIZATION TRUE )
endif ()
2022-06-08 16:25:14 +02:00
endif ()
#######################
# Target FS structure #
#######################
2022-04-10 15:07:52 +02:00
if ( NOT TARGET_DIR_ROOT )
2022-04-10 15:26:18 +02:00
if ( NOT ANDROID )
set ( TARGET_DIR_ROOT "" )
else ()
set ( TARGET_DIR_ROOT "/data/data/com.termux/files/usr" )
endif ()
2022-04-10 15:07:52 +02:00
endif ()
2022-04-10 15:26:18 +02:00
2022-04-10 15:07:52 +02:00
if ( NOT TARGET_DIR_USR )
2022-04-10 15:26:18 +02:00
if ( NOT ANDROID )
set ( TARGET_DIR_USR "${TARGET_DIR_ROOT}/usr" )
else ()
set ( TARGET_DIR_USR "${TARGET_DIR_ROOT}" )
endif ()
2022-04-10 15:07:52 +02:00
endif ()
2022-04-10 15:26:18 +02:00
2022-04-10 15:07:52 +02:00
if ( NOT TARGET_DIR_HOME )
2022-09-06 05:19:21 -07:00
if ( APPLE )
set ( TARGET_DIR_HOME "${TARGET_DIR_ROOT}/Users" )
elseif ( ANDROID )
2022-04-10 15:26:18 +02:00
set ( TARGET_DIR_HOME "/data/data/com.termux/files/home" )
2022-09-06 05:19:21 -07:00
else ()
set ( TARGET_DIR_HOME "${TARGET_DIR_ROOT}/home" )
2022-04-10 15:26:18 +02:00
endif ()
2022-04-10 15:07:52 +02:00
endif ()
2022-10-01 22:53:11 +08:00
if ( NOT TARGET_DIR_ETC )
2022-10-09 10:39:57 +02:00
set ( TARGET_DIR_ETC "${TARGET_DIR_ROOT}/etc" )
endif ()
2023-02-21 21:40:55 +08:00
message ( STATUS "Target dirs: ROOT=\" ${ TARGET_DIR_ROOT } \" USR=\ "${TARGET_DIR_USR}\" HOME=\ "${TARGET_DIR_HOME}\" ETC=\ "${TARGET_DIR_ETC}\"")
2023-02-21 21:38:10 +08:00
2022-10-09 10:39:57 +02:00
#https://cmake.org/cmake/help/latest/variable/CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT.html
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
set(CMAKE_INSTALL_PREFIX " ${ TARGET_DIR_USR } " CACHE PATH " ... " FORCE)
endif()
if(NOT CMAKE_INSTALL_SYSCONFDIR)
set(CMAKE_INSTALL_SYSCONFDIR " ${ TARGET_DIR_ETC } " CACHE PATH " ... " FORCE)
2022-10-01 22:53:11 +08:00
endif()
2022-06-08 16:25:14 +02:00
#################
# Tweak version #
#################
2021-10-22 21:53:29 +02:00
2022-04-10 15:07:52 +02:00
if (SET_TWEAK AND EXISTS " ${ CMAKE_SOURCE_DIR } /.git ")
execute_process(
COMMAND git describe --tags
WORKING_DIRECTORY " ${ CMAKE_SOURCE_DIR } "
2024-08-09 09:52:53 +08:00
OUTPUT_VARIABLE PROJECT_VERSION_GIT
2022-04-10 15:07:52 +02:00
OUTPUT_STRIP_TRAILING_WHITESPACE
)
2024-08-09 09:52:53 +08:00
string(REGEX MATCH " -[0-9]+ " PROJECT_VERSION_TWEAK " ${ PROJECT_VERSION_GIT } ")
2022-04-10 15:07:52 +02:00
endif()
2022-12-08 18:33:43 +08:00
if(PROJECT_VERSION_TWEAK)
string(REGEX MATCH " [0-9]+ " PROJECT_VERSION_TWEAK_NUM " ${ PROJECT_VERSION_TWEAK } ")
else()
set(PROJECT_VERSION_TWEAK_NUM 0)
endif()
2022-04-10 15:07:52 +02:00
2022-06-08 16:25:14 +02:00
#############
# Text data #
#############
2023-11-21 11:03:43 +08:00
function(fastfetch_encode_c_string STR OUTVAR)
2023-12-06 23:55:34 +08:00
string(REGEX REPLACE " \n$" "" TEMP "${STR}" ) # Remove trailing newline
2023-11-20 16:37:59 +08:00
string ( REPLACE "\\" "\\\\" TEMP "${TEMP}" ) # Escape backslashes
string ( REPLACE "\n" "\\n" TEMP "${TEMP}" ) # Replace newlines with \n
string ( REPLACE "\"" " \\\"" TEMP "${TEMP}" ) # Replace quotes with \"
set ( ${ OUTVAR } "\" ${ TEMP } \"" PARENT_SCOPE )
2023-11-21 11:03:43 +08:00
endfunction ( fastfetch_encode_c_string )
function ( fastfetch_load_text FILENAME OUTVAR )
file ( READ "${FILENAME}" TEMP )
fastfetch_encode_c_string ( "${TEMP}" TEMP )
set ( ${ OUTVAR } "${TEMP}" PARENT_SCOPE )
endfunction ( fastfetch_load_text )
find_package ( Python )
if ( Python_FOUND )
2024-11-13 10:24:57 +08:00
message ( STATUS "Minifying 'help.json'" )
2023-12-06 23:55:34 +08:00
execute_process ( COMMAND ${ Python_EXECUTABLE } -c "import json,sys;json.dump(json.load(sys.stdin),sys.stdout,separators=(',',':'))"
2023-11-21 11:03:43 +08:00
INPUT_FILE "${CMAKE_CURRENT_SOURCE_DIR}/src/data/help.json"
OUTPUT_VARIABLE DATATEXT_JSON_HELP )
2023-12-07 23:51:56 +08:00
if ( DATATEXT_JSON_HELP STREQUAL "" )
message ( ERROR "DATATEXT_JSON_HELP is empty, which should not happen!" )
endif ()
2023-11-21 11:03:43 +08:00
else ()
2024-11-13 10:24:57 +08:00
message ( WARNING "Python3 is not found, 'help.json' will not be minified" )
2023-12-07 23:51:56 +08:00
file ( READ "src/data/help.json" DATATEXT_JSON_HELP )
2023-11-21 11:03:43 +08:00
endif ()
2023-11-20 16:37:59 +08:00
2024-11-18 13:35:10 +08:00
if ( ENABLE_EMBEDDED_PCIIDS AND NOT EXISTS "${PROJECT_BINARY_DIR}/fastfetch_pciids.c.inc" )
2024-09-25 16:41:55 +08:00
if ( Python_FOUND )
2025-02-12 16:16:59 +08:00
if ( NOT EXISTS "${PROJECT_BINARY_DIR}/pci.ids" )
message ( STATUS "'${PROJECT_BINARY_DIR}/pci.ids' is missing, downloading..." )
file ( DOWNLOAD "https://pci-ids.ucw.cz/v2.2/pci.ids" "${PROJECT_BINARY_DIR}/pci.ids" )
endif ()
2024-11-13 10:24:57 +08:00
message ( STATUS "Generating 'fastfetch_pciids.c.inc'" )
2025-02-12 16:16:59 +08:00
execute_process ( COMMAND ${ Python_EXECUTABLE } "${CMAKE_CURRENT_SOURCE_DIR}/scripts/gen-pciids.py" "${PROJECT_BINARY_DIR}/pci.ids"
2024-11-18 14:08:53 +08:00
OUTPUT_FILE "${PROJECT_BINARY_DIR}/fastfetch_pciids.c.inc"
RESULT_VARIABLE PYTHON_PCIIDS_RETCODE )
if ( NOT PYTHON_PCIIDS_RETCODE EQUAL 0 )
2025-02-12 16:16:59 +08:00
file ( REMOVE "${PROJECT_BINARY_DIR}/fastfetch_pciids.c.inc" )
2024-11-18 14:08:53 +08:00
message ( FATAL_ERROR "Failed to generate 'fastfetch_pciids.c.inc'" )
endif ()
2024-09-25 16:41:55 +08:00
else ()
2024-11-13 10:24:57 +08:00
message ( WARNING "Python3 is not found, 'fastfetch_pciids.c.inc' will not be generated" )
2024-09-25 16:41:55 +08:00
set ( ENABLE_EMBEDDED_PCIIDS OFF )
endif ()
endif ()
2025-02-13 10:43:11 +08:00
if ( ENABLE_EMBEDDED_AMDGPUIDS AND NOT EXISTS "${PROJECT_BINARY_DIR}/fastfetch_amdgpuids.c.inc" )
if ( Python_FOUND )
if ( NOT EXISTS "${PROJECT_BINARY_DIR}/amdgpu.ids" )
message ( STATUS "'${PROJECT_BINARY_DIR}/amdgpu.ids' is missing, downloading..." )
file ( DOWNLOAD "https://gitlab.freedesktop.org/mesa/drm/-/raw/main/data/amdgpu.ids" "${PROJECT_BINARY_DIR}/amdgpu.ids" )
endif ()
message ( STATUS "Generating 'fastfetch_amdgpuids.c.inc'" )
execute_process ( COMMAND ${ Python_EXECUTABLE } "${CMAKE_CURRENT_SOURCE_DIR}/scripts/gen-amdgpuids.py" "${PROJECT_BINARY_DIR}/amdgpu.ids"
OUTPUT_FILE "${PROJECT_BINARY_DIR}/fastfetch_amdgpuids.c.inc"
RESULT_VARIABLE PYTHON_AMDGPUIDS_RETCODE )
if ( NOT PYTHON_AMDGPUIDS_RETCODE EQUAL 0 )
file ( REMOVE "${PROJECT_BINARY_DIR}/fastfetch_amdgpuids.c.inc" )
message ( FATAL_ERROR "Failed to generate 'fastfetch_amdgpuids.c.inc'" )
endif ()
else ()
message ( WARNING "Python3 is not found, 'fastfetch_amdgpuids.c.inc' will not be generated" )
set ( ENABLE_EMBEDDED_AMDGPUIDS OFF )
endif ()
endif ()
2024-11-13 10:24:57 +08:00
if ( Python_FOUND )
message ( STATUS "Generating 'fastfetch.1'" )
execute_process ( COMMAND ${ Python_EXECUTABLE } "${CMAKE_CURRENT_SOURCE_DIR}/scripts/gen-man.py"
2024-11-18 14:08:53 +08:00
OUTPUT_FILE "${PROJECT_BINARY_DIR}/fastfetch.1"
RESULT_VARIABLE PYTHON_MANPAGE_RETCODE )
if ( NOT PYTHON_MANPAGE_RETCODE EQUAL 0 )
message ( FATAL_ERROR "Failed to generate 'fastfetch.1'" )
endif ()
2024-11-13 10:24:57 +08:00
else ()
message ( WARNING "Python3 is not found, use basic 'fastfetch.1.in' instead" )
string ( TIMESTAMP FASTFETCH_BUILD_DATE "%d %B %Y" UTC )
configure_file ( doc/fastfetch.1.in fastfetch.1 @ONLY )
endif ()
2023-11-21 11:03:43 +08:00
fastfetch_encode_c_string ( "${DATATEXT_JSON_HELP}" DATATEXT_JSON_HELP )
2021-10-23 14:59:11 +02:00
fastfetch_load_text ( src/data/structure.txt DATATEXT_STRUCTURE )
2021-10-22 21:53:29 +02:00
2023-07-28 14:12:48 +08:00
configure_file ( src/fastfetch_config.h.in fastfetch_config.h @ONLY )
configure_file ( src/fastfetch_datatext.h.in fastfetch_datatext.h @ONLY )
2023-10-11 15:17:14 +08:00
if ( APPLE )
configure_file ( src/util/apple/Info.plist.in Info.plist @ONLY )
endif ()
2022-06-08 16:25:14 +02:00
2023-07-28 14:12:48 +08:00
####################
# Ascii image data #
####################
2025-07-15 11:02:31 +08:00
file ( GLOB LOGO_FILES CONFIGURE_DEPENDS "src/logo/ascii/*.txt" )
2023-12-04 15:00:25 +08:00
set ( LOGO_BUILTIN_H "#pragma once\n#pragma GCC diagnostic ignored \" -Wtrigraphs\ "\n\n" )
2023-07-28 14:12:48 +08:00
foreach ( file ${ LOGO_FILES } )
2023-11-21 11:03:43 +08:00
fastfetch_load_text ( "${file}" content )
2024-04-25 15:48:39 +08:00
get_filename_component ( file "${file}" NAME_WE )
2023-07-28 14:12:48 +08:00
string ( TOUPPER "${file}" file )
2023-07-29 20:47:02 +08:00
set ( LOGO_BUILTIN_H "${LOGO_BUILTIN_H}#define FASTFETCH_DATATEXT_LOGO_${file} ${content}\n" )
2023-07-28 14:12:48 +08:00
endforeach ()
2023-07-29 20:47:02 +08:00
file ( GENERATE OUTPUT logo_builtin.h CONTENT "${LOGO_BUILTIN_H}" )
2021-03-06 11:28:38 +01:00
2022-06-08 16:25:14 +02:00
#######################
# libfastfetch target #
#######################
2022-02-21 11:40:33 +05:00
2022-09-04 12:43:30 +02:00
set ( LIBFASTFETCH_SRC
2023-08-17 16:00:24 +08:00
src/common/commandoption.c
2025-07-30 14:30:36 +08:00
src/common/duration.c
2022-04-08 15:50:49 +02:00
src/common/font.c
2022-02-09 15:20:07 +01:00
src/common/format.c
2025-07-30 14:30:36 +08:00
src/common/frequency.c
2022-11-20 18:14:32 +01:00
src/common/init.c
2023-03-15 15:24:40 +08:00
src/common/jsonconfig.c
2022-11-20 18:14:32 +01:00
src/common/library.c
2023-08-20 20:51:55 +08:00
src/common/modules.c
2023-09-26 21:49:01 +08:00
src/common/netif/netif.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_common.c
2023-03-07 14:56:13 +08:00
src/common/option.c
2022-02-09 15:20:07 +01:00
src/common/parsing.c
2025-07-30 14:30:36 +08:00
src/common/percent.c
2022-11-20 18:14:32 +01:00
src/common/printing.c
src/common/properties.c
2022-02-09 15:20:07 +01:00
src/common/settings.c
2025-07-30 14:30:36 +08:00
src/common/size.c
2024-02-26 16:39:41 +08:00
src/common/temps.c
2025-08-19 09:49:43 +08:00
src/common/time.c
2024-07-28 10:55:07 +08:00
src/detection/bluetoothradio/bluetoothradio.c
2024-05-15 21:36:15 +08:00
src/detection/bootmgr/bootmgr.c
2023-06-22 17:32:01 +08:00
src/detection/chassis/chassis.c
2022-09-04 22:20:12 +02:00
src/detection/cpu/cpu.c
2023-03-17 17:56:31 +08:00
src/detection/cpuusage/cpuusage.c
2022-11-20 18:14:32 +01:00
src/detection/disk/disk.c
2023-10-07 16:21:26 +08:00
src/detection/diskio/diskio.c
2022-11-20 18:14:32 +01:00
src/detection/displayserver/displayserver.c
2024-05-22 16:13:36 +08:00
src/detection/editor/editor.c
2022-11-20 18:14:32 +01:00
src/detection/font/font.c
2022-09-05 17:42:42 +02:00
src/detection/gpu/gpu.c
2022-11-20 18:14:32 +01:00
src/detection/media/media.c
2023-09-27 00:05:37 +08:00
src/detection/netio/netio.c
2023-04-25 19:03:20 +08:00
src/detection/opencl/opencl.c
2024-07-10 00:20:11 +08:00
src/detection/opengl/opengl_shared.c
2022-11-20 18:14:32 +01:00
src/detection/os/os.c
src/detection/packages/packages.c
2024-05-13 20:29:46 +08:00
src/detection/physicalmemory/physicalmemory.c
2023-09-13 16:20:50 +08:00
src/detection/publicip/publicip.c
2024-01-22 16:03:32 +08:00
src/detection/terminaltheme/terminaltheme.c
2022-09-18 15:53:51 +02:00
src/detection/terminalfont/terminalfont.c
2022-10-14 16:28:03 +08:00
src/detection/terminalshell/terminalshell.c
2023-08-21 09:19:16 +08:00
src/detection/version/version.c
2023-02-14 17:50:53 +08:00
src/detection/vulkan/vulkan.c
2023-09-13 18:31:22 +08:00
src/detection/weather/weather.c
2022-11-20 18:14:32 +01:00
src/logo/builtin.c
src/logo/image/im6.c
src/logo/image/im7.c
src/logo/image/image.c
src/logo/logo.c
2023-03-07 16:13:53 +08:00
src/modules/battery/battery.c
2023-03-10 14:48:09 +08:00
src/modules/bios/bios.c
2023-03-13 17:36:48 +08:00
src/modules/bluetooth/bluetooth.c
2024-07-28 00:05:07 +08:00
src/modules/bluetoothradio/bluetoothradio.c
2023-03-13 18:54:57 +08:00
src/modules/board/board.c
2024-05-15 21:36:15 +08:00
src/modules/bootmgr/bootmgr.c
2023-03-14 15:29:47 +08:00
src/modules/brightness/brightness.c
2023-03-13 19:01:08 +08:00
src/modules/break/break.c
2024-09-14 16:18:35 +08:00
src/modules/btrfs/btrfs.c
2024-02-02 15:09:54 +08:00
src/modules/camera/camera.c
2023-06-09 10:08:04 +08:00
src/modules/chassis/chassis.c
2023-03-15 17:02:54 +08:00
src/modules/colors/colors.c
2023-03-15 18:17:24 +08:00
src/modules/cpu/cpu.c
2024-06-05 11:02:26 +08:00
src/modules/cpucache/cpucache.c
2023-03-17 17:56:31 +08:00
src/modules/cpuusage/cpuusage.c
2023-03-20 14:57:46 +08:00
src/modules/cursor/cursor.c
2023-03-20 15:46:00 +08:00
src/modules/custom/custom.c
2023-03-07 19:27:49 +08:00
src/modules/command/command.c
2023-03-09 19:38:03 +08:00
src/modules/datetime/datetime.c
2023-06-07 10:39:53 +08:00
src/modules/de/de.c
2023-04-02 00:13:11 +08:00
src/modules/disk/disk.c
2023-10-07 16:21:26 +08:00
src/modules/diskio/diskio.c
2024-06-12 14:47:58 +08:00
src/modules/dns/dns.c
2024-05-22 16:13:36 +08:00
src/modules/editor/editor.c
2023-04-04 12:28:52 +08:00
src/modules/font/font.c
2023-03-26 20:42:18 +08:00
src/modules/gpu/gpu.c
2023-03-10 11:26:53 +08:00
src/modules/host/host.c
2023-06-07 09:49:38 +08:00
src/modules/icons/icons.c
2024-05-28 23:46:13 +08:00
src/modules/initsystem/initsystem.c
2023-04-04 11:01:42 +08:00
src/modules/gamepad/gamepad.c
2023-03-10 14:14:32 +08:00
src/modules/kernel/kernel.c
2024-10-09 09:45:09 +08:00
src/modules/keyboard/keyboard.c
2023-06-20 23:01:18 +08:00
src/modules/lm/lm.c
2024-05-08 16:41:33 +08:00
src/modules/loadavg/loadavg.c
2023-04-04 17:47:42 +08:00
src/modules/locale/locale.c
2023-04-04 20:46:50 +08:00
src/modules/localip/localip.c
2023-05-11 21:07:04 +08:00
src/modules/memory/memory.c
2024-10-01 12:10:15 +08:00
src/modules/monitor/monitor.c
2023-09-27 00:05:37 +08:00
src/modules/netio/netio.c
2023-06-07 15:10:44 +08:00
src/modules/opencl/opencl.c
2023-06-07 14:44:27 +08:00
src/modules/opengl/opengl.c
2023-03-07 14:56:13 +08:00
src/modules/os/os.c
2023-05-26 14:32:27 +08:00
src/modules/packages/packages.c
2023-12-18 10:43:20 +08:00
src/modules/physicaldisk/physicaldisk.c
2024-05-10 23:47:15 +08:00
src/modules/physicalmemory/physicalmemory.c
2023-06-09 10:24:20 +08:00
src/modules/processes/processes.c
2023-06-07 16:19:07 +08:00
src/modules/player/player.c
2023-06-05 16:57:55 +08:00
src/modules/poweradapter/poweradapter.c
2023-06-08 09:41:22 +08:00
src/modules/publicip/publicip.c
2023-03-10 10:56:36 +08:00
src/modules/display/display.c
2023-03-09 17:00:37 +08:00
src/modules/separator/separator.c
2023-06-01 11:37:52 +08:00
src/modules/shell/shell.c
2023-04-12 14:05:09 +08:00
src/modules/sound/sound.c
2023-05-11 21:07:04 +08:00
src/modules/swap/swap.c
2023-06-07 16:10:14 +08:00
src/modules/media/media.c
2024-10-09 09:45:09 +08:00
src/modules/mouse/mouse.c
2023-06-02 16:07:01 +08:00
src/modules/terminal/terminal.c
2024-01-22 16:03:32 +08:00
src/modules/terminaltheme/terminaltheme.c
2023-06-02 16:28:58 +08:00
src/modules/terminalfont/terminalfont.c
2023-07-26 10:27:40 +08:00
src/modules/terminalsize/terminalsize.c
2023-06-09 08:48:46 +08:00
src/modules/theme/theme.c
2023-03-09 18:11:03 +08:00
src/modules/title/title.c
2024-09-25 22:55:57 +08:00
src/modules/tpm/tpm.c
2023-04-25 19:57:27 +08:00
src/modules/uptime/uptime.c
2023-06-07 15:23:01 +08:00
src/modules/users/users.c
2023-08-21 09:19:16 +08:00
src/modules/version/version.c
2023-06-07 15:16:09 +08:00
src/modules/vulkan/vulkan.c
2023-06-07 10:14:08 +08:00
src/modules/wallpaper/wallpaper.c
2023-06-08 11:33:33 +08:00
src/modules/weather/weather.c
2023-05-23 15:30:59 +08:00
src/modules/wifi/wifi.c
2023-06-07 10:50:52 +08:00
src/modules/wm/wm.c
2023-04-28 19:11:55 +08:00
src/modules/wmtheme/wmtheme.c
2024-08-28 10:55:04 +08:00
src/modules/zpool/zpool.c
2023-10-26 10:26:15 +08:00
src/options/display.c
2023-10-25 10:44:34 +08:00
src/options/logo.c
2023-10-25 13:39:13 +08:00
src/options/general.c
2023-08-08 20:23:26 +08:00
src/util/edidHelper.c
2024-07-05 16:14:56 +08:00
src/util/base64.c
2022-11-20 18:14:32 +01:00
src/util/FFlist.c
src/util/FFstrbuf.c
2024-09-27 08:36:38 +08:00
src/util/kmod.c
2024-08-20 16:37:54 +08:00
src/util/path.c
2023-01-15 15:57:26 +01:00
src/util/platform/FFPlatform.c
2023-06-22 10:45:43 +00:00
src/util/smbiosHelper.c
2022-02-09 15:20:07 +01:00
)
2022-02-08 07:10:46 +02:00
2022-11-20 18:14:32 +01:00
if ( LINUX )
2022-10-08 16:04:55 +08:00
list ( APPEND LIBFASTFETCH_SRC
2023-01-24 10:39:33 +01:00
src/common/dbus.c
2023-01-28 12:40:12 +01:00
src/common/io/io_unix.c
2023-09-26 16:26:15 +08:00
src/common/netif/netif_linux.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2022-11-20 18:14:32 +01:00
src/common/processing_linux.c
src/detection/battery/battery_linux.c
src/detection/bios/bios_linux.c
src/detection/board/board_linux.c
2024-05-15 21:36:15 +08:00
src/detection/bootmgr/bootmgr_linux.c
2023-01-09 19:09:22 +08:00
src/detection/brightness/brightness_linux.c
2024-09-14 16:18:35 +08:00
src/detection/btrfs/btrfs_linux.c
2022-12-24 22:48:10 +08:00
src/detection/chassis/chassis_linux.c
2022-11-20 18:14:32 +01:00
src/detection/cpu/cpu_linux.c
2024-06-05 11:02:26 +08:00
src/detection/cpucache/cpucache_linux.c
2023-03-17 17:56:31 +08:00
src/detection/cpuusage/cpuusage_linux.c
2022-11-23 12:10:45 +08:00
src/detection/cursor/cursor_linux.c
2023-01-24 10:39:33 +01:00
src/detection/bluetooth/bluetooth_linux.c
2024-07-28 10:55:07 +08:00
src/detection/bluetoothradio/bluetoothradio_linux.c
2022-11-20 18:14:32 +01:00
src/detection/disk/disk_linux.c
2024-06-12 14:47:58 +08:00
src/detection/dns/dns_linux.c
2023-12-18 10:43:20 +08:00
src/detection/physicaldisk/physicaldisk_linux.c
2024-05-11 08:14:56 +00:00
src/detection/physicalmemory/physicalmemory_linux.c
2023-10-07 16:21:26 +08:00
src/detection/diskio/diskio_linux.c
2022-11-20 18:14:32 +01:00
src/detection/displayserver/linux/displayserver_linux.c
2025-09-01 09:59:24 +08:00
src/detection/displayserver/linux/common.c
2023-11-29 14:55:40 +08:00
src/detection/displayserver/linux/drm.c
2024-04-21 23:21:13 +08:00
src/detection/displayserver/linux/wayland/wayland.c
src/detection/displayserver/linux/wayland/global-output.c
src/detection/displayserver/linux/wayland/zwlr-output.c
2024-07-05 16:14:56 +08:00
src/detection/displayserver/linux/wayland/kde-output.c
2024-04-21 23:21:13 +08:00
src/detection/displayserver/linux/wayland/wlr-output-management-unstable-v1-protocol.c
2024-07-05 16:14:56 +08:00
src/detection/displayserver/linux/wayland/kde-output-device-v2-protocol.c
2024-07-05 16:54:43 +08:00
src/detection/displayserver/linux/wayland/kde-output-order-v1-protocol.c
2024-07-05 23:10:42 +08:00
src/detection/displayserver/linux/wayland/xdg-output-unstable-v1-protocol.c
2022-11-20 18:14:32 +01:00
src/detection/displayserver/linux/wmde.c
src/detection/displayserver/linux/xcb.c
src/detection/displayserver/linux/xlib.c
src/detection/font/font_linux.c
src/detection/gpu/gpu_linux.c
2025-06-18 10:01:32 +08:00
src/detection/gpu/gpu_drm.c
2024-02-11 23:01:14 +08:00
src/detection/gpu/gpu_pci.c
2023-02-14 17:46:21 +08:00
src/detection/gtk_qt/gtk.c
2022-11-20 18:14:32 +01:00
src/detection/host/host_linux.c
2024-12-06 18:31:33 +08:00
src/detection/host/host_mac.c
2023-06-06 11:26:29 +08:00
src/detection/icons/icons_linux.c
2024-05-28 23:46:13 +08:00
src/detection/initsystem/initsystem_linux.c
2024-10-09 09:45:09 +08:00
src/detection/keyboard/keyboard_linux.c
2023-10-05 19:06:15 +08:00
src/detection/libc/libc_linux.c
2023-06-20 23:01:18 +08:00
src/detection/lm/lm_linux.c
2024-05-08 16:41:33 +08:00
src/detection/loadavg/loadavg_linux.c
2024-01-15 14:50:47 +08:00
src/detection/locale/locale_linux.c
2022-10-08 22:48:13 +08:00
src/detection/localip/localip_linux.c
2023-02-01 21:28:42 +08:00
src/detection/gamepad/gamepad_linux.c
2022-11-20 18:14:32 +01:00
src/detection/media/media_linux.c
src/detection/memory/memory_linux.c
2024-10-09 09:45:09 +08:00
src/detection/mouse/mouse_linux.c
2023-09-27 00:05:37 +08:00
src/detection/netio/netio_linux.c
2022-11-20 18:14:32 +01:00
src/detection/opengl/opengl_linux.c
src/detection/os/os_linux.c
src/detection/packages/packages_linux.c
2025-08-12 19:25:10 +08:00
src/detection/packages/packages_nix.c
2024-01-04 13:54:11 +08:00
src/detection/poweradapter/poweradapter_linux.c
2022-11-20 18:14:32 +01:00
src/detection/processes/processes_linux.c
2023-02-14 17:46:21 +08:00
src/detection/gtk_qt/qt.c
2023-01-26 00:49:43 +08:00
src/detection/sound/sound_linux.c
2022-11-20 18:14:32 +01:00
src/detection/swap/swap_linux.c
src/detection/terminalfont/terminalfont_linux.c
src/detection/terminalshell/terminalshell_linux.c
2023-07-26 10:27:40 +08:00
src/detection/terminalsize/terminalsize_linux.c
2023-06-08 14:32:15 +08:00
src/detection/theme/theme_linux.c
2024-09-25 22:55:57 +08:00
src/detection/tpm/tpm_linux.c
2022-11-20 18:14:32 +01:00
src/detection/uptime/uptime_linux.c
src/detection/users/users_linux.c
2023-06-06 20:43:38 +08:00
src/detection/wallpaper/wallpaper_linux.c
2022-12-02 22:34:56 +08:00
src/detection/wifi/wifi_linux.c
2025-01-02 11:13:28 +09:00
src/detection/wm/wm_linux.c
2023-10-30 22:46:38 +08:00
src/detection/de/de_linux.c
2022-11-20 18:14:32 +01:00
src/detection/wmtheme/wmtheme_linux.c
2024-02-02 22:14:25 +08:00
src/detection/camera/camera_linux.c
2024-08-28 10:55:04 +08:00
src/detection/zpool/zpool_linux.c
2023-01-15 15:57:26 +01:00
src/util/platform/FFPlatform_unix.c
2024-08-21 15:31:47 +08:00
src/util/binary_linux.c
2022-10-08 16:04:55 +08:00
)
2022-11-20 18:14:32 +01:00
elseif ( ANDROID )
2022-09-19 22:23:31 +02:00
list ( APPEND LIBFASTFETCH_SRC
2025-09-01 09:59:24 +08:00
src/common/dbus.c
2023-01-28 12:40:12 +01:00
src/common/io/io_unix.c
2023-09-26 16:26:15 +08:00
src/common/netif/netif_linux.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2022-11-20 18:14:32 +01:00
src/common/processing_linux.c
2023-01-21 14:45:36 +08:00
src/detection/battery/battery_android.c
2023-07-27 22:50:19 +08:00
src/detection/bios/bios_android.c
2023-01-24 10:46:00 +01:00
src/detection/bluetooth/bluetooth_nosupport.c
2024-07-28 00:05:07 +08:00
src/detection/bluetoothradio/bluetoothradio_nosupport.c
2023-07-27 19:47:26 +08:00
src/detection/board/board_android.c
2024-05-18 11:08:21 +08:00
src/detection/bootmgr/bootmgr_nosupport.c
2023-01-09 18:59:02 +08:00
src/detection/brightness/brightness_nosupport.c
2024-09-14 16:18:35 +08:00
src/detection/btrfs/btrfs_nosupport.c
2022-12-24 22:48:10 +08:00
src/detection/chassis/chassis_nosupport.c
2022-09-19 22:23:31 +02:00
src/detection/cpu/cpu_linux.c
2024-06-05 11:02:26 +08:00
src/detection/cpucache/cpucache_linux.c
2025-09-01 09:59:24 +08:00
src/detection/cursor/cursor_linux.c
2023-03-17 17:56:31 +08:00
src/detection/cpuusage/cpuusage_linux.c
2022-10-27 14:58:29 +08:00
src/detection/disk/disk_linux.c
2024-06-12 15:34:27 +08:00
src/detection/dns/dns_linux.c
2023-12-18 10:43:20 +08:00
src/detection/physicaldisk/physicaldisk_linux.c
2024-05-10 23:47:15 +08:00
src/detection/physicalmemory/physicalmemory_nosupport.c
2023-10-08 09:51:13 +08:00
src/detection/diskio/diskio_linux.c
2023-07-19 13:59:40 +08:00
src/detection/displayserver/displayserver_android.c
2025-09-01 09:59:24 +08:00
src/detection/displayserver/linux/common.c
src/detection/displayserver/linux/wmde.c
src/detection/displayserver/linux/xcb.c
src/detection/displayserver/linux/xlib.c
src/detection/gtk_qt/gtk.c
src/detection/gtk_qt/qt.c
src/detection/font/font_linux.c
2025-08-28 14:24:40 +08:00
src/detection/gpu/gpu_android.c
2022-11-20 18:14:32 +01:00
src/detection/host/host_android.c
2025-09-01 09:59:24 +08:00
src/detection/icons/icons_linux.c
2024-05-28 23:46:13 +08:00
src/detection/initsystem/initsystem_linux.c
2024-10-09 09:45:09 +08:00
src/detection/keyboard/keyboard_nosupport.c
2023-10-05 19:06:15 +08:00
src/detection/libc/libc_android.c
2023-06-20 23:01:18 +08:00
src/detection/lm/lm_nosupport.c
2024-05-08 16:41:33 +08:00
src/detection/loadavg/loadavg_linux.c
2024-01-15 14:50:47 +08:00
src/detection/locale/locale_linux.c
2022-11-20 18:14:32 +01:00
src/detection/localip/localip_linux.c
2023-02-01 14:01:39 +08:00
src/detection/gamepad/gamepad_nosupport.c
2025-09-01 09:59:24 +08:00
src/detection/media/media_linux.c
2022-09-19 22:23:31 +02:00
src/detection/memory/memory_linux.c
2024-10-09 09:45:09 +08:00
src/detection/mouse/mouse_nosupport.c
2023-09-27 15:34:53 +08:00
src/detection/netio/netio_linux.c
2022-11-20 18:14:32 +01:00
src/detection/opengl/opengl_linux.c
src/detection/os/os_android.c
src/detection/packages/packages_linux.c
2025-08-14 14:41:53 +08:00
src/detection/packages/packages_nix.c
2022-11-20 18:14:32 +01:00
src/detection/poweradapter/poweradapter_nosupport.c
2022-10-26 17:20:39 +08:00
src/detection/processes/processes_linux.c
2025-09-01 09:59:24 +08:00
src/detection/sound/sound_linux.c
2022-10-18 23:46:42 +08:00
src/detection/swap/swap_linux.c
2022-11-20 18:14:32 +01:00
src/detection/terminalfont/terminalfont_android.c
2025-09-01 09:59:24 +08:00
src/detection/terminalfont/terminalfont_linux.c
2022-11-20 18:14:32 +01:00
src/detection/terminalshell/terminalshell_linux.c
2023-07-26 10:27:40 +08:00
src/detection/terminalsize/terminalsize_linux.c
2025-09-01 09:59:24 +08:00
src/detection/theme/theme_linux.c
2024-09-25 22:55:57 +08:00
src/detection/tpm/tpm_nosupport.c
2022-10-26 17:03:46 +08:00
src/detection/uptime/uptime_linux.c
2022-11-20 18:14:32 +01:00
src/detection/users/users_linux.c
2025-09-01 09:59:24 +08:00
src/detection/wallpaper/wallpaper_linux.c
2023-01-21 14:45:36 +08:00
src/detection/wifi/wifi_android.c
2025-09-01 09:59:24 +08:00
src/detection/wm/wm_linux.c
src/detection/de/de_linux.c
src/detection/wmtheme/wmtheme_linux.c
2024-02-02 23:22:40 +08:00
src/detection/camera/camera_android.c
2024-08-28 10:55:04 +08:00
src/detection/zpool/zpool_nosupport.c
2023-01-15 15:57:26 +01:00
src/util/platform/FFPlatform_unix.c
2024-08-21 15:31:47 +08:00
src/util/binary_linux.c
2022-09-19 22:23:31 +02:00
)
2024-08-05 08:54:25 +08:00
elseif ( FreeBSD )
2022-09-19 22:23:31 +02:00
list ( APPEND LIBFASTFETCH_SRC
2023-01-24 10:46:00 +01:00
src/common/dbus.c
2023-01-28 12:40:12 +01:00
src/common/io/io_unix.c
2025-08-08 10:05:20 +08:00
src/common/netif/netif_bsd.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2022-11-20 18:14:32 +01:00
src/common/processing_linux.c
src/common/sysctl.c
2023-01-10 12:27:51 +08:00
src/detection/battery/battery_bsd.c
2022-12-29 20:12:14 +08:00
src/detection/bios/bios_bsd.c
2024-12-21 20:25:29 +08:00
src/detection/bluetoothradio/bluetoothradio_nosupport.c
2023-06-15 10:12:05 +08:00
src/detection/board/board_bsd.c
2024-05-16 10:59:10 +08:00
src/detection/bootmgr/bootmgr_bsd.c
2023-06-24 06:26:55 +00:00
src/detection/brightness/brightness_bsd.c
2024-09-14 16:18:35 +08:00
src/detection/btrfs/btrfs_nosupport.c
2023-06-15 10:15:31 +08:00
src/detection/chassis/chassis_bsd.c
2022-11-20 18:14:32 +01:00
src/detection/cpu/cpu_bsd.c
2024-06-21 15:21:55 +08:00
src/detection/cpucache/cpucache_shared.c
2023-03-17 17:56:31 +08:00
src/detection/cpuusage/cpuusage_bsd.c
2022-11-23 12:10:45 +08:00
src/detection/cursor/cursor_linux.c
2022-11-20 18:14:32 +01:00
src/detection/disk/disk_bsd.c
2024-06-12 14:47:58 +08:00
src/detection/dns/dns_linux.c
2023-12-18 10:43:20 +08:00
src/detection/physicaldisk/physicaldisk_bsd.c
2024-05-12 17:54:54 +08:00
src/detection/physicalmemory/physicalmemory_linux.c
2023-10-08 09:51:13 +08:00
src/detection/diskio/diskio_bsd.c
2022-11-24 18:54:52 +08:00
src/detection/displayserver/linux/displayserver_linux.c
2025-09-01 09:59:24 +08:00
src/detection/displayserver/linux/common.c
2023-12-03 12:10:52 +08:00
src/detection/displayserver/linux/drm.c
2024-04-21 23:21:13 +08:00
src/detection/displayserver/linux/wayland/wayland.c
src/detection/displayserver/linux/wayland/global-output.c
src/detection/displayserver/linux/wayland/zwlr-output.c
2024-07-05 16:14:56 +08:00
src/detection/displayserver/linux/wayland/kde-output.c
2024-04-21 23:21:13 +08:00
src/detection/displayserver/linux/wayland/wlr-output-management-unstable-v1-protocol.c
2024-07-05 16:14:56 +08:00
src/detection/displayserver/linux/wayland/kde-output-device-v2-protocol.c
2024-07-05 16:54:43 +08:00
src/detection/displayserver/linux/wayland/kde-output-order-v1-protocol.c
2024-07-05 23:10:42 +08:00
src/detection/displayserver/linux/wayland/xdg-output-unstable-v1-protocol.c
2022-11-24 18:54:52 +08:00
src/detection/displayserver/linux/wmde.c
src/detection/displayserver/linux/xcb.c
src/detection/displayserver/linux/xlib.c
src/detection/font/font_linux.c
2024-01-25 10:18:19 +08:00
src/detection/gpu/gpu_bsd.c
2025-06-18 10:01:32 +08:00
src/detection/gpu/gpu_drm.c
2024-02-11 23:01:14 +08:00
src/detection/gpu/gpu_pci.c
2023-02-14 17:46:21 +08:00
src/detection/gtk_qt/gtk.c
2022-11-20 18:14:32 +01:00
src/detection/host/host_bsd.c
2024-12-08 23:23:51 +08:00
src/detection/host/host_mac.c
2023-06-20 23:01:18 +08:00
src/detection/lm/lm_linux.c
2023-06-06 11:26:29 +08:00
src/detection/icons/icons_linux.c
2024-05-28 23:46:13 +08:00
src/detection/initsystem/initsystem_linux.c
2024-10-10 09:30:20 +08:00
src/detection/keyboard/keyboard_bsd.c
2023-10-09 13:28:30 +08:00
src/detection/libc/libc_bsd.c
2024-05-08 21:54:13 +08:00
src/detection/loadavg/loadavg_bsd.c
2024-01-15 14:50:47 +08:00
src/detection/locale/locale_linux.c
2022-11-20 18:14:32 +01:00
src/detection/localip/localip_linux.c
2023-06-15 14:22:47 +00:00
src/detection/gamepad/gamepad_bsd.c
2022-11-24 18:54:52 +08:00
src/detection/media/media_linux.c
2022-11-20 18:14:32 +01:00
src/detection/memory/memory_bsd.c
2024-10-10 09:30:20 +08:00
src/detection/mouse/mouse_bsd.c
2023-09-27 00:05:37 +08:00
src/detection/netio/netio_bsd.c
2022-10-06 17:47:49 +08:00
src/detection/opengl/opengl_linux.c
2022-11-24 18:54:52 +08:00
src/detection/os/os_linux.c
2023-12-08 09:30:17 +08:00
src/detection/packages/packages_bsd.c
2022-10-09 23:23:46 +08:00
src/detection/poweradapter/poweradapter_nosupport.c
2022-11-20 18:14:32 +01:00
src/detection/processes/processes_bsd.c
2023-02-14 17:46:21 +08:00
src/detection/gtk_qt/qt.c
2024-01-16 11:06:07 +08:00
src/detection/sound/sound_bsd.c
2022-11-20 18:14:32 +01:00
src/detection/swap/swap_bsd.c
2022-11-24 18:54:52 +08:00
src/detection/terminalfont/terminalfont_linux.c
2022-11-20 18:14:32 +01:00
src/detection/terminalshell/terminalshell_linux.c
2023-07-26 10:27:40 +08:00
src/detection/terminalsize/terminalsize_linux.c
2023-06-08 14:32:15 +08:00
src/detection/theme/theme_linux.c
2024-09-26 10:39:03 +08:00
src/detection/tpm/tpm_bsd.c
2022-11-20 18:14:32 +01:00
src/detection/uptime/uptime_bsd.c
src/detection/users/users_linux.c
2023-06-06 20:43:38 +08:00
src/detection/wallpaper/wallpaper_linux.c
2025-04-12 10:48:26 +08:00
src/detection/wm/wm_linux.c
2023-10-30 22:46:38 +08:00
src/detection/de/de_linux.c
2022-11-24 18:54:52 +08:00
src/detection/wmtheme/wmtheme_linux.c
2024-02-04 09:22:24 +08:00
src/detection/camera/camera_linux.c
2024-08-28 10:55:04 +08:00
src/detection/zpool/zpool_linux.c
2023-01-15 15:57:26 +01:00
src/util/platform/FFPlatform_unix.c
2024-08-21 15:31:47 +08:00
src/util/binary_linux.c
2022-09-23 00:10:48 +02:00
)
2024-12-28 22:13:49 +08:00
if ( DragonFly )
list ( APPEND LIBFASTFETCH_SRC
src/detection/bluetooth/bluetooth_nosupport.c
2025-03-23 12:23:30 +08:00
src/detection/wifi/wifi_nosupport.c
2024-12-28 22:13:49 +08:00
)
else ()
list ( APPEND LIBFASTFETCH_SRC
src/detection/bluetooth/bluetooth_bsd.c
2025-03-23 12:23:30 +08:00
src/detection/wifi/wifi_bsd.c
2024-12-28 22:13:49 +08:00
)
endif ()
2024-10-27 11:43:36 +08:00
elseif ( NetBSD )
list ( APPEND LIBFASTFETCH_SRC
src/common/dbus.c
src/common/io/io_unix.c
src/common/netif/netif_bsd.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2024-10-27 11:43:36 +08:00
src/common/processing_linux.c
src/common/sysctl.c
2024-12-21 14:08:30 +08:00
src/detection/battery/battery_nbsd.c
2024-10-27 11:43:36 +08:00
src/detection/bios/bios_nbsd.c
2025-04-15 19:05:31 +08:00
src/detection/bluetooth/bluetooth_bsd.c
2024-12-21 20:25:29 +08:00
src/detection/bluetoothradio/bluetoothradio_nosupport.c
2024-10-27 11:43:36 +08:00
src/detection/board/board_nbsd.c
2025-03-23 12:08:15 +08:00
src/detection/bootmgr/bootmgr_bsd.c
2024-12-20 21:28:22 +08:00
src/detection/brightness/brightness_nbsd.c
2024-10-27 11:43:36 +08:00
src/detection/btrfs/btrfs_nosupport.c
src/detection/chassis/chassis_nbsd.c
2024-10-30 23:29:05 +08:00
src/detection/cpu/cpu_nbsd.c
2025-02-15 14:45:09 +08:00
src/detection/cpucache/cpucache_shared.c
2024-10-28 15:19:05 +08:00
src/detection/cpuusage/cpuusage_bsd.c
2024-10-27 11:43:36 +08:00
src/detection/cursor/cursor_linux.c
2024-10-28 15:48:43 +08:00
src/detection/disk/disk_bsd.c
2024-10-27 11:43:36 +08:00
src/detection/dns/dns_linux.c
src/detection/physicaldisk/physicaldisk_nosupport.c
2025-02-15 14:45:09 +08:00
src/detection/physicalmemory/physicalmemory_linux.c
2024-11-01 15:02:47 +08:00
src/detection/diskio/diskio_nbsd.c
2024-10-27 11:43:36 +08:00
src/detection/displayserver/linux/displayserver_linux.c
2025-09-01 09:59:24 +08:00
src/detection/displayserver/linux/common.c
2024-10-27 11:43:36 +08:00
src/detection/displayserver/linux/drm.c
src/detection/displayserver/linux/wayland/wayland.c
src/detection/displayserver/linux/wayland/global-output.c
src/detection/displayserver/linux/wayland/zwlr-output.c
src/detection/displayserver/linux/wayland/kde-output.c
src/detection/displayserver/linux/wayland/wlr-output-management-unstable-v1-protocol.c
src/detection/displayserver/linux/wayland/kde-output-device-v2-protocol.c
src/detection/displayserver/linux/wayland/kde-output-order-v1-protocol.c
src/detection/displayserver/linux/wayland/xdg-output-unstable-v1-protocol.c
src/detection/displayserver/linux/wmde.c
src/detection/displayserver/linux/xcb.c
src/detection/displayserver/linux/xlib.c
src/detection/font/font_linux.c
2025-10-31 10:18:16 +08:00
src/detection/gpu/gpu_nbsd.c
2024-10-27 11:43:36 +08:00
src/detection/gpu/gpu_pci.c
src/detection/gtk_qt/gtk.c
src/detection/host/host_nbsd.c
src/detection/lm/lm_linux.c
src/detection/icons/icons_linux.c
src/detection/initsystem/initsystem_linux.c
src/detection/keyboard/keyboard_nosupport.c
src/detection/libc/libc_nosupport.c
src/detection/loadavg/loadavg_bsd.c
src/detection/locale/locale_linux.c
src/detection/localip/localip_linux.c
src/detection/gamepad/gamepad_nosupport.c
src/detection/media/media_linux.c
2025-01-13 18:33:05 +08:00
src/detection/memory/memory_nbsd.c
2024-10-27 11:43:36 +08:00
src/detection/mouse/mouse_nosupport.c
2024-11-01 18:51:59 +08:00
src/detection/netio/netio_bsd.c
2024-10-27 11:43:36 +08:00
src/detection/opengl/opengl_linux.c
src/detection/os/os_nbsd.c
2025-05-26 15:12:47 +08:00
src/detection/packages/packages_nbsd.c
2024-10-27 11:43:36 +08:00
src/detection/poweradapter/poweradapter_nosupport.c
2024-11-01 00:20:51 +08:00
src/detection/processes/processes_nbsd.c
2024-10-27 11:43:36 +08:00
src/detection/gtk_qt/qt.c
2025-01-27 23:49:42 +08:00
src/detection/sound/sound_nbsd.c
2024-10-28 15:19:05 +08:00
src/detection/swap/swap_obsd.c
2024-10-27 11:43:36 +08:00
src/detection/terminalfont/terminalfont_linux.c
src/detection/terminalshell/terminalshell_linux.c
src/detection/terminalsize/terminalsize_linux.c
src/detection/theme/theme_linux.c
src/detection/tpm/tpm_nosupport.c
src/detection/uptime/uptime_bsd.c
src/detection/users/users_linux.c
src/detection/wallpaper/wallpaper_linux.c
2025-04-20 11:53:15 +08:00
src/detection/wifi/wifi_nbsd.c
2025-05-31 10:02:45 +08:00
src/detection/wm/wm_linux.c
2024-10-27 11:43:36 +08:00
src/detection/de/de_linux.c
src/detection/wmtheme/wmtheme_linux.c
src/detection/camera/camera_linux.c
src/detection/zpool/zpool_linux.c
src/util/platform/FFPlatform_unix.c
src/util/binary_linux.c
)
2024-10-04 15:58:17 +08:00
elseif ( OpenBSD )
list ( APPEND LIBFASTFETCH_SRC
src/common/dbus.c
src/common/io/io_unix.c
2025-08-08 10:05:20 +08:00
src/common/netif/netif_bsd.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2024-10-04 15:58:17 +08:00
src/common/processing_linux.c
src/common/sysctl.c
2024-12-21 12:04:57 +08:00
src/detection/battery/battery_obsd.c
2025-03-23 10:36:15 +08:00
src/detection/bios/bios_windows.c
2024-12-21 20:25:29 +08:00
src/detection/bluetooth/bluetooth_nosupport.c
src/detection/bluetoothradio/bluetoothradio_nosupport.c
2025-03-23 10:36:15 +08:00
src/detection/board/board_windows.c
2025-03-23 12:08:15 +08:00
src/detection/bootmgr/bootmgr_bsd.c
2024-12-20 22:11:28 +08:00
src/detection/brightness/brightness_obsd.c
2024-10-04 15:58:17 +08:00
src/detection/btrfs/btrfs_nosupport.c
2025-03-23 10:36:15 +08:00
src/detection/chassis/chassis_windows.c
2024-10-04 15:58:17 +08:00
src/detection/cpu/cpu_obsd.c
2025-03-23 10:36:15 +08:00
src/detection/cpucache/cpucache_shared.c
2024-10-04 15:58:17 +08:00
src/detection/cpuusage/cpuusage_bsd.c
src/detection/cursor/cursor_linux.c
src/detection/disk/disk_bsd.c
src/detection/dns/dns_linux.c
src/detection/physicaldisk/physicaldisk_nosupport.c
2025-03-23 10:36:15 +08:00
src/detection/physicalmemory/physicalmemory_linux.c
2024-11-01 15:21:47 +08:00
src/detection/diskio/diskio_obsd.c
2024-10-04 15:58:17 +08:00
src/detection/displayserver/linux/displayserver_linux.c
2025-09-01 09:59:24 +08:00
src/detection/displayserver/linux/common.c
2024-10-04 15:58:17 +08:00
src/detection/displayserver/linux/drm.c
src/detection/displayserver/linux/wayland/wayland.c
src/detection/displayserver/linux/wayland/global-output.c
src/detection/displayserver/linux/wayland/zwlr-output.c
src/detection/displayserver/linux/wayland/kde-output.c
src/detection/displayserver/linux/wayland/wlr-output-management-unstable-v1-protocol.c
src/detection/displayserver/linux/wayland/kde-output-device-v2-protocol.c
src/detection/displayserver/linux/wayland/kde-output-order-v1-protocol.c
src/detection/displayserver/linux/wayland/xdg-output-unstable-v1-protocol.c
src/detection/displayserver/linux/wmde.c
src/detection/displayserver/linux/xcb.c
src/detection/displayserver/linux/xlib.c
src/detection/font/font_linux.c
2024-10-31 23:51:58 +08:00
src/detection/gpu/gpu_pci.c
2025-11-01 17:22:36 +08:00
src/detection/gpu/gpu_obsd.c
2024-10-04 15:58:17 +08:00
src/detection/gtk_qt/gtk.c
src/detection/host/host_obsd.c
src/detection/lm/lm_nosupport.c
src/detection/icons/icons_linux.c
src/detection/initsystem/initsystem_linux.c
2024-10-09 09:45:09 +08:00
src/detection/keyboard/keyboard_nosupport.c
2024-10-04 15:58:17 +08:00
src/detection/libc/libc_nosupport.c
src/detection/loadavg/loadavg_bsd.c
src/detection/locale/locale_linux.c
src/detection/localip/localip_linux.c
src/detection/gamepad/gamepad_nosupport.c
src/detection/media/media_linux.c
src/detection/memory/memory_obsd.c
2024-10-09 09:45:09 +08:00
src/detection/mouse/mouse_nosupport.c
2024-11-01 18:51:59 +08:00
src/detection/netio/netio_bsd.c
2024-10-04 15:58:17 +08:00
src/detection/opengl/opengl_linux.c
src/detection/os/os_obsd.c
src/detection/packages/packages_obsd.c
src/detection/poweradapter/poweradapter_nosupport.c
src/detection/processes/processes_obsd.c
src/detection/gtk_qt/qt.c
2025-01-27 00:30:55 +08:00
src/detection/sound/sound_obsd.c
2024-10-04 15:58:17 +08:00
src/detection/swap/swap_obsd.c
src/detection/terminalfont/terminalfont_linux.c
src/detection/terminalshell/terminalshell_linux.c
src/detection/terminalsize/terminalsize_linux.c
src/detection/theme/theme_linux.c
src/detection/tpm/tpm_nosupport.c
src/detection/uptime/uptime_bsd.c
2024-11-01 18:44:09 +08:00
src/detection/users/users_obsd.c
2024-10-04 15:58:17 +08:00
src/detection/wallpaper/wallpaper_linux.c
2025-04-20 11:49:40 +08:00
src/detection/wifi/wifi_obsd.c
2025-05-31 10:16:26 +08:00
src/detection/wm/wm_linux.c
2024-10-04 15:58:17 +08:00
src/detection/de/de_linux.c
src/detection/wmtheme/wmtheme_linux.c
2024-10-29 09:34:43 +08:00
src/detection/camera/camera_linux.c
2024-10-04 15:58:17 +08:00
src/detection/zpool/zpool_nosupport.c
src/util/platform/FFPlatform_unix.c
src/util/binary_linux.c
2025-03-23 10:36:15 +08:00
src/util/smbiosHelper.c
2024-10-04 15:58:17 +08:00
)
2022-11-20 18:14:32 +01:00
elseif ( APPLE )
2022-10-27 10:46:33 +08:00
list ( APPEND LIBFASTFETCH_SRC
2023-01-28 12:40:12 +01:00
src/common/io/io_unix.c
2025-08-08 10:05:20 +08:00
src/common/netif/netif_apple.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2022-11-20 18:14:32 +01:00
src/common/processing_linux.c
src/common/sysctl.c
src/detection/battery/battery_apple.c
2022-12-29 01:24:34 +08:00
src/detection/bios/bios_apple.c
2023-01-24 22:13:53 +08:00
src/detection/bluetooth/bluetooth_apple.m
2024-07-28 13:06:29 +08:00
src/detection/bluetoothradio/bluetoothradio_apple.m
2023-11-28 11:00:50 +08:00
src/detection/board/board_apple.c
2024-05-16 16:27:37 +08:00
src/detection/bootmgr/bootmgr_apple.c
2023-01-09 18:59:02 +08:00
src/detection/brightness/brightness_apple.c
2024-09-14 16:18:35 +08:00
src/detection/btrfs/btrfs_nosupport.c
2025-02-20 15:57:47 +08:00
src/detection/chassis/chassis_apple.c
2022-11-20 18:14:32 +01:00
src/detection/cpu/cpu_apple.c
2024-06-05 11:02:26 +08:00
src/detection/cpucache/cpucache_apple.c
2023-03-26 20:41:03 +08:00
src/detection/cpuusage/cpuusage_apple.c
2023-03-20 11:14:58 +08:00
src/detection/cursor/cursor_apple.m
2022-11-20 18:14:32 +01:00
src/detection/disk/disk_bsd.c
2025-03-28 10:49:20 +08:00
src/detection/dns/dns_apple.c
2023-12-18 10:43:20 +08:00
src/detection/physicaldisk/physicaldisk_apple.c
2024-05-11 14:46:52 +08:00
src/detection/physicalmemory/physicalmemory_apple.m
2023-10-07 16:21:26 +08:00
src/detection/diskio/diskio_apple.c
2022-11-20 18:14:32 +01:00
src/detection/displayserver/displayserver_apple.c
src/detection/font/font_apple.m
src/detection/gpu/gpu_apple.c
2023-12-29 15:12:41 +08:00
src/detection/gpu/gpu_apple.m
2022-11-20 18:14:32 +01:00
src/detection/host/host_apple.c
2024-12-06 18:31:33 +08:00
src/detection/host/host_mac.c
2023-06-06 11:26:29 +08:00
src/detection/icons/icons_nosupport.c
2024-05-28 23:46:13 +08:00
src/detection/initsystem/initsystem_linux.c
2024-10-09 09:45:09 +08:00
src/detection/keyboard/keyboard_apple.c
2024-05-08 16:41:33 +08:00
src/detection/lm/lm_nosupport.c
2024-05-08 21:54:13 +08:00
src/detection/loadavg/loadavg_bsd.c
2023-10-09 10:43:58 +08:00
src/detection/libc/libc_apple.c
2024-01-15 14:50:47 +08:00
src/detection/locale/locale_linux.c
2022-11-20 18:14:32 +01:00
src/detection/localip/localip_linux.c
2023-02-01 20:23:46 +08:00
src/detection/gamepad/gamepad_apple.c
2022-11-20 18:14:32 +01:00
src/detection/media/media_apple.m
src/detection/memory/memory_apple.c
2024-10-09 09:45:09 +08:00
src/detection/mouse/mouse_apple.c
2024-11-15 14:35:25 +08:00
src/detection/netio/netio_apple.c
2022-11-20 18:14:32 +01:00
src/detection/opengl/opengl_apple.c
src/detection/os/os_apple.m
src/detection/packages/packages_apple.c
2025-08-12 19:25:10 +08:00
src/detection/packages/packages_nix.c
2022-11-20 18:14:32 +01:00
src/detection/poweradapter/poweradapter_apple.c
src/detection/processes/processes_bsd.c
2023-01-25 14:28:13 +08:00
src/detection/sound/sound_apple.c
2022-11-20 18:14:32 +01:00
src/detection/swap/swap_apple.c
src/detection/terminalfont/terminalfont_apple.m
src/detection/terminalshell/terminalshell_linux.c
2023-07-26 10:27:40 +08:00
src/detection/terminalsize/terminalsize_linux.c
2025-09-29 09:25:24 +08:00
src/detection/theme/theme_apple.c
2025-03-31 23:40:01 +08:00
src/detection/tpm/tpm_apple.c
2022-11-20 18:14:32 +01:00
src/detection/uptime/uptime_bsd.c
src/detection/users/users_linux.c
2024-01-03 10:12:37 +08:00
src/detection/wallpaper/wallpaper_apple.m
2022-11-28 16:34:56 +08:00
src/detection/wifi/wifi_apple.m
2025-01-02 10:37:27 +08:00
src/detection/wm/wm_apple.m
2023-10-30 22:46:38 +08:00
src/detection/de/de_nosupport.c
2022-11-20 18:14:32 +01:00
src/detection/wmtheme/wmtheme_apple.m
2024-02-02 15:09:54 +08:00
src/detection/camera/camera_apple.m
2024-08-28 10:55:04 +08:00
src/detection/zpool/zpool_nosupport.c
2022-11-20 18:14:32 +01:00
src/util/apple/cf_helpers.c
src/util/apple/osascript.m
2024-09-24 10:37:54 +08:00
src/util/apple/smc_temps.c
2023-01-15 15:57:26 +01:00
src/util/platform/FFPlatform_unix.c
2024-08-21 15:31:47 +08:00
src/util/binary_apple.c
2022-10-27 10:46:33 +08:00
)
2022-11-20 18:14:32 +01:00
elseif ( WIN32 )
2022-10-05 00:41:43 +08:00
list ( APPEND LIBFASTFETCH_SRC
2023-01-28 12:40:12 +01:00
src/common/io/io_windows.c
2023-09-26 16:26:15 +08:00
src/common/netif/netif_windows.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_windows.c
2022-11-20 18:14:32 +01:00
src/common/processing_windows.c
2022-11-22 01:42:26 +08:00
src/detection/battery/battery_windows.c
2022-11-21 17:27:37 +08:00
src/detection/bios/bios_windows.c
2023-01-24 21:01:21 +08:00
src/detection/bluetooth/bluetooth_windows.c
2024-11-06 00:16:05 +08:00
src/detection/bluetooth/bluetooth_windows.cpp
2024-07-28 00:05:07 +08:00
src/detection/bluetoothradio/bluetoothradio_windows.c
2022-11-21 17:34:54 +08:00
src/detection/board/board_windows.c
2024-05-15 21:36:15 +08:00
src/detection/bootmgr/bootmgr_windows.c
2023-01-09 19:24:19 +08:00
src/detection/brightness/brightness_windows.cpp
2024-09-14 16:18:35 +08:00
src/detection/btrfs/btrfs_nosupport.c
2024-01-06 00:41:02 +08:00
src/detection/chassis/chassis_windows.c
2022-11-21 22:26:50 +08:00
src/detection/cpu/cpu_windows.c
2024-06-05 11:02:26 +08:00
src/detection/cpucache/cpucache_windows.c
2023-03-17 17:56:31 +08:00
src/detection/cpuusage/cpuusage_windows.c
2022-11-23 12:10:45 +08:00
src/detection/cursor/cursor_windows.c
2022-11-20 18:14:32 +01:00
src/detection/disk/disk_windows.c
2023-12-18 10:43:20 +08:00
src/detection/physicaldisk/physicaldisk_windows.c
2023-10-07 16:21:26 +08:00
src/detection/diskio/diskio_windows.c
2023-01-09 19:53:41 +08:00
src/detection/displayserver/displayserver_windows.c
2024-06-12 16:33:13 +08:00
src/detection/dns/dns_windows.c
2022-11-23 19:57:55 +08:00
src/detection/font/font_windows.c
2023-03-25 13:04:44 +08:00
src/detection/gpu/gpu_windows.c
2024-12-08 23:23:51 +08:00
src/detection/host/host_mac.c
2024-01-06 00:41:02 +08:00
src/detection/host/host_windows.c
2023-06-06 14:47:51 +08:00
src/detection/icons/icons_windows.c
2024-05-28 23:46:13 +08:00
src/detection/initsystem/initsystem_nosupport.c
2024-10-09 09:45:09 +08:00
src/detection/keyboard/keyboard_windows.c
2023-10-05 19:06:15 +08:00
src/detection/libc/libc_windows.cpp
2023-06-20 23:01:18 +08:00
src/detection/lm/lm_nosupport.c
2024-05-08 16:41:33 +08:00
src/detection/loadavg/loadavg_nosupport.c
2024-01-15 14:50:47 +08:00
src/detection/locale/locale_windows.c
2022-11-20 18:14:32 +01:00
src/detection/localip/localip_windows.c
2023-03-24 23:38:29 +08:00
src/detection/gamepad/gamepad_windows.c
2024-06-11 16:41:57 +08:00
src/detection/media/media_windows.c
2022-11-21 12:18:36 +08:00
src/detection/memory/memory_windows.c
2024-10-09 09:45:09 +08:00
src/detection/mouse/mouse_windows.c
2024-05-11 08:14:56 +00:00
src/detection/physicalmemory/physicalmemory_linux.c
2023-09-27 00:05:37 +08:00
src/detection/netio/netio_windows.c
2022-10-05 23:51:59 +08:00
src/detection/opengl/opengl_windows.c
2025-10-01 16:06:32 +08:00
src/detection/os/os_windows.cpp
2022-11-20 18:14:32 +01:00
src/detection/packages/packages_windows.c
src/detection/poweradapter/poweradapter_nosupport.c
2023-05-11 19:55:31 +08:00
src/detection/processes/processes_windows.c
2023-01-25 17:17:31 +08:00
src/detection/sound/sound_windows.cpp
2023-05-11 19:55:31 +08:00
src/detection/swap/swap_windows.c
2022-10-12 20:40:38 +08:00
src/detection/terminalfont/terminalfont_windows.c
2023-05-11 19:55:31 +08:00
src/detection/terminalshell/terminalshell_windows.c
2023-07-26 10:27:40 +08:00
src/detection/terminalsize/terminalsize_windows.c
2025-09-29 09:40:10 +08:00
src/detection/theme/theme_windows.c
2024-09-25 22:55:57 +08:00
src/detection/tpm/tpm_windows.c
2022-11-20 18:14:32 +01:00
src/detection/uptime/uptime_windows.c
2022-11-23 19:11:10 +08:00
src/detection/users/users_windows.c
2023-06-06 15:48:24 +08:00
src/detection/wallpaper/wallpaper_windows.c
2022-11-26 18:23:08 +08:00
src/detection/wifi/wifi_windows.c
2023-10-31 21:56:50 +08:00
src/detection/wm/wm_windows.cpp
2023-10-30 22:46:38 +08:00
src/detection/de/de_nosupport.c
2022-11-20 18:14:32 +01:00
src/detection/wmtheme/wmtheme_windows.c
2024-02-02 16:42:47 +08:00
src/detection/camera/camera_windows.cpp
2024-08-28 10:55:04 +08:00
src/detection/zpool/zpool_nosupport.c
2022-10-13 18:12:54 +08:00
src/util/windows/getline.c
2023-01-25 15:49:31 +08:00
src/util/windows/com.cpp
2022-11-26 12:55:48 +08:00
src/util/windows/registry.c
2022-11-22 01:33:22 +08:00
src/util/windows/unicode.c
2022-11-20 18:14:32 +01:00
src/util/windows/wmi.cpp
2025-01-02 14:01:44 +08:00
src/util/windows/version.c
2023-01-15 15:57:26 +01:00
src/util/platform/FFPlatform_windows.c
2024-08-22 16:41:06 +08:00
src/util/binary_windows.c
2025-03-16 10:38:04 +08:00
src/util/debug_windows.c
2022-09-04 12:43:30 +02:00
)
2024-06-16 01:02:48 +08:00
elseif ( SunOS )
list ( APPEND LIBFASTFETCH_SRC
src/common/dbus.c
src/common/io/io_unix.c
2025-08-08 10:05:20 +08:00
src/common/netif/netif_apple.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2024-06-16 01:02:48 +08:00
src/common/processing_linux.c
src/detection/battery/battery_nosupport.c
2024-06-16 22:25:16 +08:00
src/detection/bios/bios_windows.c
src/detection/board/board_windows.c
2024-06-16 01:02:48 +08:00
src/detection/bootmgr/bootmgr_nosupport.c
src/detection/brightness/brightness_nosupport.c
2024-09-14 16:18:35 +08:00
src/detection/btrfs/btrfs_nosupport.c
2024-06-16 22:25:16 +08:00
src/detection/chassis/chassis_windows.c
2024-06-17 01:01:21 +08:00
src/detection/cpu/cpu_sunos.c
2024-06-21 15:21:55 +08:00
src/detection/cpucache/cpucache_shared.c
2024-06-17 22:51:40 +08:00
src/detection/cpuusage/cpuusage_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/cursor/cursor_linux.c
src/detection/bluetooth/bluetooth_nosupport.c
2024-07-28 00:05:07 +08:00
src/detection/bluetoothradio/bluetoothradio_nosupport.c
2024-06-17 19:32:54 +08:00
src/detection/disk/disk_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/dns/dns_linux.c
2025-06-22 01:16:50 +08:00
src/detection/physicaldisk/physicaldisk_sunos.c
2024-06-16 22:25:16 +08:00
src/detection/physicalmemory/physicalmemory_linux.c
2024-06-17 23:41:53 +08:00
src/detection/diskio/diskio_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/displayserver/linux/displayserver_linux.c
2025-09-01 09:59:24 +08:00
src/detection/displayserver/linux/common.c
2024-06-16 01:02:48 +08:00
src/detection/displayserver/linux/drm.c
src/detection/displayserver/linux/wayland/wayland.c
src/detection/displayserver/linux/wayland/global-output.c
src/detection/displayserver/linux/wayland/zwlr-output.c
2024-07-05 16:14:56 +08:00
src/detection/displayserver/linux/wayland/kde-output.c
2024-06-16 01:02:48 +08:00
src/detection/displayserver/linux/wayland/wlr-output-management-unstable-v1-protocol.c
2024-07-05 16:14:56 +08:00
src/detection/displayserver/linux/wayland/kde-output-device-v2-protocol.c
2024-07-05 16:54:43 +08:00
src/detection/displayserver/linux/wayland/kde-output-order-v1-protocol.c
2024-07-05 23:10:42 +08:00
src/detection/displayserver/linux/wayland/xdg-output-unstable-v1-protocol.c
2024-06-16 01:02:48 +08:00
src/detection/displayserver/linux/wmde.c
src/detection/displayserver/linux/xcb.c
src/detection/displayserver/linux/xlib.c
src/detection/font/font_linux.c
2024-06-17 12:37:11 +08:00
src/detection/gpu/gpu_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/gpu/gpu_pci.c
src/detection/gtk_qt/gtk.c
2024-06-16 22:25:16 +08:00
src/detection/host/host_windows.c
src/detection/icons/icons_linux.c
2024-06-17 13:35:26 +08:00
src/detection/initsystem/initsystem_linux.c
2024-10-10 10:06:54 +08:00
src/detection/keyboard/keyboard_nosupport.c
2024-06-16 01:02:48 +08:00
src/detection/libc/libc_nosupport.c
src/detection/lm/lm_nosupport.c
2024-06-17 15:23:35 +08:00
src/detection/loadavg/loadavg_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/locale/locale_linux.c
src/detection/localip/localip_linux.c
src/detection/gamepad/gamepad_nosupport.c
src/detection/media/media_linux.c
2024-06-17 15:52:45 +08:00
src/detection/memory/memory_sunos.c
2024-10-10 10:06:54 +08:00
src/detection/mouse/mouse_nosupport.c
2024-06-18 10:17:02 +08:00
src/detection/netio/netio_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/opengl/opengl_linux.c
src/detection/os/os_sunos.c
2024-06-17 01:01:21 +08:00
src/detection/packages/packages_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/poweradapter/poweradapter_nosupport.c
src/detection/processes/processes_linux.c
src/detection/gtk_qt/qt.c
2025-06-22 20:34:33 +08:00
src/detection/sound/sound_sunos.c
2024-06-17 16:43:52 +08:00
src/detection/swap/swap_sunos.c
2024-06-16 01:02:48 +08:00
src/detection/terminalfont/terminalfont_linux.c
src/detection/terminalshell/terminalshell_linux.c
src/detection/terminalsize/terminalsize_linux.c
src/detection/theme/theme_linux.c
2024-09-25 22:55:57 +08:00
src/detection/tpm/tpm_nosupport.c
2024-06-16 01:02:48 +08:00
src/detection/uptime/uptime_sunos.c
src/detection/users/users_linux.c
src/detection/wallpaper/wallpaper_linux.c
src/detection/wifi/wifi_nosupport.c
src/detection/wm/wm_nosupport.c
src/detection/de/de_linux.c
src/detection/wmtheme/wmtheme_linux.c
src/detection/camera/camera_nosupport.c
2024-08-28 10:55:04 +08:00
src/detection/zpool/zpool_linux.c
2024-06-16 01:02:48 +08:00
src/util/platform/FFPlatform_unix.c
2024-08-21 15:31:47 +08:00
src/util/binary_linux.c
2024-06-16 01:02:48 +08:00
)
2025-02-05 02:08:28 +01:00
elseif ( Haiku )
list ( APPEND LIBFASTFETCH_SRC
2025-02-12 00:45:14 +08:00
src/common/dbus.c
2025-02-05 02:08:28 +01:00
src/common/io/io_unix.c
src/common/netif/netif_haiku.c
2025-03-15 23:40:40 +08:00
src/common/networking/networking_linux.c
2025-02-05 02:08:28 +01:00
src/common/processing_linux.c
2025-02-13 23:27:14 +00:00
src/detection/battery/battery_haiku.c
2025-02-14 16:47:48 +08:00
src/detection/bios/bios_windows.c
src/detection/board/board_windows.c
2025-02-05 02:08:28 +01:00
src/detection/bootmgr/bootmgr_nosupport.c
src/detection/brightness/brightness_nosupport.c
src/detection/btrfs/btrfs_nosupport.c
2025-02-14 16:47:48 +08:00
src/detection/chassis/chassis_windows.c
2025-02-12 00:16:50 +08:00
src/detection/cpu/cpu_haiku.c
2025-02-14 16:47:48 +08:00
src/detection/cpucache/cpucache_shared.c
2025-02-16 19:13:47 +08:00
src/detection/cpuusage/cpuusage_haiku.c
2025-02-05 02:08:28 +01:00
src/detection/cursor/cursor_nosupport.c
2025-02-16 20:37:21 +08:00
src/detection/bluetooth/bluetooth_haiku.cpp
2025-02-05 02:08:28 +01:00
src/detection/bluetoothradio/bluetoothradio_nosupport.c
2025-02-12 00:17:18 +08:00
src/detection/disk/disk_haiku.cpp
2025-02-05 02:08:28 +01:00
src/detection/dns/dns_linux.c
2025-02-16 20:12:06 +08:00
src/detection/physicaldisk/physicaldisk_haiku.c
2025-02-14 16:47:48 +08:00
src/detection/physicalmemory/physicalmemory_linux.c
2025-02-05 02:08:28 +01:00
src/detection/diskio/diskio_nosupport.c
src/detection/displayserver/displayserver_haiku.cpp
src/detection/font/font_haiku.cpp
2025-02-12 21:59:19 +00:00
src/detection/gpu/gpu_haiku.c
2025-02-05 02:08:28 +01:00
src/detection/gpu/gpu_pci.c
src/detection/gtk_qt/gtk.c
2025-02-14 16:47:48 +08:00
src/detection/host/host_windows.c
2025-02-05 02:08:28 +01:00
src/detection/icons/icons_nosupport.c
2025-02-17 21:22:12 +08:00
src/detection/initsystem/initsystem_haiku.c
2025-02-15 16:22:23 +01:00
src/detection/keyboard/keyboard_haiku.cpp
2025-02-05 02:08:28 +01:00
src/detection/libc/libc_nosupport.c
src/detection/lm/lm_nosupport.c
src/detection/loadavg/loadavg_nosupport.c
src/detection/locale/locale_linux.c
src/detection/localip/localip_linux.c
2025-02-16 20:18:04 +08:00
src/detection/gamepad/gamepad_haiku.cpp
2025-02-12 00:29:43 +00:00
src/detection/media/media_linux.c
2025-02-05 02:08:28 +01:00
src/detection/memory/memory_haiku.c
2025-02-15 16:13:19 +01:00
src/detection/mouse/mouse_haiku.cpp
2025-02-15 18:53:59 +01:00
src/detection/netio/netio_haiku.cpp
2025-02-16 22:52:51 +08:00
src/detection/opengl/opengl_haiku.cpp
2025-02-05 10:15:09 +08:00
src/detection/os/os_haiku.c
2025-02-05 02:08:28 +01:00
src/detection/packages/packages_haiku.c
src/detection/poweradapter/poweradapter_nosupport.c
src/detection/processes/processes_haiku.c
src/detection/gtk_qt/qt.c
2025-02-12 00:17:36 +08:00
src/detection/sound/sound_haiku.cpp
2025-02-05 02:08:28 +01:00
src/detection/swap/swap_haiku.c
src/detection/terminalfont/terminalfont_linux.c
src/detection/terminalshell/terminalshell_linux.c
src/detection/terminalsize/terminalsize_linux.c
src/detection/theme/theme_nosupport.c
src/detection/tpm/tpm_nosupport.c
src/detection/uptime/uptime_haiku.c
src/detection/users/users_linux.c
src/detection/wallpaper/wallpaper_nosupport.c
src/detection/wifi/wifi_nosupport.c
src/detection/wm/wm_nosupport.c
src/detection/de/de_nosupport.c
src/detection/wmtheme/wmtheme_nosupport.c
src/detection/camera/camera_nosupport.c
src/detection/zpool/zpool_nosupport.c
src/util/platform/FFPlatform_unix.c
src/util/binary_linux.c
2025-02-17 21:22:12 +08:00
src/util/haiku/version.cpp
2025-02-05 02:08:28 +01:00
)
2025-05-19 15:07:46 +00:00
elseif ( GNU )
list ( APPEND LIBFASTFETCH_SRC
src/common/dbus.c
src/common/io/io_unix.c
2025-08-06 07:36:32 +00:00
src/common/netif/netif_gnu.c
2025-05-19 15:07:46 +00:00
src/common/networking/networking_linux.c
src/common/processing_linux.c
src/detection/battery/battery_nosupport.c
src/detection/bios/bios_nosupport.c
src/detection/board/board_nosupport.c
src/detection/bootmgr/bootmgr_nosupport.c
src/detection/brightness/brightness_nosupport.c
src/detection/btrfs/btrfs_nosupport.c
src/detection/chassis/chassis_nosupport.c
src/detection/cpu/cpu_linux.c
src/detection/cpucache/cpucache_nosupport.c
src/detection/cpuusage/cpuusage_linux.c
src/detection/cursor/cursor_linux.c
src/detection/bluetooth/bluetooth_linux.c
src/detection/bluetoothradio/bluetoothradio_linux.c
src/detection/disk/disk_linux.c
src/detection/dns/dns_linux.c
src/detection/physicaldisk/physicaldisk_nosupport.c
src/detection/physicalmemory/physicalmemory_nosupport.c
src/detection/diskio/diskio_nosupport.c
src/detection/displayserver/linux/displayserver_linux.c
2025-09-01 09:59:24 +08:00
src/detection/displayserver/linux/common.c
2025-05-19 15:07:46 +00:00
src/detection/displayserver/linux/drm.c
src/detection/displayserver/linux/wayland/wayland.c
src/detection/displayserver/linux/wayland/global-output.c
src/detection/displayserver/linux/wayland/zwlr-output.c
src/detection/displayserver/linux/wayland/wlr-output-management-unstable-v1-protocol.c
src/detection/displayserver/linux/wmde.c
src/detection/displayserver/linux/xcb.c
src/detection/displayserver/linux/xlib.c
src/detection/font/font_linux.c
2025-11-01 17:26:49 +08:00
src/detection/gpu/gpu_general.c
2025-05-19 15:07:46 +00:00
src/detection/gpu/gpu_pci.c
src/detection/gtk_qt/gtk.c
src/detection/host/host_nosupport.c
src/detection/icons/icons_linux.c
src/detection/initsystem/initsystem_linux.c
src/detection/keyboard/keyboard_nosupport.c
src/detection/libc/libc_linux.c
src/detection/lm/lm_linux.c
src/detection/loadavg/loadavg_linux.c
src/detection/locale/locale_linux.c
src/detection/localip/localip_linux.c
src/detection/gamepad/gamepad_nosupport.c
src/detection/media/media_linux.c
src/detection/memory/memory_linux.c
src/detection/mouse/mouse_nosupport.c
src/detection/netio/netio_nosupport.c
src/detection/opengl/opengl_linux.c
src/detection/os/os_linux.c
src/detection/packages/packages_linux.c
2025-08-24 19:35:33 +08:00
src/detection/packages/packages_nix.c
2025-05-19 15:07:46 +00:00
src/detection/poweradapter/poweradapter_nosupport.c
src/detection/processes/processes_linux.c
src/detection/gtk_qt/qt.c
src/detection/sound/sound_linux.c
src/detection/swap/swap_linux.c
src/detection/terminalfont/terminalfont_linux.c
src/detection/terminalshell/terminalshell_linux.c
src/detection/terminalsize/terminalsize_linux.c
src/detection/theme/theme_linux.c
src/detection/tpm/tpm_nosupport.c
src/detection/uptime/uptime_linux.c
src/detection/users/users_linux.c
src/detection/wallpaper/wallpaper_linux.c
2025-08-24 22:04:58 +08:00
src/detection/wifi/wifi_nosupport.c
2025-08-24 19:56:43 +08:00
src/detection/wm/wm_linux.c
2025-05-19 15:07:46 +00:00
src/detection/de/de_linux.c
src/detection/wmtheme/wmtheme_linux.c
src/detection/camera/camera_nosupport.c
src/detection/zpool/zpool_nosupport.c
src/util/platform/FFPlatform_unix.c
src/util/binary_linux.c
)
2022-09-04 12:43:30 +02:00
endif ()
2023-09-20 23:55:36 +08:00
if ( ENABLE_DIRECTX_HEADERS )
message ( STATUS "Enabling DirectX headers for WSL" )
list ( APPEND LIBFASTFETCH_SRC src/detection/gpu/gpu_wsl.cpp )
endif ()
2024-06-22 22:03:28 +08:00
# Proprietary GPU driver APIs
2024-08-05 08:54:25 +08:00
if ( LINUX OR FreeBSD OR WIN32 )
2024-06-22 22:03:28 +08:00
list ( APPEND LIBFASTFETCH_SRC src/detection/gpu/gpu_nvidia.c )
2024-08-02 16:29:23 +08:00
list ( APPEND LIBFASTFETCH_SRC src/detection/gpu/gpu_mthreads.c )
2024-06-22 22:03:28 +08:00
endif ()
if ( WIN32 )
list ( APPEND LIBFASTFETCH_SRC src/detection/gpu/gpu_intel.c )
list ( APPEND LIBFASTFETCH_SRC src/detection/gpu/gpu_amd.c )
2024-01-01 12:38:06 +02:00
endif ()
2023-07-31 14:10:53 +08:00
include ( CheckFunctionExists )
check_function_exists ( wcwidth HAVE_WCWIDTH )
if ( NOT HAVE_WCWIDTH )
2025-09-09 09:54:30 +08:00
list ( APPEND LIBFASTFETCH_SRC src/util/wcwidth.c )
2023-07-31 14:10:53 +08:00
endif ()
2025-02-05 15:36:09 +08:00
if ( NOT WIN32 )
check_function_exists ( pipe2 HAVE_PIPE2 )
endif ()
2023-07-31 14:10:53 +08:00
2023-08-19 11:10:14 +08:00
if ( ENABLE_SYSTEM_YYJSON )
find_package ( yyjson )
if ( yyjson_FOUND )
message ( STATUS "System provided yyjson is used" )
else ()
message ( FATAL_ERROR "ENABLE_SYSTEM_YYJSON is set but system provided yyjson is not found" )
endif ()
else ()
list ( APPEND LIBFASTFETCH_SRC
src/3rdparty/yyjson/yyjson.c
)
endif ()
2022-09-04 12:43:30 +02:00
add_library ( libfastfetch OBJECT
${ LIBFASTFETCH_SRC }
)
2023-09-20 23:55:36 +08:00
2023-08-19 11:10:14 +08:00
if ( yyjson_FOUND )
2025-10-28 09:28:23 +08:00
target_compile_definitions ( libfastfetch PUBLIC FF_USE_SYSTEM_YYJSON=1 )
2024-09-13 15:47:52 +08:00
target_link_libraries ( libfastfetch PUBLIC yyjson::yyjson )
2024-01-15 14:04:56 +08:00
# `target_link_libraries(yyjson::yyjson)` sets rpath implicitly
2025-10-28 09:28:23 +08:00
endif ()
# Used for dlopen finding dylibs installed by homebrew
# `/opt/homebrew/lib` is not on in dlopen search path by default
if ( APPLE AND NOT BINARY_LINK_TYPE STREQUAL "dlopen" )
set ( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,/opt/homebrew/lib -Wl,-rpath,/usr/local/lib" )
2023-08-19 11:10:14 +08:00
endif ()
2022-09-04 12:43:30 +02:00
2025-01-07 14:54:18 +08:00
if ( ANDROID )
if ( CMAKE_SIZEOF_VOID_P EQUAL 8 )
set ( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,/vendor/lib64 -Wl,-rpath,/system/lib64" )
else ()
set ( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,/vendor/lib -Wl,-rpath,/system/lib" )
endif ()
endif ()
2023-10-09 09:05:11 +08:00
if ( LINUX AND EXISTS "/lib/ld-musl-${CMAKE_HOST_SYSTEM_PROCESSOR}.so.1" )
execute_process ( COMMAND "/lib/ld-musl-${CMAKE_HOST_SYSTEM_PROCESSOR}.so.1"
2023-10-09 10:43:40 +08:00
ERROR_VARIABLE LD_MUSL_RESULT )
if ( "${LD_MUSL_RESULT}" MATCHES "Version ([0-9]+\\.[0-9]+\\.[0-9]+)" )
target_compile_definitions ( libfastfetch PUBLIC FF_MUSL_VERSION= "${CMAKE_MATCH_1}" )
2023-10-08 21:03:10 +08:00
endif ()
endif ()
2023-10-09 10:43:58 +08:00
if ( APPLE AND EXISTS "/usr/bin/otool" )
execute_process ( COMMAND /usr/bin/otool -L /usr/bin/otool
OUTPUT_VARIABLE OTOOL_OTOOL_RESULT )
if ( "${OTOOL_OTOOL_RESULT}" MATCHES "libSystem\\.B\\.dylib \\(.*current version ([0-9]+\\.[0-9]+\\.[0-9]+)\\)" )
target_compile_definitions ( libfastfetch PUBLIC FF_LIBSYSTEM_VERSION= "${CMAKE_MATCH_1}" )
endif ()
endif ()
2024-11-10 20:11:02 +08:00
if ( MidnightBSD AND EXISTS "/usr/bin/objdump" )
execute_process ( COMMAND /bin/sh -c "/usr/bin/objdump -T /lib/libc.so.* | grep 'FBSD_[0-9][0-9]*\\.[0-9][0-9]*' -o | sort -Vru | head -1"
OUTPUT_VARIABLE OBJDUMP_T_RESULT )
if ( "${OBJDUMP_T_RESULT}" MATCHES "FBSD_([0-9]+\\.[0-9]+)" )
message ( STATUS "Found FBSD ${CMAKE_MATCH_1}" )
target_compile_definitions ( libfastfetch PUBLIC FF_FBSD_VERSION= "${CMAKE_MATCH_1}" )
endif ()
elseif ( FreeBSD AND EXISTS "/usr/local/bin/objdump" )
2024-11-03 11:47:24 +08:00
execute_process ( COMMAND /bin/sh -c "/usr/local/bin/objdump -T /lib/libc.so.* | grep 'FBSD_[0-9][0-9]*\\.[0-9][0-9]*' -o | sort -Vru | head -1"
2023-10-09 13:28:30 +08:00
OUTPUT_VARIABLE OBJDUMP_T_RESULT )
if ( "${OBJDUMP_T_RESULT}" MATCHES "FBSD_([0-9]+\\.[0-9]+)" )
2024-11-10 20:11:02 +08:00
message ( STATUS "Found FBSD ${CMAKE_MATCH_1}" )
2023-10-09 13:28:30 +08:00
target_compile_definitions ( libfastfetch PUBLIC FF_FBSD_VERSION= "${CMAKE_MATCH_1}" )
endif ()
2024-11-10 20:11:02 +08:00
elseif ( DragonFly AND EXISTS "/usr/local/bin/objdump" )
2024-11-03 11:47:24 +08:00
execute_process ( COMMAND /bin/sh -c "/usr/local/bin/objdump -T /lib/libc.so.* | grep 'DF[0-9][0-9]*\\.[0-9][0-9]*' -o | sort -Vru | head -1"
OUTPUT_VARIABLE OBJDUMP_T_RESULT )
if ( "${OBJDUMP_T_RESULT}" MATCHES "DF([0-9]+\\.[0-9]+)" )
2024-11-10 20:11:02 +08:00
message ( STATUS "Found DF ${CMAKE_MATCH_1}" )
2024-11-03 11:47:24 +08:00
target_compile_definitions ( libfastfetch PUBLIC FF_DF_VERSION= "${CMAKE_MATCH_1}" )
endif ()
endif ()
2023-10-08 21:03:10 +08:00
2024-10-17 16:42:59 +08:00
if ( LINUX )
2024-10-23 16:09:27 +08:00
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE _XOPEN_SOURCE _ATFILE_SOURCE __STDC_WANT_LIB_EXT1__ _FILE_OFFSET_BITS=64 _TIME_BITS=64 ) # "$<$<CONFIG:Release>:_FORTIFY_SOURCE=3>"
2024-10-17 16:42:59 +08:00
elseif ( ANDROID )
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE _XOPEN_SOURCE _FILE_OFFSET_BITS=64 "$<$<CONFIG:DEBUG>:__BIONIC_FORTIFY>" "$<$<CONFIG:DEBUG>:__BIONIC_FORTIFY_RUNTIME_CHECKS_ENABLED>" )
2024-10-04 15:58:17 +08:00
elseif ( WIN32 )
2024-11-09 20:21:46 +08:00
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE WIN32_LEAN_AND_MEAN _WIN32_WINNT=0x0A00 NOMINMAX UNICODE ) # "$<$<CONFIG:Release>:_FORTIFY_SOURCE=3>"
2023-09-19 14:43:55 +08:00
elseif ( APPLE )
2024-10-04 15:58:17 +08:00
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE _XOPEN_SOURCE __STDC_WANT_LIB_EXT1__ _FILE_OFFSET_BITS=64 _DARWIN_C_SOURCE )
elseif ( OpenBSD )
target_compile_definitions ( libfastfetch PUBLIC _XOPEN_SOURCE=700 _FILE_OFFSET_BITS=64 _BSD_SOURCE )
2024-10-31 22:39:25 +08:00
set ( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,/usr/X11R6/lib" ) # detect x11 lib path automatically
2024-11-03 08:35:11 +08:00
elseif ( DragonFly )
target_compile_definitions ( libfastfetch PUBLIC __FreeBSD__ )
2024-06-16 01:02:48 +08:00
elseif ( SunOS )
2024-10-04 15:58:17 +08:00
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE _XOPEN_SOURCE __STDC_WANT_LIB_EXT1__ _FILE_OFFSET_BITS=64 __EXTENSIONS__ _POSIX_C_SOURCE )
2024-10-27 11:43:36 +08:00
elseif ( NetBSD )
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE )
set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-char-subscripts" )
2024-11-04 14:27:43 +08:00
set ( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,/usr/X11R7/lib -Wl,-rpath,/usr/pkg/lib" ) # ditto
2025-02-11 09:15:14 +08:00
elseif ( Haiku )
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE )
2025-05-19 15:07:46 +00:00
elseif ( GNU )
target_compile_definitions ( libfastfetch PUBLIC _GNU_SOURCE )
# On Hurd PATH_MAX is not defined. Set an arbitrary limit as workaround.
target_compile_definitions ( libfastfetch PUBLIC PATH_MAX=4096 )
2023-03-24 23:21:39 +08:00
endif ()
2022-09-29 14:22:56 +08:00
2024-11-15 14:48:17 +08:00
if ( FreeBSD OR OpenBSD OR NetBSD )
include ( CheckStructHasMember )
set ( CMAKE_REQUIRED_DEFINITIONS "-D_IFI_OQDROPS=1" )
CHECK_STRUCT_HAS_MEMBER ( "struct if_data" ifi_oqdrops net/if.h HAVE_IFI_OQDROPS LANGUAGE C )
if ( HAVE_IFI_OQDROPS )
target_compile_definitions ( libfastfetch PUBLIC _IFI_OQDROPS FF_HAVE_IFI_OQDROPS )
endif ()
unset ( CMAKE_REQUIRED_DEFINITIONS )
endif ()
2023-07-31 14:10:53 +08:00
if ( HAVE_WCWIDTH )
2024-09-13 15:47:52 +08:00
target_compile_definitions ( libfastfetch PUBLIC FF_HAVE_WCWIDTH )
2023-07-31 14:10:53 +08:00
endif ()
2025-02-05 15:36:09 +08:00
if ( HAVE_PIPE2 )
target_compile_definitions ( libfastfetch PUBLIC FF_HAVE_PIPE2 )
endif ()
2024-02-27 15:20:02 +08:00
if ( NOT "${CUSTOM_PCI_IDS_PATH}" STREQUAL "" )
message ( STATUS "Custom file path of pci.ids: ${CUSTOM_PCI_IDS_PATH}" )
target_compile_definitions ( libfastfetch PRIVATE FF_CUSTOM_PCI_IDS_PATH= ${ CUSTOM_PCI_IDS_PATH } )
endif ()
2024-05-04 10:01:29 +08:00
if ( NOT "${CUSTOM_AMDGPU_IDS_PATH}" STREQUAL "" )
message ( STATUS "Custom file path of amdgpu.ids: ${CUSTOM_AMDGPU_IDS_PATH}" )
target_compile_definitions ( libfastfetch PRIVATE FF_CUSTOM_AMDGPU_IDS_PATH= ${ CUSTOM_AMDGPU_IDS_PATH } )
endif ()
2024-05-06 16:25:08 +08:00
if ( NOT "${CUSTOM_OS_RELEASE_PATH}" STREQUAL "" )
message ( STATUS "Custom file path of os_release: ${CUSTOM_OS_RELEASE_PATH}" )
target_compile_definitions ( libfastfetch PRIVATE FF_CUSTOM_OS_RELEASE_PATH= ${ CUSTOM_OS_RELEASE_PATH } )
endif ()
2025-01-24 09:47:22 +08:00
if ( NOT "${CUSTOM_LSB_RELEASE_PATH}" STREQUAL "" )
message ( STATUS "Custom file path of lsb_release: ${CUSTOM_LSB_RELEASE_PATH}" )
target_compile_definitions ( libfastfetch PRIVATE FF_CUSTOM_LSB_RELEASE_PATH= ${ CUSTOM_LSB_RELEASE_PATH } )
endif ()
2024-02-27 15:20:02 +08:00
2024-05-24 14:40:14 +08:00
if ( NOT BINARY_LINK_TYPE STREQUAL "dlopen" )
message ( STATUS "Enabling custom link type: ${BINARY_LINK_TYPE}" )
target_compile_definitions ( libfastfetch PRIVATE FF_DISABLE_DLOPEN=1 )
2024-11-20 22:13:10 +08:00
if ( NOT WIN32 )
set ( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--copy-dt-needed-entries" )
endif ()
2024-05-24 14:40:14 +08:00
endif ()
2022-11-24 18:10:49 +01:00
function ( ff_lib_enable VARNAME PKGCONFIG_NAMES CMAKE_NAME )
2022-09-05 19:56:00 +02:00
if ( NOT ENABLE_ ${ VARNAME } )
return ()
2022-04-13 23:13:25 +02:00
endif ()
2022-04-11 16:19:02 +02:00
2022-11-24 18:10:49 +01:00
if ( PKG_CONFIG_FOUND )
pkg_search_module ( ${ VARNAME } QUIET ${ PKGCONFIG_NAMES } )
endif ()
if ( NOT ${ VARNAME } _FOUND )
find_package ( ${ CMAKE_NAME } QUIET )
set ( ${ VARNAME } _FOUND ${ ${CMAKE_NAME } _FOUND} )
set ( ${ VARNAME } _INCLUDE_DIRS ${ ${CMAKE_NAME } _INCLUDE_DIRS} )
set ( ${ VARNAME } _LIBRARIES ${ ${CMAKE_NAME } _LIBRARIES} )
set ( ${ VARNAME } _CFLAGS_OTHER ${ ${CMAKE_NAME } _CFLAGS_OTHER} )
endif ()
2022-09-19 18:30:00 +02:00
if ( NOT ${ VARNAME } _FOUND )
2022-11-24 18:10:49 +01:00
message ( STATUS "Library: missing: ${VARNAME}" )
2022-09-19 18:30:00 +02:00
return ()
endif ()
2022-11-24 18:10:49 +01:00
message ( STATUS "Library: found ${VARNAME}" )
2022-09-19 18:30:00 +02:00
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_ ${ VARNAME } =1 )
target_include_directories ( libfastfetch PRIVATE ${ ${VARNAME } _INCLUDE_DIRS} )
2024-05-24 14:40:14 +08:00
if ( NOT BINARY_LINK_TYPE STREQUAL "dlopen" )
2024-05-24 15:48:18 +08:00
target_link_directories ( libfastfetch PUBLIC ${ ${VARNAME } _LIBRARY_DIRS} )
2024-05-24 14:40:14 +08:00
target_link_libraries ( libfastfetch PRIVATE ${ ${VARNAME } _LIBRARIES} )
endif ()
2022-09-19 18:30:00 +02:00
foreach ( FLAG ${ ${VARNAME } _CFLAGS_OTHER} )
if ( FLAG MATCHES "-D.*" )
string ( SUBSTRING ${ FLAG } 2 -1 FLAG )
target_compile_definitions ( libfastfetch PRIVATE ${ FLAG } )
2022-05-29 16:23:56 +02:00
endif ()
2022-09-05 19:56:00 +02:00
endforeach ()
endfunction ()
2022-11-24 18:10:49 +01:00
ff_lib_enable ( VULKAN
"vulkan"
"Vulkan"
)
ff_lib_enable ( WAYLAND
"wayland-client"
"WaylandClient"
)
ff_lib_enable ( XCB_RANDR
"xcb-randr"
"XcbRandr"
)
ff_lib_enable ( XRANDR
"xrandr"
"XRandr"
)
2023-11-29 14:55:40 +08:00
ff_lib_enable ( DRM
"libdrm"
"Libdrm"
)
2024-09-27 00:12:52 +08:00
ff_lib_enable ( DRM_AMDGPU
"libdrm_amdgpu"
"Libdrm_Amdgpu"
)
2022-11-24 18:10:49 +01:00
ff_lib_enable ( GIO
"gio-2.0"
"GIO"
)
ff_lib_enable ( DCONF
"dconf"
"DConf"
)
ff_lib_enable ( DBUS
"dbus-1"
"DBus"
)
ff_lib_enable ( SQLITE3
"sqlite3"
"SQLite3"
)
ff_lib_enable ( RPM
"rpm"
"RPM"
)
ff_lib_enable ( IMAGEMAGICK7
"MagickCore-7.Q16HDRI;MagickCore-7.Q16;MagickCore-7;/usr/lib/imagemagick7/pkgconfig/MagickCore-7.Q16HDRI.pc;/usr/lib/imagemagick7/pkgconfig/MagickCore-7.Q16.pc;/usr/lib/imagemagick7/pkgconfig/MagickCore-7.pc"
"ImageMagick7"
)
ff_lib_enable ( IMAGEMAGICK6
"MagickCore-6.Q16HDRI;MagickCore-6.Q16;MagickCore-6;/usr/lib/imagemagick6/pkgconfig/MagickCore-6.Q16HDRI.pc;/usr/lib/imagemagick6/pkgconfig/MagickCore-6.Q16.pc;/usr/lib/imagemagick6/pkgconfig/MagickCore-6.pc"
"ImageMagick6"
)
ff_lib_enable ( ZLIB
"zlib"
"ZLIB"
)
ff_lib_enable ( CHAFA
"chafa>=1.10"
"Chafa"
)
ff_lib_enable ( EGL
"egl"
"EGL"
)
2024-10-29 09:08:09 +08:00
if ( NOT OpenBSD AND NOT NetBSD )
2024-10-04 15:58:17 +08:00
ff_lib_enable ( GLX
"glx"
"GLX"
)
else ()
ff_lib_enable ( GLX
"gl"
"GL"
)
endif ()
2022-11-24 18:10:49 +01:00
ff_lib_enable ( OPENCL
"OpenCL"
"OpenCL"
)
ff_lib_enable ( FREETYPE
"freetype2"
"FreeType2"
)
2023-01-26 15:48:28 +01:00
ff_lib_enable ( PULSE
"libpulse"
"Pulse"
2023-01-26 00:49:43 +08:00
)
2023-07-09 17:22:04 +08:00
ff_lib_enable ( DDCUTIL
"ddcutil"
"Ddcutil"
)
2024-08-08 15:03:10 +08:00
ff_lib_enable ( ELF
"libelf"
"libelf"
)
2023-09-20 23:55:36 +08:00
ff_lib_enable ( DIRECTX_HEADERS
"DirectX-Headers"
"DirectX-Headers"
)
2024-10-31 23:51:58 +08:00
ff_lib_enable ( PCIACCESS
"pciaccess"
"pciaccess"
)
2024-08-31 12:34:36 +08:00
# The system <libzfs.h> is only usable on SunOS. We provide our local copy of it so it's always available.
if ( ENABLE_LIBZFS )
if ( BINARY_LINK_TYPE STREQUAL "dlopen" )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_LIBZFS=1 )
else ()
set ( CMAKE_REQUIRED_LIBRARIES_BACKUP ${ CMAKE_REQUIRED_LIBRARIES } )
set ( CMAKE_REQUIRED_LIBRARIES ${ CMAKE_REQUIRED_LIBRARIES } zfs )
check_function_exists ( "libzfs_init" LIBZFS_FOUND )
set ( CMAKE_REQUIRED_LIBRARIES ${ CMAKE_REQUIRED_LIBRARIES_BACKUP } )
if ( NOT LIBZFS_FOUND )
message ( STATUS "Library: missing: LIBZFS" )
else ()
message ( STATUS "Library: found LIBZFS" )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_LIBZFS=1 )
target_link_libraries ( libfastfetch PRIVATE zfs )
endif ()
endif ()
endif ()
2022-10-12 14:13:20 +08:00
if ( ENABLE_THREADS )
2024-09-25 16:41:55 +08:00
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_THREADS=1 )
2022-10-13 18:12:54 +08:00
if ( CMAKE_USE_PTHREADS_INIT ) #Threads::Threads is not set for WIN32
target_link_libraries ( libfastfetch PRIVATE Threads::Threads )
endif ()
2022-10-12 14:13:20 +08:00
endif ()
2024-09-25 16:41:55 +08:00
if ( ENABLE_EMBEDDED_PCIIDS )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_EMBEDDED_PCIIDS=1 )
endif ()
2025-02-13 10:43:11 +08:00
if ( ENABLE_EMBEDDED_AMDGPUIDS )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_EMBEDDED_AMDGPUIDS=1 )
endif ()
2024-09-25 16:41:55 +08:00
2023-08-09 16:07:01 +08:00
if ( LINUX )
target_link_libraries ( libfastfetch
PRIVATE "m"
)
2024-09-27 00:19:07 +08:00
if ( ENABLE_DIRECTX_HEADERS )
if ( NOT BINARY_LINK_TYPE STREQUAL "dlopen" )
target_link_libraries ( libfastfetch
PRIVATE "/usr/lib/wsl/lib/libdxcore.so"
)
endif ()
endif ()
2023-08-09 16:07:01 +08:00
elseif ( APPLE )
2022-09-14 09:51:08 -07:00
target_link_libraries ( libfastfetch
2024-02-02 15:09:54 +08:00
PRIVATE "-framework AVFoundation"
2022-09-17 15:39:07 +08:00
PRIVATE "-framework Cocoa"
2023-03-01 15:40:18 +08:00
PRIVATE "-framework CoreFoundation"
2023-01-25 14:28:13 +08:00
PRIVATE "-framework CoreAudio"
2024-02-02 15:09:54 +08:00
PRIVATE "-framework CoreMedia"
2023-01-24 11:21:08 +08:00
PRIVATE "-framework CoreVideo"
2023-03-01 15:40:18 +08:00
PRIVATE "-framework CoreWLAN"
2023-01-24 22:13:53 +08:00
PRIVATE "-framework IOBluetooth"
2023-03-01 15:40:18 +08:00
PRIVATE "-framework IOKit"
2023-12-29 15:12:41 +08:00
PRIVATE "-framework Metal"
2023-03-01 15:40:18 +08:00
PRIVATE "-framework OpenGL"
PRIVATE "-framework OpenCL"
2023-04-18 14:57:25 +08:00
PRIVATE "-framework SystemConfiguration"
2023-03-01 15:40:18 +08:00
PRIVATE "-weak_framework CoreDisplay"
2023-10-27 16:59:10 +08:00
PRIVATE "-F /System/Library/PrivateFrameworks"
PRIVATE "-weak_framework DisplayServices"
PRIVATE "-weak_framework MediaRemote"
2022-09-14 09:51:08 -07:00
)
2022-10-14 16:39:48 +08:00
elseif ( WIN32 )
2022-10-05 00:41:43 +08:00
target_link_libraries ( libfastfetch
2022-10-09 23:23:46 +08:00
PRIVATE "dwmapi"
PRIVATE "gdi32"
PRIVATE "iphlpapi"
2022-10-14 16:39:48 +08:00
PRIVATE "ole32"
PRIVATE "oleaut32"
2022-10-12 19:35:23 +08:00
PRIVATE "ws2_32"
2022-10-15 19:51:33 +08:00
PRIVATE "ntdll"
2022-10-15 22:35:04 +08:00
PRIVATE "version"
2023-03-24 23:38:29 +08:00
PRIVATE "hid"
2022-11-23 19:11:10 +08:00
PRIVATE "wtsapi32"
2024-08-22 16:41:06 +08:00
PRIVATE "imagehlp"
2024-10-09 21:43:33 +08:00
PRIVATE "cfgmgr32"
2024-11-06 00:16:05 +08:00
PRIVATE "propsys"
2025-04-09 14:58:36 +08:00
PRIVATE "secur32"
2022-10-05 00:41:43 +08:00
)
2025-09-25 16:15:02 +08:00
if ( CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64" )
2025-04-15 16:39:34 +08:00
# WoA only works on Windows 10 or higher
target_link_libraries ( libfastfetch
PRIVATE "mincore"
)
endif ()
2024-08-05 08:54:25 +08:00
elseif ( FreeBSD )
2023-06-15 14:22:47 +00:00
target_link_libraries ( libfastfetch
2023-08-22 16:14:24 +08:00
PRIVATE "m"
2023-06-15 14:22:47 +00:00
PRIVATE "usbhid"
2024-12-26 15:34:17 +08:00
PRIVATE "bluetooth"
2023-06-15 14:22:47 +00:00
)
2024-11-03 08:35:11 +08:00
if ( NOT DragonFly )
target_link_libraries ( libfastfetch
PRIVATE "geom"
)
2024-11-03 18:05:56 +08:00
else ()
target_link_libraries ( libfastfetch
PRIVATE "devstat"
)
2024-11-03 08:35:11 +08:00
endif ()
2024-10-04 15:58:17 +08:00
elseif ( OpenBSD )
target_link_libraries ( libfastfetch
PRIVATE "m"
PRIVATE "kvm"
2025-01-27 00:30:55 +08:00
PRIVATE "sndio"
2024-10-04 15:58:17 +08:00
)
2024-10-27 11:50:30 +08:00
elseif ( NetBSD )
target_link_libraries ( libfastfetch
2025-04-15 19:05:31 +08:00
PRIVATE "bluetooth"
2024-10-27 11:50:30 +08:00
PRIVATE "m"
2024-12-21 14:08:30 +08:00
PRIVATE "prop"
2024-10-27 11:50:30 +08:00
)
2024-06-16 01:02:48 +08:00
elseif ( SunOS )
target_link_libraries ( libfastfetch
PRIVATE "m"
PRIVATE "socket"
2024-06-17 01:01:21 +08:00
PRIVATE "kstat"
2024-06-17 13:35:26 +08:00
PRIVATE "proc"
2024-08-30 21:24:29 +08:00
PRIVATE "zfs"
PRIVATE "nvpair"
2025-06-21 20:35:26 +08:00
PRIVATE "devinfo"
2024-06-16 01:02:48 +08:00
)
2025-05-19 15:07:46 +00:00
elseif ( GNU )
target_link_libraries ( libfastfetch
PRIVATE "m"
)
2023-08-14 10:33:11 +08:00
elseif ( ANDROID )
2025-08-30 13:30:37 +08:00
target_link_libraries ( libfastfetch
PRIVATE "m"
)
2025-10-16 15:29:24 +08:00
if ( ENABLE_WORDEXP )
# https://github.com/termux/termux-packages/pull/7056
CHECK_LIBRARY_EXISTS ( -l:libandroid-wordexp.a wordexp "" HAVE_LIBANDROID_WORDEXP_STATIC )
if ( HAVE_LIBANDROID_WORDEXP_STATIC )
2023-08-14 10:51:54 +08:00
target_link_libraries ( libfastfetch
2025-10-16 15:29:24 +08:00
PRIVATE -l:libandroid-wordexp.a
2023-08-14 10:51:54 +08:00
)
2025-10-16 15:29:24 +08:00
else ()
CHECK_LIBRARY_EXISTS ( android-wordexp wordexp "" HAVE_LIBANDROID_WORDEXP )
if ( HAVE_LIBANDROID_WORDEXP )
target_link_libraries ( libfastfetch
PRIVATE android-wordexp
)
endif ()
2023-08-14 10:51:54 +08:00
endif ()
2023-08-14 10:33:11 +08:00
endif ()
2025-02-05 02:08:28 +01:00
elseif ( Haiku )
target_link_libraries ( libfastfetch
PRIVATE "network"
2025-02-15 18:53:59 +01:00
PRIVATE "bnetapi"
2025-02-12 00:17:36 +08:00
PRIVATE "media"
2025-02-16 20:18:04 +08:00
PRIVATE "device"
2025-02-16 20:37:21 +08:00
PRIVATE "bluetooth"
2025-02-16 22:52:51 +08:00
PRIVATE "GL"
2025-02-05 02:08:28 +01:00
PRIVATE "be"
2025-02-05 15:44:03 +08:00
PRIVATE "gnu"
2025-02-05 02:08:28 +01:00
)
2022-09-14 09:51:08 -07:00
endif ()
2022-09-14 14:55:28 +02:00
2022-02-09 15:20:07 +01:00
target_include_directories ( libfastfetch
PUBLIC ${ PROJECT_BINARY_DIR }
PUBLIC ${ PROJECT_SOURCE_DIR } /src
2021-04-09 14:07:05 +02:00
)
2022-02-09 15:20:07 +01:00
target_link_libraries ( libfastfetch
PRIVATE ${ CMAKE_DL_LIBS }
2021-02-18 22:25:36 +01:00
)
2024-06-11 19:48:25 +08:00
target_compile_options ( libfastfetch PRIVATE
$< $<COMPILE_LANGUAGE:CXX > :-fno-exceptions -fno-rtti> )
2024-06-11 16:41:57 +08:00
if ( WIN32 )
set ( CMAKE_CXX_STANDARD 20 )
include ( CheckIncludeFileCXX )
2024-06-11 19:48:25 +08:00
CHECK_INCLUDE_FILE_CXX ( "winrt/Windows.Foundation.h" HAVE_WINRT )
2024-06-11 16:41:57 +08:00
if ( HAVE_WINRT )
2024-06-28 15:15:49 +08:00
add_library ( ffwinrt MODULE src/detection/media/media_windows.dll.cpp )
2024-06-11 16:41:57 +08:00
target_link_libraries ( ffwinrt PRIVATE "RuntimeObject" )
2024-06-11 19:48:25 +08:00
target_compile_definitions ( ffwinrt PRIVATE WIN32_LEAN_AND_MEAN=1 WINRT_LEAN_AND_MEAN=1 )
target_link_options ( ffwinrt
PRIVATE "-static" # stdc++, winpthread, gcc_s, etc.
)
2024-06-11 16:41:57 +08:00
endif ()
2024-07-30 11:06:27 +08:00
set ( CMAKE_CXX_STANDARD 17 )
endif ()
2024-08-28 21:33:17 +08:00
if ( FreeBSD )
2024-10-29 09:22:09 +08:00
set ( CMAKE_REQUIRED_INCLUDES "/usr/local/include" "/usr/include" )
2024-08-28 21:33:17 +08:00
endif ()
2024-10-29 09:22:09 +08:00
if ( LINUX OR FreeBSD OR OpenBSD OR NetBSD )
2024-07-30 11:06:27 +08:00
CHECK_INCLUDE_FILE ( "linux/videodev2.h" HAVE_LINUX_VIDEODEV2 )
if ( HAVE_LINUX_VIDEODEV2 )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_LINUX_VIDEODEV2=1 )
endif ()
2024-08-28 21:33:17 +08:00
endif ()
if ( LINUX )
2024-07-30 11:06:27 +08:00
CHECK_INCLUDE_FILE ( "linux/wireless.h" HAVE_LINUX_WIRELESS )
if ( HAVE_LINUX_WIRELESS )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_LINUX_WIRELESS=1 )
endif ()
endif ()
if ( NOT WIN32 )
CHECK_INCLUDE_FILE ( "utmpx.h" HAVE_UTMPX )
if ( HAVE_UTMPX )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_UTMPX=1 )
endif ()
2025-10-16 15:29:24 +08:00
if ( ENABLE_WORDEXP )
CHECK_INCLUDE_FILE ( "wordexp.h" HAVE_WORDEXP )
if ( HAVE_WORDEXP )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_WORDEXP=1 )
endif ()
2024-07-30 11:06:27 +08:00
endif ()
2024-08-14 08:57:11 +08:00
if ( ENABLE_THREADS AND CMAKE_USE_PTHREADS_INIT )
2024-08-10 07:41:31 +08:00
CHECK_INCLUDE_FILE ( "pthread_np.h" HAVE_PTHREAD_NP )
if ( HAVE_PTHREAD_NP )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_PTHREAD_NP=1 )
2024-08-14 08:57:11 +08:00
set ( CMAKE_REQUIRED_INCLUDES ${ CMAKE_REQUIRED_INCLUDES } pthread_np.h )
2024-08-10 07:41:31 +08:00
endif ()
2024-08-14 08:57:11 +08:00
set ( CMAKE_REQUIRED_LIBRARIES ${ CMAKE_REQUIRED_LIBRARIES } Threads::Threads )
2024-08-10 07:41:31 +08:00
check_function_exists ( "pthread_timedjoin_np" HAVE_TIMEDJOIN_NP )
if ( HAVE_TIMEDJOIN_NP )
target_compile_definitions ( libfastfetch PRIVATE FF_HAVE_TIMEDJOIN_NP=1 )
else ()
message ( WARNING "pthread_timedjoin_np was not found; networking timeout will not work" )
endif ()
2024-07-30 11:06:27 +08:00
endif ()
2024-06-11 16:41:57 +08:00
endif ()
2024-09-13 15:45:53 +08:00
set ( PACKAGES_DISABLE_LIST "" )
foreach ( package_manager ${ PACKAGE_MANAGERS } )
if ( PACKAGES_DISABLE_ ${ package_manager } )
list ( APPEND PACKAGES_DISABLE_LIST "${package_manager}" )
endif ()
endforeach ()
if ( "${PACKAGES_DISABLE_LIST}" STREQUAL "" )
set ( PACKAGES_DISABLE_LIST "FF_PACKAGES_FLAG_NONE" )
else ()
message ( STATUS "Disabled package managers: ${PACKAGES_DISABLE_LIST}" )
list ( TRANSFORM PACKAGES_DISABLE_LIST PREPEND "FF_PACKAGES_FLAG_" )
list ( TRANSFORM PACKAGES_DISABLE_LIST APPEND "_BIT" )
list ( JOIN PACKAGES_DISABLE_LIST " | " PACKAGES_DISABLE_LIST )
endif ()
target_compile_definitions ( libfastfetch PRIVATE FF_PACKAGES_DISABLE_LIST= ${ PACKAGES_DISABLE_LIST } )
2022-06-08 16:25:14 +02:00
######################
# Executable targets #
######################
2022-02-09 15:20:07 +01:00
2021-02-27 18:30:05 +01:00
add_executable ( fastfetch
src/fastfetch.c
2022-02-09 15:20:07 +01:00
)
2022-12-08 18:33:43 +08:00
target_compile_definitions ( fastfetch
2022-12-10 13:10:06 +08:00
PRIVATE FASTFETCH_TARGET_BINARY_NAME=fastfetch
2022-12-08 18:33:43 +08:00
)
2022-02-09 15:20:07 +01:00
target_link_libraries ( fastfetch
PRIVATE libfastfetch
2021-02-27 18:30:05 +01:00
)
2024-06-11 16:41:57 +08:00
# Prevent fastfetch from linking to libstdc++
set ( CMAKE_CXX_IMPLICIT_LINK_LIBRARIES "" )
set ( CMAKE_CXX_IMPLICIT_LINK_DIRECTORIES "" )
set_target_properties ( fastfetch PROPERTIES LINKER_LANGUAGE C )
2023-09-20 23:55:36 +08:00
2022-11-06 01:33:06 +08:00
if ( WIN32 )
target_sources ( fastfetch
2022-12-08 18:33:43 +08:00
PRIVATE src/util/windows/version.rc
2022-11-06 01:33:06 +08:00
)
2023-10-11 15:17:14 +08:00
elseif ( APPLE )
target_link_options ( fastfetch
PRIVATE LINKER:-sectcreate,__TEXT,__info_plist,Info.plist
)
2022-11-06 01:33:06 +08:00
endif ()
2024-05-24 14:40:14 +08:00
if ( BINARY_LINK_TYPE STREQUAL "static" )
target_link_options ( fastfetch PRIVATE "-static" )
2024-12-21 16:53:02 +01:00
endif ()
# Apply all above parameters to flashfetch if it is built
if ( BUILD_FLASHFETCH )
add_executable ( flashfetch
src/flashfetch.c
)
target_compile_definitions ( flashfetch
PRIVATE FASTFETCH_TARGET_BINARY_NAME=flashfetch
)
target_link_libraries ( flashfetch
PRIVATE libfastfetch
)
set_target_properties ( flashfetch PROPERTIES LINKER_LANGUAGE C )
if ( WIN32 )
target_sources ( flashfetch
PRIVATE src/util/windows/version.rc
)
elseif ( APPLE )
target_link_options ( flashfetch
PRIVATE LINKER:-sectcreate,__TEXT,__info_plist,Info.plist
)
endif ()
if ( BINARY_LINK_TYPE STREQUAL "static" )
target_link_options ( flashfetch PRIVATE "-static" )
endif ()
2024-05-24 14:40:14 +08:00
endif ()
2022-06-08 16:25:14 +02:00
###################
# Testing targets #
###################
2022-02-21 11:40:33 +05:00
2022-02-21 12:22:29 +05:00
if ( BUILD_TESTS )
add_executable ( fastfetch-test-strbuf
tests/strbuf.c
)
target_link_libraries ( fastfetch-test-strbuf
PRIVATE libfastfetch
)
2022-09-20 22:45:36 +08:00
add_executable ( fastfetch-test-list
tests/list.c
)
target_link_libraries ( fastfetch-test-list
PRIVATE libfastfetch
)
2024-09-02 15:54:22 +08:00
add_executable ( fastfetch-test-format
tests/format.c
)
target_link_libraries ( fastfetch-test-format
PRIVATE libfastfetch
)
2025-04-17 10:48:18 +08:00
add_executable ( fastfetch-test-color
tests/color.c
)
target_link_libraries ( fastfetch-test-color
PRIVATE libfastfetch
)
2025-04-29 10:20:23 +08:00
add_executable ( fastfetch-test-duration
tests/duration.c
)
target_link_libraries ( fastfetch-test-duration
PRIVATE libfastfetch
)
2022-02-21 12:22:29 +05:00
enable_testing ()
add_test ( NAME test-strbuf COMMAND fastfetch-test-strbuf )
2022-09-20 22:45:36 +08:00
add_test ( NAME test-list COMMAND fastfetch-test-list )
2024-09-02 15:54:22 +08:00
add_test ( NAME test-format COMMAND fastfetch-test-format )
2025-04-17 10:48:18 +08:00
add_test ( NAME test-color COMMAND fastfetch-test-color )
2025-04-29 10:20:23 +08:00
add_test ( NAME test-duration COMMAND fastfetch-test-duration )
2022-02-21 12:22:29 +05:00
endif ()
2022-02-21 11:40:33 +05:00
2022-06-08 16:25:14 +02:00
##################
# install target #
##################
2022-03-25 11:57:58 +01:00
include ( GNUInstallDirs )
2022-02-21 11:40:33 +05:00
2022-03-08 11:59:06 +01:00
install (
2024-12-21 16:53:02 +01:00
TARGETS fastfetch
2022-07-27 21:56:28 +02:00
DESTINATION "${CMAKE_INSTALL_BINDIR}"
2022-03-08 11:59:06 +01:00
)
2022-02-21 11:40:33 +05:00
2024-12-21 16:53:02 +01:00
if ( TARGET flashfetch )
install (
TARGETS flashfetch
DESTINATION "${CMAKE_INSTALL_BINDIR}"
)
endif ()
2024-06-21 09:43:18 +08:00
if ( TARGET ffwinrt )
install (
TARGETS ffwinrt
DESTINATION "${CMAKE_INSTALL_BINDIR}"
)
endif ()
2022-03-08 11:59:06 +01:00
install (
2024-05-30 21:37:05 +08:00
FILES "${CMAKE_SOURCE_DIR}/completions/${CMAKE_PROJECT_NAME}.bash"
2022-07-27 21:56:28 +02:00
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/bash-completion/completions"
RENAME "${CMAKE_PROJECT_NAME}"
2022-02-21 11:40:33 +05:00
)
2024-08-25 19:58:47 +06:00
install (
FILES "${CMAKE_SOURCE_DIR}/completions/${CMAKE_PROJECT_NAME}.zsh"
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/zsh/site-functions"
RENAME "_${CMAKE_PROJECT_NAME}"
)
2023-12-06 10:38:55 +08:00
install (
2024-05-30 21:37:05 +08:00
FILES "${CMAKE_SOURCE_DIR}/completions/${CMAKE_PROJECT_NAME}.fish"
2023-12-06 10:38:55 +08:00
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/fish/vendor_completions.d"
RENAME "${CMAKE_PROJECT_NAME}.fish"
)
2022-03-08 11:59:06 +01:00
install (
2022-08-12 21:39:27 +03:00
DIRECTORY "${CMAKE_SOURCE_DIR}/presets"
2022-07-27 21:56:28 +02:00
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/${CMAKE_PROJECT_NAME}"
2022-03-08 11:59:06 +01:00
)
2024-05-30 21:36:57 +08:00
if ( INSTALL_LICENSE )
install (
FILES "${CMAKE_SOURCE_DIR}/LICENSE"
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/licenses/${CMAKE_PROJECT_NAME}"
)
endif ()
2022-03-25 11:57:58 +01:00
2023-11-18 15:18:08 +01:00
install (
FILES "${PROJECT_BINARY_DIR}/fastfetch.1"
2023-12-05 14:05:52 +02:00
DESTINATION "${CMAKE_INSTALL_MANDIR}/man1"
2023-11-18 15:18:08 +01:00
)
2022-06-08 16:25:14 +02:00
##################
# package target #
##################
2022-03-25 11:57:58 +01:00
2022-09-11 10:47:47 +02:00
set ( CPACK_GENERATOR "TGZ;ZIP" )
2024-02-10 13:14:43 +08:00
if ( APPLE )
2025-06-17 09:01:38 +08:00
string ( TOLOWER "${CMAKE_PROJECT_NAME}-macos-${CMAKE_SYSTEM_PROCESSOR}" CPACK_PACKAGE_FILE_NAME ) # use macos instead of darwin
elseif ( IS_MUSL )
string ( TOLOWER "${CMAKE_PROJECT_NAME}-musl-${CMAKE_SYSTEM_PROCESSOR}" CPACK_PACKAGE_FILE_NAME )
else ()
string ( TOLOWER "${CMAKE_PROJECT_NAME}-${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}" CPACK_PACKAGE_FILE_NAME )
2024-02-10 13:14:43 +08:00
endif ()
2022-09-11 10:47:47 +02:00
if ( LINUX )
2024-04-16 21:54:52 +08:00
find_program ( HAVE_DPKG "dpkg" )
2024-04-23 15:05:55 +04:00
if ( HAVE_DPKG )
set ( CPACK_GENERATOR "${CPACK_GENERATOR};DEB" )
set ( CPACK_DEBIAN_PACKAGE_SECTION, "utils" )
set ( CPACK_DEBIAN_PACKAGE_PRIORITY "optional" )
2024-05-05 21:29:32 +08:00
if ( NOT IS_MUSL )
2024-07-03 09:54:00 +08:00
EXECUTE_PROCESS (
2024-05-05 21:29:32 +08:00
COMMAND getconf GNU_LIBC_VERSION
OUTPUT_VARIABLE GLIBC_VERSION
OUTPUT_STRIP_TRAILING_WHITESPACE )
2024-07-03 09:54:00 +08:00
if ( GLIBC_VERSION )
STRING ( REPLACE "glibc " "" GLIBC_VERSION ${ GLIBC_VERSION } )
set ( CPACK_DEBIAN_PACKAGE_DEPENDS "libc6 (>= ${GLIBC_VERSION})" )
message ( STATUS "found glibc ${GLIBC_VERSION}" )
else ()
message ( WARNING "Could not determine glibc version. If `musl` is used, `-DIS_MUSL=ON` should be set" )
endif ()
2024-05-05 21:29:32 +08:00
endif ()
2024-04-16 21:54:52 +08:00
endif ()
2022-09-11 10:47:47 +02:00
2025-06-04 09:05:04 +08:00
if ( NOT IS_MUSL )
find_program ( HAVE_RPMBUILD "rpmbuild" )
if ( HAVE_RPMBUILD )
set ( CPACK_GENERATOR "${CPACK_GENERATOR};RPM" )
2022-09-11 10:47:47 +02:00
2025-06-04 09:05:04 +08:00
set ( CPACK_RPM_PACKAGE_LICENSE "MIT" )
endif ()
2024-04-23 15:05:55 +04:00
endif ()
2025-06-02 15:56:18 +08:00
elseif ( FreeBSD )
2025-06-02 19:15:14 +08:00
set ( CPACK_FREEBSD_PACKAGE_LICENSE "MIT" )
2025-06-02 15:56:18 +08:00
set ( CPACK_GENERATOR "${CPACK_GENERATOR};FREEBSD" )
2022-09-11 10:47:47 +02:00
endif ()
2022-07-26 22:13:09 +02:00
set ( CPACK_SET_DESTDIR ON )
2022-03-25 11:57:58 +01:00
2025-09-28 14:36:55 +08:00
set ( CPACK_PACKAGE_CONTACT "Carter Li <zhangsongcui@live.cn>" )
2022-04-23 11:24:24 +02:00
set ( CPACK_PACKAGE_DESCRIPTION "\
fastfetch is a neofetch-like tool for fetching system information and displaying them in a pretty way. \
2024-02-10 13:14:43 +08:00
It is written mostly in C to achieve much better performance.\
2022-03-25 11:57:58 +01:00
" )
2024-10-06 12:31:47 +08:00
include ( CPack )