mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-26 17:01:07 +00:00
70dfe4fcd7
When building the Fiasco.OC kernel, and L4Linux within the Genode build system, forward the CC, and CXX variables. It might contain useful tools like ccache, or distcc to speed up compilation. Moreover, don't delete the MAKEFLAGS when building Fiasco.OC. It hinders parallel builds.
55 lines
1.8 KiB
Makefile
55 lines
1.8 KiB
Makefile
TARGET = vmlinux
|
|
VERBOSE_LX_MK ?= 0
|
|
REQUIRES += foc
|
|
INC_DIR += $(REP_DIR)/include
|
|
LIBS = l4lx l4sys
|
|
GENODE_LIBS := allocator_avl \
|
|
avl_tree \
|
|
cap_alloc \
|
|
console \
|
|
cxx \
|
|
env \
|
|
heap \
|
|
ipc \
|
|
l4lx \
|
|
l4sys \
|
|
lock \
|
|
log_console \
|
|
signal \
|
|
slab \
|
|
startup \
|
|
syscalls \
|
|
thread
|
|
GENODE_LIBS := $(foreach l,$(GENODE_LIBS),$(BUILD_BASE_DIR)/var/libcache/$l/$l.lib.a)
|
|
GENODE_LIBS_SORTED = $(sort $(wildcard $(GENODE_LIBS)))
|
|
GENODE_LIBS_SORTED += $(shell $(CC) $(CC_MARCH) -print-libgcc-file-name)
|
|
|
|
L4LX_BUILD = $(BUILD_BASE_DIR)/$(LX_TARGET)
|
|
L4LX_BINARY = $(L4LX_BUILD)/$(TARGET)
|
|
L4LX_SYMLINK = $(BUILD_BASE_DIR)/bin/$(LX_TARGET)
|
|
L4LX_CONFIG = $(L4LX_BUILD)/.config
|
|
|
|
$(TARGET): $(L4LX_BINARY)
|
|
|
|
$(L4LX_BINARY): $(L4LX_CONFIG)
|
|
$(VERBOSE_MK)$(MAKE) $(VERBOSE_DIR) \
|
|
-C $(REP_DIR)/contrib/$(LX_TARGET) \
|
|
O=$(L4LX_BUILD) \
|
|
CROSS_COMPILE="$(CROSS_DEV_PREFIX)" \
|
|
CC="$(CC)" \
|
|
KBUILD_VERBOSE=$(VERBOSE_LX_MK) \
|
|
V=$(VERBOSE_LX_MK) \
|
|
GENODE_INCLUDES="$(addprefix -I,$(INC_DIR))" \
|
|
GENODE_LIBS="$(GENODE_LIBS_SORTED)" \
|
|
L4ARCH="$(L4LX_L4ARCH)" || false
|
|
$(VERBOSE)ln -sf $@ $(L4LX_SYMLINK)
|
|
|
|
$(L4LX_CONFIG): $(SRC_L4LX_CONFIG)
|
|
$(VERBOSE)sed -e "s/CONFIG_L4_OBJ_TREE.*/CONFIG_L4_OBJ_TREE=\"$(subst /,\/,$(L4_BUILD_DIR))\"/" $< > $@
|
|
|
|
clean:
|
|
$(VERBOSE)rm -rf $(L4LX_BUILD)
|
|
|
|
.PHONY: $(L4LX_BINARY)
|
|
|