mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-19 08:36:49 +00:00
kernel: differentiate board-specific components
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
This commit is contained in:
parent
c43267dbaa
commit
a1e70b9ba4
@ -1,4 +1,5 @@
|
||||
FOC_BUILD_DIR = $(shell pwd)/build
|
||||
BOARD ?= unknown
|
||||
FOC_BUILD_DIR = $(shell pwd)/$(BOARD)-build
|
||||
FOC = $(FOC_BUILD_DIR)/foc
|
||||
FOC_SRC := $(call select_from_ports,foc)/src/kernel/foc/kernel/fiasco
|
||||
|
||||
@ -41,7 +42,7 @@ PKGS := l4re-core/crtn \
|
||||
drivers-frst/include drivers-frst/of drivers-frst/uart \
|
||||
bootstrap
|
||||
|
||||
L4_BUILD_DIR := $(LIB_CACHE_DIR)/syscall-foc/build
|
||||
L4_BUILD_DIR := $(LIB_CACHE_DIR)/syscall-foc/$(BOARD)-build
|
||||
|
||||
#
|
||||
# Supress several warnings especially of the uclibc-minimal
|
||||
|
@ -30,7 +30,7 @@ endif
|
||||
|
||||
L4_BUILD_OPT = CROSS_COMPILE=$(CROSS_DEV_PREFIX)
|
||||
L4_PKG_DIR := $(call select_from_ports,foc)/src/kernel/foc/l4/pkg
|
||||
PKG_TAGS = $(addsuffix .tag,$(PKGS))
|
||||
PKG_TAGS = $(addsuffix .tag,$(addsuffix .$(BOARD),$(PKGS)))
|
||||
|
||||
BUILD_OUTPUT_FILTER = 2>&1 | sed "s~^~ [$*] ~"
|
||||
|
||||
@ -49,7 +49,7 @@ endif
|
||||
#
|
||||
.NOTPARALLEL: $(PKG_TAGS)
|
||||
|
||||
%.tag:
|
||||
%.$(BOARD).tag:
|
||||
$(VERBOSE_MK) set -o pipefail; \
|
||||
$(MAKE) $(VERBOSE_DIR) O=$(L4_BUILD_DIR) -C $(L4_PKG_DIR)/$* \
|
||||
"$(L4_BUILD_OPT)" WARNINGS=$(WARNINGS) $(BUILD_OUTPUT_FILTER)
|
||||
|
@ -1,5 +1,5 @@
|
||||
L4_CONFIG := $(call select_from_repositories,config/arndale.user)
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/arm_armv7a
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/arndale-build/bin/arm_armv7a
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/arm/syscall-foc.inc
|
||||
|
@ -1,5 +1,5 @@
|
||||
L4_CONFIG := $(call select_from_repositories,config/imx6q_sabrelite.user)
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/arm_armv7a
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/imx6q_sabrelite-build/bin/arm_armv7a
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/arm/syscall-foc.inc
|
||||
|
@ -1,5 +1,5 @@
|
||||
L4_CONFIG := $(call select_from_repositories,config/imx7.user)
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/arm_armv7a
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/imx7d_sabre-build/bin/arm_armv7a
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/arm/syscall-foc.inc
|
||||
|
@ -1,5 +1,5 @@
|
||||
L4_CONFIG := $(call select_from_repositories,config/odroid_x2.user)
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/arm_armv7a
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/odroid_x2-build/bin/arm_armv7a
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/arm/syscall-foc.inc
|
||||
|
@ -1,5 +1,5 @@
|
||||
L4_CONFIG := $(call select_from_repositories,config/panda.user)
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/arm_armv7a
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/panda-build/bin/arm_armv7a
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/arm/syscall-foc.inc
|
||||
|
@ -1,5 +1,5 @@
|
||||
L4_CONFIG := $(call select_from_repositories,config/pbxa9.user)
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/arm_armv7a
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/pbxa9-build/bin/arm_armv7a
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/arm/syscall-foc.inc
|
||||
|
@ -1,5 +1,5 @@
|
||||
L4_CONFIG := $(call select_from_repositories,config/rpi.user)
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/arm_armv6
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/rpi-build/bin/arm_armv6
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/arm/syscall-foc.inc
|
||||
|
@ -4,7 +4,7 @@ L4_INC_TARGETS := x86/l4/sys x86/l4f/l4/sys x86/l4/vcpu
|
||||
|
||||
CC_OPT += -Iinclude/x86
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/x86_586
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/pc-build/bin/x86_586
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/x86/syscall-foc.inc
|
||||
|
||||
|
@ -4,6 +4,6 @@ L4_INC_TARGETS := amd64/l4/sys amd64/l4f/l4/sys amd64/l4/vcpu
|
||||
|
||||
CC_OPT += -Iinclude/amd64
|
||||
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/build/bin/amd64_K8
|
||||
L4_BIN_DIR := $(LIB_CACHE_DIR)/syscall-foc/pc-build/bin/amd64_K8
|
||||
|
||||
include $(REP_DIR)/lib/mk/spec/x86/syscall-foc.inc
|
||||
|
@ -6,8 +6,9 @@
|
||||
# userland (L4re) that comes with Fiasco.OC.
|
||||
#
|
||||
|
||||
BOARD ?= unknown
|
||||
L4_SRC_DIR := $(call select_from_ports,foc)/src/kernel/foc
|
||||
L4_BUILD_DIR := $(shell pwd)/build
|
||||
L4_BUILD_DIR := $(shell pwd)/$(BOARD)-build
|
||||
|
||||
#
|
||||
# Create mirror for architecture-specific L4sys header files
|
||||
@ -67,14 +68,14 @@ $(SRC_S) $(SRC_C) : $(PKG_TAGS)
|
||||
# included in the depot's base-foc binary archives.
|
||||
#
|
||||
ifneq ($(INSTALL_DIR),)
|
||||
all: $(INSTALL_DIR)/sigma0-foc $(INSTALL_DIR)/bootstrap-foc
|
||||
all: $(INSTALL_DIR)/sigma0-foc-$(BOARD) $(INSTALL_DIR)/bootstrap-foc-$(BOARD)
|
||||
|
||||
$(INSTALL_DIR)/sigma0-foc $(INSTALL_DIR)/bootstrap-foc: $(PKG_TAGS)
|
||||
$(INSTALL_DIR)/sigma0-foc-$(BOARD) $(INSTALL_DIR)/bootstrap-foc-$(BOARD): $(PKG_TAGS)
|
||||
|
||||
$(INSTALL_DIR)/sigma0-foc:
|
||||
$(INSTALL_DIR)/sigma0-foc-$(BOARD):
|
||||
$(VERBOSE)ln -sf $(L4_BIN_DIR)/l4f/sigma0 $@
|
||||
|
||||
$(INSTALL_DIR)/bootstrap-foc:
|
||||
$(INSTALL_DIR)/bootstrap-foc-$(BOARD):
|
||||
$(VERBOSE)ln -sf $(L4_BIN_DIR)/bootstrap $@
|
||||
endif
|
||||
|
||||
|
@ -1,7 +1,3 @@
|
||||
RECIPE_DIR := $(REP_DIR)/recipes/src/base-foc-arndale
|
||||
BOARD := arndale
|
||||
|
||||
include $(GENODE_DIR)/repos/base-foc/recipes/src/base-foc_content.inc
|
||||
|
||||
content: enable_board_spec
|
||||
enable_board_spec: etc/specs.conf
|
||||
echo "SPECS += arndale" >> etc/specs.conf
|
||||
|
@ -1,7 +1,3 @@
|
||||
RECIPE_DIR := $(REP_DIR)/recipes/src/base-foc-imx6q_sabrelite
|
||||
BOARD := imx6q_sabrelite
|
||||
|
||||
include $(GENODE_DIR)/repos/base-foc/recipes/src/base-foc_content.inc
|
||||
|
||||
content: enable_board_spec
|
||||
enable_board_spec: etc/specs.conf
|
||||
echo "SPECS += imx6q_sabrelite" >> etc/specs.conf
|
||||
|
@ -1,7 +1,3 @@
|
||||
RECIPE_DIR := $(REP_DIR)/recipes/src/base-foc-imx7d_sabre
|
||||
BOARD := imx7d_sabre
|
||||
|
||||
include $(GENODE_DIR)/repos/base-foc/recipes/src/base-foc_content.inc
|
||||
|
||||
content: enable_board_spec
|
||||
enable_board_spec: etc/specs.conf
|
||||
echo "SPECS += imx7d_sabre" >> etc/specs.conf
|
||||
|
@ -1,7 +1,3 @@
|
||||
RECIPE_DIR := $(REP_DIR)/recipes/src/base-foc-pbxa9
|
||||
BOARD := pbxa9
|
||||
|
||||
include $(GENODE_DIR)/repos/base-foc/recipes/src/base-foc_content.inc
|
||||
|
||||
content: enable_board_spec
|
||||
enable_board_spec: etc/specs.conf
|
||||
echo "SPECS += pbxa9" >> etc/specs.conf
|
||||
|
@ -1,3 +1,3 @@
|
||||
RECIPE_DIR := $(REP_DIR)/recipes/src/base-foc-pc
|
||||
BOARD := pc
|
||||
|
||||
include $(GENODE_DIR)/repos/base-foc/recipes/src/base-foc_content.inc
|
||||
|
@ -1,5 +1,6 @@
|
||||
include $(GENODE_DIR)/repos/base/recipes/src/base_content.inc
|
||||
|
||||
RECIPE_DIR := $(REP_DIR)/recipes/src/base-foc-$(BOARD)
|
||||
FROM_BASE_FOC := include/foc include/foc_native_cpu
|
||||
|
||||
content: $(FROM_BASE_FOC)
|
||||
@ -30,4 +31,11 @@ content:
|
||||
done;
|
||||
sed -i "s/ld-foc/ld/" src/lib/ld/foc/target.mk
|
||||
sed -i "s/foc_timer_drv/timer/" src/timer/foc/target.mk
|
||||
sed -i "s/BOARD.*unknown/BOARD = $(BOARD)/" src/core/foc/target.mk
|
||||
sed -i "s/BOARD.*unknown/BOARD = $(BOARD)/" src/kernel/foc/target.mk
|
||||
sed -i "s/BOARD.*unknown/BOARD = $(BOARD)/" lib/mk/syscall-foc.inc
|
||||
sed -i "s/BOARD.*unknown/BOARD = $(BOARD)/" lib/mk/kernel-foc.inc
|
||||
|
||||
content: enable_board_spec
|
||||
enable_board_spec: etc/specs.conf
|
||||
echo "SPECS += $(BOARD)" >> etc/specs.conf
|
||||
|
@ -1,4 +1,6 @@
|
||||
BOARD ?= unknown
|
||||
TARGET := foc-$(BOARD)
|
||||
LIBS := core-foc
|
||||
CORE_OBJ := core-foc.o
|
||||
CORE_OBJ := core-foc-$(BOARD).o
|
||||
|
||||
include $(BASE_DIR)/src/core/target.inc
|
||||
|
@ -1,7 +1,8 @@
|
||||
BOARD ?= unknown
|
||||
TARGET = kernel-foc
|
||||
LIBS = kernel-foc
|
||||
|
||||
$(TARGET): $(INSTALL_DIR)/foc
|
||||
$(TARGET): $(INSTALL_DIR)/foc-$(BOARD)
|
||||
|
||||
$(INSTALL_DIR)/foc: $(LIB_CACHE_DIR)/kernel-foc/build/fiasco
|
||||
$(INSTALL_DIR)/foc-$(BOARD): $(LIB_CACHE_DIR)/kernel-foc/$(BOARD)-build/fiasco
|
||||
$(VERBOSE)ln -sf $< $@
|
||||
|
@ -4,7 +4,7 @@ ifeq ($(filter-out $(SPECS),x86_64),)
|
||||
SPECS += pci ps2 vesa framebuffer
|
||||
|
||||
ifneq ($(filter-out $(SPECS),muen),)
|
||||
SPECS += acpi x86_pc
|
||||
SPECS += acpi
|
||||
endif
|
||||
endif
|
||||
|
||||
|
@ -8,10 +8,4 @@ SRC_CC += bootstrap/spec/arm/imx_tzic.cc
|
||||
SRC_CC += bootstrap/spec/arm/arm_v7_cpu.cc
|
||||
SRC_CC += hw/spec/32bit/memory_map.cc
|
||||
|
||||
ifneq ($(filter-out $(SPECS),trustzone),)
|
||||
SRC_CC += bootstrap/spec/imx53_qsb/platform.cc
|
||||
else
|
||||
SRC_CC += bootstrap/spec/imx53_qsb/platform_trustzone.cc
|
||||
endif
|
||||
|
||||
include $(BASE_DIR)/../base-hw/lib/mk/bootstrap-hw.inc
|
@ -0,0 +1,3 @@
|
||||
SRC_CC += bootstrap/spec/imx53_qsb/platform.cc
|
||||
|
||||
include $(BASE_DIR)/../base-hw/lib/mk/spec/arm_v7/bootstrap-hw-imx53_qsb.inc
|
@ -0,0 +1,3 @@
|
||||
SRC_CC += bootstrap/spec/imx53_qsb/platform_trustzone.cc
|
||||
|
||||
include $(BASE_DIR)/../base-hw/lib/mk/spec/arm_v7/bootstrap-hw-imx53_qsb.inc
|
17
repos/base-hw/lib/mk/spec/arm_v7/core-hw-imx53_qsb.inc
Normal file
17
repos/base-hw/lib/mk/spec/arm_v7/core-hw-imx53_qsb.inc
Normal file
@ -0,0 +1,17 @@
|
||||
#
|
||||
# \brief Build config for Genodes core process
|
||||
# \author Stefan Kalkowski
|
||||
# \author Martin Stein
|
||||
# \date 2012-10-24
|
||||
#
|
||||
|
||||
# add include paths
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/imx53_qsb
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/imx53
|
||||
|
||||
SRC_CC += spec/imx53/pic.cc
|
||||
SRC_CC += spec/imx53/timer.cc
|
||||
|
||||
# include less specific configuration
|
||||
include $(REP_DIR)/lib/mk/spec/cortex_a8/core-hw.inc
|
||||
|
5
repos/base-hw/lib/mk/spec/arm_v7/core-hw-imx53_qsb.mk
Normal file
5
repos/base-hw/lib/mk/spec/arm_v7/core-hw-imx53_qsb.mk
Normal file
@ -0,0 +1,5 @@
|
||||
SRC_CC += kernel/vm_thread_off.cc
|
||||
SRC_CC += platform_services.cc
|
||||
|
||||
# include less specific configuration
|
||||
include $(REP_DIR)/lib/mk/spec/arm_v7/core-hw-imx53_qsb.inc
|
14
repos/base-hw/lib/mk/spec/arm_v7/core-hw-imx53_qsb_tz.mk
Normal file
14
repos/base-hw/lib/mk/spec/arm_v7/core-hw-imx53_qsb_tz.mk
Normal file
@ -0,0 +1,14 @@
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/arm_v7/trustzone
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/imx53/trustzone
|
||||
|
||||
SRC_CC += spec/imx53/trustzone/platform_services.cc
|
||||
SRC_CC += kernel/vm_thread_on.cc
|
||||
SRC_CC += spec/arm_v7/trustzone/kernel/vm.cc
|
||||
SRC_CC += spec/arm_v7/vm_session_component.cc
|
||||
SRC_CC += spec/arm_v7/trustzone/vm_session_component.cc
|
||||
|
||||
SRC_S += spec/arm_v7/trustzone/exception_vector.s
|
||||
|
||||
# include less specific configuration
|
||||
include $(REP_DIR)/lib/mk/spec/arm_v7/core-hw-imx53_qsb.inc
|
||||
|
@ -1,32 +0,0 @@
|
||||
#
|
||||
# \brief Build config for Genodes core process
|
||||
# \author Stefan Kalkowski
|
||||
# \author Martin Stein
|
||||
# \date 2012-10-24
|
||||
#
|
||||
|
||||
# add include paths
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/imx53_qsb
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/imx53
|
||||
|
||||
SRC_CC += spec/imx53/pic.cc
|
||||
SRC_CC += spec/imx53/timer.cc
|
||||
|
||||
ifneq ($(filter-out $(SPECS),trustzone),)
|
||||
SRC_CC += kernel/vm_thread_off.cc
|
||||
SRC_CC += platform_services.cc
|
||||
else
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/arm_v7/trustzone
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/imx53/trustzone
|
||||
|
||||
SRC_CC += spec/imx53/trustzone/platform_services.cc
|
||||
SRC_CC += kernel/vm_thread_on.cc
|
||||
SRC_CC += spec/arm_v7/trustzone/kernel/vm.cc
|
||||
SRC_CC += spec/arm_v7/vm_session_component.cc
|
||||
SRC_CC += spec/arm_v7/trustzone/vm_session_component.cc
|
||||
|
||||
SRC_S += spec/arm_v7/trustzone/exception_vector.s
|
||||
endif
|
||||
|
||||
# include less specific configuration
|
||||
include $(REP_DIR)/lib/mk/spec/cortex_a8/core-hw.inc
|
@ -1,6 +1,7 @@
|
||||
TARGET = bootstrap
|
||||
LIBS = bootstrap-hw
|
||||
BOOTSTRAP_OBJ = bootstrap-hw.o
|
||||
BOARD ?= unknown
|
||||
TARGET = bootstrap_hw_$(BOARD)
|
||||
LIBS = bootstrap-hw-$(BOARD)
|
||||
BOOTSTRAP_OBJ = bootstrap-hw-$(BOARD).o
|
||||
|
||||
$(TARGET):
|
||||
$(VERBOSE)true
|
||||
|
@ -1,4 +1,6 @@
|
||||
LIBS := core-hw
|
||||
CORE_OBJ := core-hw.o
|
||||
BOARD ?= unknown
|
||||
TARGET := core_hw_$(BOARD)
|
||||
LIBS := core-hw-$(BOARD)
|
||||
CORE_OBJ := core-hw-$(BOARD).o
|
||||
|
||||
include $(BASE_DIR)/src/core/target.inc
|
||||
|
@ -1,13 +0,0 @@
|
||||
GEN_SRC_CC = platform_services.cc
|
||||
|
||||
REP_SRC_CC = \
|
||||
spec/arm/boot_info.cc \
|
||||
spec/arm/irq.cc \
|
||||
spec/arm/platform.cc \
|
||||
spec/arm/platform_thread.cc \
|
||||
spec/arm/thread.cc \
|
||||
spec/arm/vm_space.cc
|
||||
|
||||
INC_DIR += $(REP_DIR)/src/core/spec/arm
|
||||
|
||||
include $(REP_DIR)/lib/mk/core-sel4.inc
|
@ -1,5 +1,6 @@
|
||||
TARGET = sel4
|
||||
LIBS = kernel-sel4
|
||||
BOARD ?= unknown
|
||||
TARGET = sel4-$(BOARD)
|
||||
LIBS = kernel-sel4-$(BOARD)
|
||||
|
||||
$(INSTALL_DIR)/$(TARGET):
|
||||
$(VERBOSE)ln -sf $(LIB_CACHE_DIR)/kernel-sel4/kernel.elf.strip $@
|
||||
$(VERBOSE)ln -sf $(LIB_CACHE_DIR)/kernel-sel4-$(BOARD)/kernel.elf.strip $@
|
||||
|
@ -1,4 +1,4 @@
|
||||
TARGET = core
|
||||
TARGET ?= core
|
||||
CORE_OBJ ?= core.o
|
||||
|
||||
$(TARGET):
|
||||
|
@ -324,6 +324,7 @@ run/%: $(call select_from_repositories,run/%.run) $(RUN_ENV)
|
||||
$(VERBOSE)$(GENODE_DIR)/tool/run/run --genode-dir $(GENODE_DIR) \
|
||||
--name $* \
|
||||
--specs "$(SPECS)" \
|
||||
--board "$(BOARD)" \
|
||||
--repositories "$(REPOSITORIES)" \
|
||||
--cross-dev-prefix "$(CROSS_DEV_PREFIX)" \
|
||||
--qemu-args "$(QEMU_OPT)" \
|
||||
|
@ -1,5 +1,5 @@
|
||||
proc binary_name_ld_lib_so { } { return "ld-foc.lib.so" }
|
||||
proc binary_name_core_o { } { return "core-foc.o" }
|
||||
proc binary_name_core_o { } { return "core-foc-[board].o" }
|
||||
proc binary_name_timer { } { return "foc_timer_drv" }
|
||||
|
||||
proc kernel_files { } { return { foc sigma0-foc bootstrap-foc } }
|
||||
@ -39,10 +39,10 @@ proc reset_target { {spawn_id_arg -1} } {
|
||||
}
|
||||
|
||||
|
||||
proc l4_build_dir { } { return "[pwd]/var/libcache/syscall-foc/build" }
|
||||
proc l4_build_dir { } { return "[pwd]/var/libcache/syscall-foc/[board]-build" }
|
||||
|
||||
|
||||
proc kernel_binary { } { return "[pwd]/bin/foc" }
|
||||
proc kernel_binary { } { return "[pwd]/bin/foc-[board]" }
|
||||
|
||||
|
||||
proc l4_bin_dir { } {
|
||||
@ -72,9 +72,9 @@ proc run_boot_dir_x86 {binaries} {
|
||||
if {[llength $targets]} { build $targets }
|
||||
|
||||
if {$kernel_arg != ""} {
|
||||
file copy -force [pwd]/bin/foc [run_dir]/genode/foc
|
||||
file copy -force [pwd]/bin/sigma0-foc [run_dir]/genode/sigma0-foc
|
||||
file copy -force [pwd]/bin/bootstrap-foc [run_dir]/genode/bootstrap-foc
|
||||
file copy -force [pwd]/bin/foc-[board] [run_dir]/genode/foc
|
||||
file copy -force [pwd]/bin/sigma0-foc-[board] [run_dir]/genode/sigma0-foc
|
||||
file copy -force [pwd]/bin/bootstrap-foc-[board] [run_dir]/genode/bootstrap-foc
|
||||
}
|
||||
|
||||
build_core_image $binaries
|
||||
|
@ -61,8 +61,8 @@ proc run_boot_dir {binaries} {
|
||||
if {[llength $build_args]} { build $build_args }
|
||||
|
||||
if {$ld_arg != ""} { file copy -force bin/ld-hw.lib.so [run_dir]/genode/ld.lib.so }
|
||||
if {$core_arg != ""} { file copy -force bin/core-hw.o [run_dir]/genode/core-hw.o }
|
||||
if {$bootstrap_arg != ""} { file copy -force bin/bootstrap-hw.o [run_dir]/genode/bootstrap-hw.o }
|
||||
if {$core_arg != ""} { file copy -force bin/core-hw-[board].o [run_dir]/genode/core-hw.o }
|
||||
if {$bootstrap_arg != ""} { file copy -force bin/bootstrap-hw-[board].o [run_dir]/genode/bootstrap-hw.o }
|
||||
|
||||
#
|
||||
# Copy specified modules to the run directory, excluding core.
|
||||
@ -77,8 +77,8 @@ proc run_boot_dir {binaries} {
|
||||
set bootstrap_obj bootstrap-hw.o
|
||||
|
||||
# create core and bootstrap binary without modules for debugging
|
||||
if {[file exists debug/$core_obj]} {
|
||||
build_core debug/$core_obj {} [run_dir].core [core_link_address]
|
||||
if {[file exists debug/core-hw-[board].o]} {
|
||||
build_core debug/core-hw-[board].o {} [run_dir].core [core_link_address]
|
||||
build_core [run_dir]/genode/$bootstrap_obj {} [run_dir].bootstrap [bootstrap_link_address]
|
||||
}
|
||||
|
||||
|
@ -15,10 +15,10 @@ proc run_boot_string { } { return "\n\rBooting all finished, dropped to user s
|
||||
proc core_link_address { } { return "0x02000000" }
|
||||
|
||||
proc sel4_elfloader_dir { } {
|
||||
if {![file exists [pwd]/var/libcache/kernel-sel4/elfloader]} {
|
||||
build LIB=kernel-sel4
|
||||
if {![file exists [pwd]/var/libcache/kernel-sel4-[board]/elfloader]} {
|
||||
build LIB=kernel-sel4-[board]
|
||||
}
|
||||
return "[pwd]/var/libcache/kernel-sel4/elfloader"
|
||||
return "[pwd]/var/libcache/kernel-sel4-[board]/elfloader"
|
||||
}
|
||||
|
||||
##
|
||||
@ -39,7 +39,7 @@ proc run_boot_dir {binaries} {
|
||||
if {[llength $targets]} { build $targets }
|
||||
|
||||
if {$kernel_arg != ""} {
|
||||
file copy -force [pwd]/bin/sel4 [run_dir]/genode/sel4
|
||||
file copy -force [pwd]/bin/sel4-[board] [run_dir]/genode/sel4
|
||||
}
|
||||
|
||||
build_core_image $binaries
|
||||
|
14
tool/run/run
14
tool/run/run
@ -499,6 +499,7 @@ set run_name [get_cmd_arg --name "noname"]
|
||||
set genode_dir [get_cmd_arg --genode-dir ""]
|
||||
set cross_dev_prefix [get_cmd_arg --cross-dev-prefix ""]
|
||||
set specs [get_cmd_arg --specs ""]
|
||||
set board_var [get_cmd_arg --board ""]
|
||||
set repositories [get_cmd_arg --repositories ""]
|
||||
|
||||
|
||||
@ -815,6 +816,19 @@ proc terminal { } {
|
||||
}
|
||||
|
||||
|
||||
##
|
||||
# Return the board to build for
|
||||
#
|
||||
proc board { } {
|
||||
global board_var
|
||||
if {$board_var eq ""} {
|
||||
puts "Unknown platform no BOARD variable set"
|
||||
exit 0
|
||||
}
|
||||
return $board_var
|
||||
}
|
||||
|
||||
|
||||
##
|
||||
# Determine GDB executable installed at the host
|
||||
#
|
||||
|
Loading…
x
Reference in New Issue
Block a user