mirror of
https://github.com/genodelabs/genode.git
synced 2025-05-04 09:43:06 +00:00
Components like kernel, core, and bootstrap that are built for a specific board need to reside inside the same architectural dependent build directory. For instance there are sel4, foc, and hw kernel builds for imx6q_sabrelite and imx7d_sabre, which have to reside inside the same arm_v7 build directory. This commit names those components explicitely, and adapts the run-tool to it. Fix #3316
28 lines
653 B
PHP
28 lines
653 B
PHP
TARGET ?= core
|
|
CORE_OBJ ?= core.o
|
|
|
|
$(TARGET):
|
|
@true
|
|
|
|
ifneq ($(INSTALL_DIR),)
|
|
ifneq ($(DEBUG_DIR),)
|
|
$(TARGET): $(INSTALL_DIR)/$(CORE_OBJ) $(DEBUG_DIR)/$(CORE_OBJ)
|
|
|
|
$(CORE_OBJ).stripped: $(CORE_OBJ)
|
|
$(VERBOSE)$(STRIP) --strip-debug -o $@ $<
|
|
|
|
$(INSTALL_DIR)/$(CORE_OBJ) : $(CORE_OBJ).stripped
|
|
$(VERBOSE)ln -sf $(CURDIR)/$< $(INSTALL_DIR)/$(CORE_OBJ)
|
|
|
|
$(DEBUG_DIR)/$(CORE_OBJ) : $(CORE_OBJ)
|
|
$(VERBOSE)ln -sf $(CURDIR)/$< $(DEBUG_DIR)/$(CORE_OBJ)
|
|
endif
|
|
endif
|
|
|
|
.PHONY: $(CORE_OBJ)
|
|
$(CORE_OBJ):
|
|
$(VERBOSE)$(LD) $(LD_MARCH) -u _start --whole-archive -r $(LINK_ITEMS) $(LIBCXX_GCC) -o $@
|
|
|
|
clean cleanall:
|
|
$(VERBOSE)rm -f $(CORE_OBJ) $(CORE_OBJ).stripped
|