summaryrefslogtreecommitdiffstats
path: root/src/build/mkrules
diff options
context:
space:
mode:
Diffstat (limited to 'src/build/mkrules')
-rw-r--r--src/build/mkrules/cflags.env.mk5
-rw-r--r--src/build/mkrules/dist.targets.mk1
-rwxr-xr-xsrc/build/mkrules/hbfw/img/makefile5
-rw-r--r--src/build/mkrules/images.rules.mk10
4 files changed, 16 insertions, 5 deletions
diff --git a/src/build/mkrules/cflags.env.mk b/src/build/mkrules/cflags.env.mk
index 1ab9b9a30..106dc408b 100644
--- a/src/build/mkrules/cflags.env.mk
+++ b/src/build/mkrules/cflags.env.mk
@@ -44,3 +44,8 @@ INCFLAGS = $(addprefix -I, $(INCDIR) )
ASMINCFLAGS = $(addprefix $(lastword -Wa,-I), $(INCDIR))
FLAGS_FILTER ?= $(1)
+
+ifdef HOSTBOOT_RUNTIME
+CFLAGS += -D__HOSTBOOT_RUNTIME=1
+TRACE_FLAGS += --full-strings
+endif
diff --git a/src/build/mkrules/dist.targets.mk b/src/build/mkrules/dist.targets.mk
index c7afac9ee..b36c92a34 100644
--- a/src/build/mkrules/dist.targets.mk
+++ b/src/build/mkrules/dist.targets.mk
@@ -79,6 +79,7 @@ COPY_RENAME_FILES = \
hbicore.bin:img/hbicore$(UNDERSCORE_TEST).bin:vpo \
img/hostboot.bin:img/hbicore$(UNDERSCORE_TEST).bin:fsp \
img/hostboot_extended.bin:img/hbicore$(UNDERSCORE_TEST)_extended.bin:fsp \
+ img/hostboot_runtime.bin:img/hbirt$(UNDERSCORE_TEST).bin:fsp \
vbu_MURANO.pnor:img/vbu$(UNDERSCORE_TEST)_MURANO.pnor:vpo \
vbu_VENICE.pnor:img/vbu$(UNDERSCORE_TEST)_VENICE.pnor:vpo \
hbicore.syms:img/hbicore$(UNDERSCORE_TEST).syms:tools,vpo \
diff --git a/src/build/mkrules/hbfw/img/makefile b/src/build/mkrules/hbfw/img/makefile
index f56194cab..54d1baa39 100755
--- a/src/build/mkrules/hbfw/img/makefile
+++ b/src/build/mkrules/hbfw/img/makefile
@@ -47,7 +47,8 @@ install_all: build_pnor_images
#################################################
BASE_IMAGE = hostboot.bin
EXT_IMAGE = hostboot_extended.bin
-BASE_IMAGES = ${BASE_IMAGE} ${EXT_IMAGE}
+HBRT_IMAGE = hostboot_runtime.bin
+BASE_IMAGES = ${BASE_IMAGE} ${EXT_IMAGE} ${HBRT_IMAGE}
BASE_W_HEADER_IMAGE = hostboot.header.bin
BASE_W_HEADER_ECC_IMAGE = hostboot.header.bin.ecc
BASE_ECC_IMAGE = hostboot.bin.ecc
@@ -88,7 +89,7 @@ PNOR_BUILD_SCRIPT = ${buildpnor.pl:P}
#so need to use tryinclude for now.
.tryinclude <${.PATH:Ffips_pnor.mk}>
-HOSTBOOT_DEFAULT_SECTIONS = HBB=${BASE_W_HEADER_ECC_IMAGE},HBI=${EXT_IMAGE}
+HOSTBOOT_DEFAULT_SECTIONS = HBB=${BASE_W_HEADER_ECC_IMAGE},HBI=${EXT_IMAGE},HBRT=${HBRT_IMAGE}
HBFW_OBJPATH = ${.PATH:M*obj*}
ENGD_OBJPATH = ${HBFW_OBJPATH:S/hbfw\/img/engd\/href/g}
diff --git a/src/build/mkrules/images.rules.mk b/src/build/mkrules/images.rules.mk
index 190f29be5..3b660925c 100644
--- a/src/build/mkrules/images.rules.mk
+++ b/src/build/mkrules/images.rules.mk
@@ -37,7 +37,7 @@ define ELF_template
$$(IMGDIR)/$(1).elf: $$(addprefix $$(OBJDIR)/, $$($(1)_OBJECTS)) \
$$(ROOTPATH)/src/kernel.ld
$$(C2) " LD $$(notdir $$@)"
- $$(C1)$$(LD) -static $$(LDFLAGS) \
+ $$(C1)$$(LD) -static $$(LDFLAGS) $$($$*_LDFLAGS) \
$$(addprefix $$(OBJDIR)/, $$($(1)_OBJECTS)) \
$$($(1)_LDFLAGS) -T $$(ROOTPATH)/src/kernel.ld -o $$@
endef
@@ -49,8 +49,11 @@ $(IMGDIR)/%.bin: $(IMGDIR)/%.elf \
$(C2) " LINKER $(notdir $@)"
$(C1)set -o pipefail && $(CUSTOM_LINKER) $@ $< \
$(addprefix $(IMGDIR)/lib, $(addsuffix .so, $($*_MODULES))) \
+ $(if $($*_EXTENDED_MODULES), \
--extended=0x40000 $(IMGDIR)/$*_extended.bin \
- $(addprefix $(IMGDIR)/lib, $(addsuffix .so, $($*_EXTENDED_MODULES))) \
+ $(addprefix $(IMGDIR)/lib, \
+ $(addsuffix .so, $($*_EXTENDED_MODULES))) \
+ ) \
$(addprefix $(IMGDIR)/, $($*_DATA_MODULES)) \
| bzip2 -zc > $(IMGDIR)/.$*.lnkout.bz2
$(C1)$(ROOTPATH)/src/build/tools/addimgid $@ $<
@@ -58,7 +61,8 @@ $(IMGDIR)/%.bin: $(IMGDIR)/%.elf \
$(IMGDIR)/%.list.bz2 $(IMGDIR)/%.syms: $(IMGDIR)/%.bin
$(C2) " GENLIST $(notdir $*)"
$(C1)(cd $(ROOTPATH)&& \
- src/build/linker/gensyms $*.bin $*_extended.bin 0x40000000 \
+ src/build/linker/gensyms $*.bin \
+ $(if $($*_EXTENDED_MODULES), $*_extended.bin 0x40000000) \
> ./img/$*.syms && \
src/build/linker/genlist $*.bin | bzip2 -zc > ./img/$*.list.bz2)
OpenPOWER on IntegriCloud