build: build libc as object, not kbuild library (lib.a)
The way we build the libc files is not a real library that can be used as a libc and makes managing the source files a bit difficult, so lets revert back to building the c function files like everything else in the system to avoid any confusion. Change-Id: I4e998e37bc376522fe253c4aefefe7804597f0f2 Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This commit is contained in:
parent
0db074eae4
commit
8d00ec5c4e
8 changed files with 12 additions and 14 deletions
6
Makefile
6
Makefile
|
@ -519,7 +519,7 @@ scripts: scripts_basic include/config/auto.conf include/config/tristate.conf
|
|||
$(Q)$(MAKE) $(build)=$(@)
|
||||
|
||||
|
||||
core-y := arch/ kernel/ misc/ net/
|
||||
core-y := lib/ arch/ kernel/ misc/ net/
|
||||
platform-y := drivers/
|
||||
|
||||
ifneq ($(strip $(PROJECT)),)
|
||||
|
@ -551,14 +551,10 @@ include/config/auto.conf: ;
|
|||
endif # $(dot-config)
|
||||
|
||||
ifdef CONFIG_MINIMAL_LIBC
|
||||
# Objects we will link into the kernel / subdirs we need to visit
|
||||
KLIBC_DIR := lib/libc/minimal
|
||||
libs-y := $(KLIBC_DIR)/
|
||||
ZEPHYRINCLUDE += -I$(srctree)/lib/libc/minimal/include
|
||||
endif
|
||||
|
||||
ifdef CONFIG_TOOLCHAIN_NEWLIB
|
||||
libs-y += lib/libc/newlib/
|
||||
ALL_LIBS += c m
|
||||
endif
|
||||
|
||||
|
|
1
lib/Makefile
Normal file
1
lib/Makefile
Normal file
|
@ -0,0 +1 @@
|
|||
obj-y := libc/
|
|
@ -1,2 +1,2 @@
|
|||
libs-$(CONFIG_MINIMAL_LIBC) += minimal/
|
||||
libs-$(CONFIG_NEWLIB) += newlib/
|
||||
obj-$(CONFIG_MINIMAL_LIBC) += minimal/
|
||||
obj-$(CONFIG_NEWLIB) += newlib/
|
||||
|
|
|
@ -1,5 +1 @@
|
|||
lib-y := source/stdout/fprintf.o
|
||||
lib-y += source/stdout/prf.o
|
||||
lib-y += source/stdout/sprintf.o
|
||||
lib-y += source/stdout/stdout_console.o
|
||||
lib-y += source/string/string.o
|
||||
obj-y := source/
|
||||
|
|
2
lib/libc/minimal/source/Makefile
Normal file
2
lib/libc/minimal/source/Makefile
Normal file
|
@ -0,0 +1,2 @@
|
|||
obj-y := stdout/
|
||||
obj-y += string/
|
2
lib/libc/minimal/source/stdout/Makefile
Normal file
2
lib/libc/minimal/source/stdout/Makefile
Normal file
|
@ -0,0 +1,2 @@
|
|||
|
||||
obj-y = fprintf.o prf.o sprintf.o stdout_console.o
|
1
lib/libc/minimal/source/string/Makefile
Normal file
1
lib/libc/minimal/source/string/Makefile
Normal file
|
@ -0,0 +1 @@
|
|||
obj-y := string.o
|
|
@ -1 +1 @@
|
|||
lib-y := libc-hooks.o
|
||||
obj-y := libc-hooks.o
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue