This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
     new 4d9f67940c nuttx/toolchain: Add macro _LDBL_EQ_DBL to 
nuttx/arch/arm64/src/Toolchain.defs
4d9f67940c is described below

commit 4d9f67940c920a3b667a1547e14b05cb003784e3
Author: yanghuatao <yanghua...@xiaomi.com>
AuthorDate: Fri Jul 7 11:36:34 2023 +0800

    nuttx/toolchain: Add macro _LDBL_EQ_DBL to 
nuttx/arch/arm64/src/Toolchain.defs
    
    Fix goldfish build toolchain math library error:
    /mnt/yang/vela_Goldfish/nuttx/include/libcxx/cmath:454:9: error: 
'nexttowardf' has not been declared in '::'
      454 | using ::nexttowardf;
          |         ^~~~~~~~~~~
    /mnt/yang/vela_Goldfish/nuttx/include/libcxx/cmath:472:9: error: 'acosl' 
has not been declared in '::'
      472 | using ::acosl;
          |         ^~~~~
    /mnt/yang/vela_Goldfish/nuttx/include/libcxx/cmath:473:9: error: 'asinl' 
has not been declared in '::'
      473 | using ::asinl;
          |         ^~~~~
    
    Signed-off-by: yanghuatao <yanghua...@xiaomi.com>
---
 arch/arm64/src/Toolchain.defs | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/arm64/src/Toolchain.defs b/arch/arm64/src/Toolchain.defs
index a62d87c14e..c8d6052ca2 100644
--- a/arch/arm64/src/Toolchain.defs
+++ b/arch/arm64/src/Toolchain.defs
@@ -80,6 +80,11 @@ ifeq ($(CONFIG_MM_UBSAN_TRAP_ON_ERROR),y)
   ARCHOPTIMIZATION += -fsanitize-undefined-trap-on-error
 endif
 
+ifeq ($(CONFIG_ARCH_FPU),y)
+  ARCHCXXFLAGS += -D_LDBL_EQ_DBL
+  ARCHCFLAGS   += -D_LDBL_EQ_DBL
+endif
+
 ARCHCFLAGS += -fno-common
 ARCHCXXFLAGS += -fno-common -nostdinc++
 

Reply via email to