From aa77344bedd8ff0ad8821d45fc8832ea82b23832 Mon Sep 17 00:00:00 2001 From: = <=> Date: Mon, 29 Jan 2024 21:27:53 +0100 Subject: [PATCH 1/2] use the correct macro variable --- src/defaultfont.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/defaultfont.cpp b/src/defaultfont.cpp index 292e52b..c6f8972 100644 --- a/src/defaultfont.cpp +++ b/src/defaultfont.cpp @@ -1,6 +1,6 @@ // SPDX-License-Identifier: BSD-2-Clause -#if defined(__LINUX__) +#if defined(__linux__) #include const char *getLinuxFilePath() { From 92ab23a737b5a2013fc6c3b3095a2854560d7e07 Mon Sep 17 00:00:00 2001 From: = <=> Date: Mon, 29 Jan 2024 21:30:52 +0100 Subject: [PATCH 2/2] #ifdef instead of #if defined --- src/defaultfont.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/defaultfont.cpp b/src/defaultfont.cpp index c6f8972..f50d8ed 100644 --- a/src/defaultfont.cpp +++ b/src/defaultfont.cpp @@ -1,6 +1,6 @@ // SPDX-License-Identifier: BSD-2-Clause -#if defined(__linux__) +#ifdef __linux__ #include const char *getLinuxFilePath() { @@ -21,7 +21,7 @@ const char *getLinuxFilePath() { const char *getDefaultFontPath() { #if defined(_WIN32) || defined(_WIN64) return R"(C:\Windows\Fonts\Arial.ttf)"; -#elif defined(__linux__) +#elifdef __linux__ return getLinuxFilePath(); #elif defined(__APPLE__) || defined(__MACH__) return "/System/Library/Fonts/Supplemental/Arial.ttf";