From 43073cfdbb8a249bcb8e733add833f4cc8e91d97 Mon Sep 17 00:00:00 2001 From: apio Date: Fri, 21 Oct 2022 18:39:46 +0200 Subject: [PATCH] Add new __lc_used macro --- libs/libc/include/bits/macros.h | 1 + libs/libc/src/init.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/libs/libc/include/bits/macros.h b/libs/libc/include/bits/macros.h index 02af796b..390352ba 100644 --- a/libs/libc/include/bits/macros.h +++ b/libs/libc/include/bits/macros.h @@ -5,5 +5,6 @@ #define __lc_align(n) __attribute__((aligned(n))) #define __lc_deprecated(msg) __attribute__((deprecated(msg))) #define __lc_unreachable __builtin_unreachable +#define __lc_used __attribute__((used)) #endif \ No newline at end of file diff --git a/libs/libc/src/init.cpp b/libs/libc/src/init.cpp index 93f0f37c..07caefc2 100644 --- a/libs/libc/src/init.cpp +++ b/libs/libc/src/init.cpp @@ -4,7 +4,7 @@ #include #include -__attribute__((used)) const char* __argv[] = {NULL}; // For now. +__lc_used const char* __argv[] = {NULL}; // For now. static void terminate_libc() {