From 4bce609d2a0145e70f44227636a68348e9b23cf9 Mon Sep 17 00:00:00 2001 From: Tianhao Wang Date: Tue, 4 Jun 2024 17:50:10 +0200 Subject: mm: fully map the kernel to high memory --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index a3236c0..3fbe202 100644 --- a/Makefile +++ b/Makefile @@ -19,9 +19,10 @@ ARCH = x86_64 ASM = nasm ASMOBJFORMAT = elf64 ASMFLAGS = -w-zeroing -LINKER_SCRIPT = ./defs/$(ARCH)-linker.ld +LINKER_SCRIPT = ./defs/$(ARCH)-hm-linker.ld CARGO_XBUILD_TARGET = ./defs/$(ARCH)-rustubs.json CARGO_XBUILD_FLAGS = +RUSTC_FLAGS := -C code-model=large # ---------- No need to edit below this line -------------- # ---------- If you have to, something is wrong ----------- LDFLAGS = -no-warn-rwx-segment -static -e startup @@ -65,7 +66,7 @@ $(BUILD)/_%.o : %.s | $(BUILD) # define this, the linker will have troubles, especially when we use a "no_std" build rust_kernel: check @echo "---BUILDING RUST KERNEL---" - @cargo xbuild --target $(CARGO_XBUILD_TARGET) $(CARGO_XBUILD_FLAGS) + @RUSTFLAGS="$(RUSTC_FLAGS)" cargo xbuild --target $(CARGO_XBUILD_TARGET) $(CARGO_XBUILD_FLAGS) # need nasm # TODO make this arch dependent -- cgit v1.2.3-70-g09d2