File tree Expand file tree Collapse file tree 2 files changed +21
-1
lines changed
Expand file tree Collapse file tree 2 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -546,7 +546,7 @@ elseif(APPLE)
546546 src/detection/host/host_apple .c
547547 src/detection/lm/lm_nosupport.c
548548 src/detection/icons/icons_nosupport.c
549- src/detection/libc/libc_nosupport .c
549+ src/detection/libc/libc_apple .c
550550 src/detection/localip/localip_linux.c
551551 src/detection/gamepad/gamepad_apple.c
552552 src/detection/media/media_apple.m
@@ -670,6 +670,13 @@ if(LINUX AND EXISTS "/lib/ld-musl-${CMAKE_HOST_SYSTEM_PROCESSOR}.so.1")
670670 target_compile_definitions (libfastfetch PUBLIC FF_MUSL_VERSION="${CMAKE_MATCH_1} " )
671671 endif ()
672672endif ()
673+ if (APPLE AND EXISTS "/usr/bin/otool" )
674+ execute_process (COMMAND /usr/bin/otool -L /usr/bin/otool
675+ OUTPUT_VARIABLE OTOOL_OTOOL_RESULT)
676+ if ("${OTOOL_OTOOL_RESULT} " MATCHES "libSystem\\ .B\\ .dylib \\ (.*current version ([0-9]+\\ .[0-9]+\\ .[0-9]+)\\ )" )
677+ target_compile_definitions (libfastfetch PUBLIC FF_LIBSYSTEM_VERSION="${CMAKE_MATCH_1} " )
678+ endif ()
679+ endif ()
673680
674681target_compile_definitions (libfastfetch PUBLIC _GNU_SOURCE _XOPEN_SOURCE __STDC_WANT_LIB_EXT1__=1)
675682if (WIN32 )
Original file line number Diff line number Diff line change 1+ #include "libc.h"
2+
3+ const char * ffDetectLibc (FFLibcResult * result )
4+ {
5+ result -> name = "libSystem" ;
6+
7+ #ifdef FF_LIBSYSTEM_VERSION
8+ result -> version = FF_LIBSYSTEM_VERSION ;
9+ #else
10+ result -> version = NULL ;
11+ #endif
12+ return NULL ;
13+ }
You can’t perform that action at this time.
0 commit comments