Skip to content

Commit

Permalink
libc/newlib:Declaration of adding depth
Browse files Browse the repository at this point in the history
Resolve the issue of inability to compile when opening newlib

Signed-off-by: liwenxiang1 <[email protected]>
  • Loading branch information
xianglyc committed Oct 12, 2024
1 parent a2b129f commit e39f695
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions libs/libm/newlib/Make.defs
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ CSRCS += $(wildcard newlib/newlib/newlib/libm/complex/*.c)

VPATH += :newlib/newlib/newlib/libm/common
VPATH += :newlib/newlib/newlib/libm/complex
DEPPATH += --dep-path newlib/newlib/newlib/libm/common
DEPPATH += --dep-path newlib/newlib/newlib/libm/complex

ifeq ($(CONFIG_ARCH_ARM),y)
ARCH = arm
Expand All @@ -84,10 +86,14 @@ endif

CSRCS += $(wildcard newlib/newlib/newlib/libm/machine/$(ARCH)/*.c)
VPATH += :newlib/newlib/newlib/libm/machine/$(ARCH)
DEPPATH += --dep-path newlib/newlib/newlib/libm/machine/$(ARCH)


ifeq ($(CONFIG_ARCH_X86_64),y)
CSRCS += $(wildcard newlib/newlib/newlib/libm/fenv/*.c)
VPATH += :newlib/newlib/newlib/libm/fenv
DEPPATH += --dep-path newlib/newlib/newlib/libm/fenv


CFLAGS += ${INCDIR_PREFIX}newlib/newlib/newlib/libc/machine/shared_x86/sys
endif
Expand All @@ -98,10 +104,13 @@ endif

CSRCS += newlib/sincosl.c
VPATH += :newlib
DEPPATH += --dep-path newlib


ifeq ($(CONFIG_LIBM_NEWLIB_HW_FP),y)
CSRCS += $(wildcard newlib/newlib/newlib/libm/mathfp/*.c)
VPATH += :newlib/newlib/newlib/libm/mathfp
DEPPATH += --dep-path newlib/newlib/newlib/libm/mathfp
CFLAGS += -Wno-dangling-else
CFLAGS += -Wno-endif-labels
CFLAGS += -Wno-implicit-function-declaration
Expand All @@ -112,6 +121,7 @@ ifeq ($(CONFIG_LIBM_NEWLIB_HW_FP),y)
else
CSRCS += $(wildcard newlib/newlib/newlib/libm/math/*.c)
VPATH += :newlib/newlib/newlib/libm/math
DEPPATH += --dep-path newlib/newlib/newlib/libm/math
endif

CSRCS := $(shell echo $(notdir $(CSRCS) | tr " " "\n" | sort | uniq))
Expand Down

0 comments on commit e39f695

Please sign in to comment.