diff options
author | Danny Holman <dholman@gymli.org> | 2025-10-15 19:47:38 -0500 |
---|---|---|
committer | Danny Holman <dholman@gymli.org> | 2025-10-15 19:47:38 -0500 |
commit | b3c8f16a7d83c792d87044d0650ddc73910cec7d (patch) | |
tree | 0f98bb64ad3001157de4cea47c7e6237f72ba712 /bootstrap/stage1/Makefile | |
parent | bootstrap: update build configs (diff) | |
download | box-b3c8f16a7d83c792d87044d0650ddc73910cec7d.tar.gz box-b3c8f16a7d83c792d87044d0650ddc73910cec7d.tar.zst box-b3c8f16a7d83c792d87044d0650ddc73910cec7d.zip |
bootstrap: stage1: update build configuration
Update the build configuration in the first stage of the bootloader.
The new build files should take advantage of the modular makefile
configs in the project root or override them.
Signed-off-by: Danny Holman <dholman@gymli.org>
Diffstat (limited to 'bootstrap/stage1/Makefile')
-rw-r--r-- | bootstrap/stage1/Makefile | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/bootstrap/stage1/Makefile b/bootstrap/stage1/Makefile index 7c3bf81..b80a16b 100644 --- a/bootstrap/stage1/Makefile +++ b/bootstrap/stage1/Makefile @@ -17,7 +17,12 @@ include $(ROOTDIR)/common.mk -INCLUDE+=-I$(ARCHDIR)/include -Iinclude -I$(ROOTDIR)kernel/include -I$(ROOTDIR)kernel/arch/$(ARCH)/include +ifeq ($(BS_DEBUG),YES) + AFLAGS+=-g + CFLAGS+=-g +endif + +INCLUDE+=-I$(ARCHDIR)/include -Iinclude CFLAGS+=-ffreestanding -fno-stack-protector $(BS_OPLVL) BINARY=bootstrap-stage1 @@ -28,9 +33,6 @@ include $(FIRMWARE_DIR)/make.conf COMMON_DIR=firmware/common COMMON_OBJS=$(COMMON_DIR)/bprintf.o \ - $(COMMON_DIR)/elf_load.o \ - $(COMMON_DIR)/exception.o \ - $(COMMON_DIR)/rescue.o \ $(COMMON_DIR)/string.o \ OBJS=$(ARCH_OBJS) \ @@ -49,9 +51,10 @@ $(BINARY): $(OBJS) @echo [CC] $@ %.o: %.s + @$(info $(AFLAGS)) @$(CC) -c $< -o $@ $(AFLAGS) $(INCLUDE) clean: - $(RM) $(BINARY) $(OBJS) $(OBJS:.o=.d) + $(RM) $(BINARY) $(OBJS) $(OBJS:.o=.d) $(OBJS:.o=.dwo) $(BINARY:=.dwp) -include $(OBJS:.o=.d) |