From d745d7afef18cf441fa5356a3a744a26b1cfa072 Mon Sep 17 00:00:00 2001 From: Viorel Date: Mon, 22 Apr 2024 18:22:00 +0300 Subject: [PATCH 1/3] Fix build with ENABLE_DBUS=OFF --- CHANGELOG.md | 5 +++++ src/detection/de/de_linux.c | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e7aebf98ba..5f20a840a3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +# 2.10.1 + +Bugfixes: +* fix build with ENABLE_DBUS=OFF + # 2.10.0 Changes: diff --git a/src/detection/de/de_linux.c b/src/detection/de/de_linux.c index 7fbb4652aa..9443d55fdd 100644 --- a/src/detection/de/de_linux.c +++ b/src/detection/de/de_linux.c @@ -45,12 +45,16 @@ static void getKDE(FFstrbuf* result, FFDEOptions* options) static const char* getGnomeBySo(FFstrbuf* result) { +#ifdef FF_HAVE_DBUS FFDBusData dbus; if (ffDBusLoadData(DBUS_BUS_SESSION, &dbus) != NULL) return "ffDBusLoadData() failed"; ffDBusGetPropertyString(&dbus, "org.gnome.Shell", "/org/gnome/Shell", "org.gnome.Shell", "ShellVersion", result); return NULL; +#else // FF_HAVE_DBUS + return "ffDBusLoadData() failed: dbus support not compiled in"; +#endif // FF_HAVE_DBUS } static void getGnome(FFstrbuf* result, FF_MAYBE_UNUSED FFDEOptions* options) From 84ee7cef7c0ffb275d607e7cbc51e25bc09ec319 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= Date: Mon, 22 Apr 2024 23:38:43 +0800 Subject: [PATCH 2/3] DE (Linux): silence warnings --- src/detection/de/de_linux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/detection/de/de_linux.c b/src/detection/de/de_linux.c index 9443d55fdd..6c456495e2 100644 --- a/src/detection/de/de_linux.c +++ b/src/detection/de/de_linux.c @@ -43,7 +43,7 @@ static void getKDE(FFstrbuf* result, FFDEOptions* options) } } -static const char* getGnomeBySo(FFstrbuf* result) +static const char* getGnomeByDbus(FF_MAYBE_UNUSED FFstrbuf* result) { #ifdef FF_HAVE_DBUS FFDBusData dbus; @@ -59,7 +59,7 @@ static const char* getGnomeBySo(FFstrbuf* result) static void getGnome(FFstrbuf* result, FF_MAYBE_UNUSED FFDEOptions* options) { - getGnomeBySo(result); + getGnomeByDbus(result); if (result->length == 0 && options->slowVersionDetection) { From 3fa308386ff06455458763a8f0c76344d76200eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= Date: Mon, 22 Apr 2024 23:44:21 +0800 Subject: [PATCH 3/3] Release: v2.10.1 --- CHANGELOG.md | 2 +- CMakeLists.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5f20a840a3..918416f5bd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,7 @@ # 2.10.1 Bugfixes: -* fix build with ENABLE_DBUS=OFF +* fix build with `-DENABLE_DBUS=OFF` # 2.10.0 diff --git a/CMakeLists.txt b/CMakeLists.txt index 6ee082f535..ecd30934ab 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.12.0) # target_link_libraries with OBJECT libs & project homepage url project(fastfetch - VERSION 2.10.0 + VERSION 2.10.1 LANGUAGES C DESCRIPTION "Fast neofetch-like system information tool" HOMEPAGE_URL "https://github.com/fastfetch-cli/fastfetch"