From 0af461a4e318898f72e392d53b7067225313b22c Mon Sep 17 00:00:00 2001
From: Alberto Nidasio <nidasioalberto@gmail.com>
Date: Mon, 1 Jul 2024 14:38:20 +0200
Subject: [PATCH] Prevented redefining `_GNU_SOURCE` in stringpart.cpp

Signed-off-by: Terraneo Federico <fede.tft@miosix.org>
---
 miosix/filesystem/stringpart.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/miosix/filesystem/stringpart.cpp b/miosix/filesystem/stringpart.cpp
index d70f3ded..03be75b8 100644
--- a/miosix/filesystem/stringpart.cpp
+++ b/miosix/filesystem/stringpart.cpp
@@ -26,7 +26,9 @@
  ***************************************************************************/
 
 //Makes memrchr available in newer GCCs
+#ifndef _GNU_SOURCE
 #define _GNU_SOURCE
+#endif
 #include <string.h>
 
 #include "stringpart.h"
-- 
GitLab