From 48dd7b8c2ef7056ff4730c378ccd7e9445b5e40f Mon Sep 17 00:00:00 2001 From: Kinsey Moore Date: Mon, 29 Jun 2020 14:35:08 -0500 Subject: score: Add CPU_USE_LIBC_INIT_FINI_ARRAY This introduces the CPU_USE_LIBC_INIT_FINI_ARRAY define for use by CPU ports to determine which global constructor and destructor methods are used instead of placing architecture defines where they shouldn't be. Close #4018 --- cpukit/libcsupport/src/newlibc_exit.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'cpukit/libcsupport/src') diff --git a/cpukit/libcsupport/src/newlibc_exit.c b/cpukit/libcsupport/src/newlibc_exit.c index 650b692c74..d29214af3f 100644 --- a/cpukit/libcsupport/src/newlibc_exit.c +++ b/cpukit/libcsupport/src/newlibc_exit.c @@ -17,11 +17,8 @@ #include #include -/* FIXME: These defines are a blatant hack */ - #if defined(__USE_INIT_FINI__) - #if defined(__ARM_EABI__) || defined(__riscv) \ - || defined(__or1k__) || defined(__or1knd__) + #if CPU_USE_LIBC_INIT_FINI_ARRAY == TRUE #define FINI_SYMBOL __libc_fini_array #else #define FINI_SYMBOL _fini -- cgit v1.2.3