import: Make.defs: Fix 'make import' for CONFIG_BUILD_KERNEL=y
Summary: - I noticed that 'make import' failed due to recent changes in nuttx - This commit fixes this issue by adding logic for -lm - Also applies the same style for -lgcc Impact: - CONFIG_BUILD_KERNEL=y only Testing: - Build (mkimport, make import) with sama5d4-ek:knsh Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
This commit is contained in:
parent
f6f4bbff3a
commit
cecc83d6b9
@ -77,14 +77,21 @@ endif
|
|||||||
# Link with user libraries
|
# Link with user libraries
|
||||||
|
|
||||||
ifeq ($(CONFIG_BUILD_KERNEL),y)
|
ifeq ($(CONFIG_BUILD_KERNEL),y)
|
||||||
LDLIBS = -lapps -lxx -lmm -lc -lm -lproxies
|
LDLIBS = -lapps -lxx -lmm -lc -lproxies
|
||||||
|
ifneq ($(CONFIG_LIBM),y)
|
||||||
|
LIBM = ${shell "$(CC)" $(ARCHCPUFLAGS) --print-file-name=libm.a}
|
||||||
|
ifneq ($(LIBM),".")
|
||||||
|
LDLIBPATH += -L "${shell dirname $(LIBM)}"
|
||||||
|
LDLIBS += -lm
|
||||||
|
endif
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Try to get the path to libgcc.a. Of course, this only works for GCC
|
# Try to get the path to libgcc.a. Of course, this only works for GCC
|
||||||
# toolchains.
|
# toolchains.
|
||||||
|
|
||||||
LIBGCC = ${shell "$(CC)" $(ARCHCPUFLAGS) -print-file-name=libgcc.a}
|
LIBGCC = ${shell "$(CC)" $(ARCHCPUFLAGS) --print-file-name=libgcc.a}
|
||||||
ifneq ($(LIBGCC),)
|
ifneq ($(LIBGCC),".")
|
||||||
LDLIBPATH += -L "${shell dirname $(LIBGCC)}"
|
LDLIBPATH += -L "${shell dirname $(LIBGCC)}"
|
||||||
LDLIBS += -lgcc
|
LDLIBS += -lgcc
|
||||||
endif
|
endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user