summaryrefslogtreecommitdiff
path: root/kernel/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/Makefile')
-rw-r--r--kernel/Makefile13
1 files changed, 3 insertions, 10 deletions
diff --git a/kernel/Makefile b/kernel/Makefile
index 6cf8ae4..c6cf24e 100644
--- a/kernel/Makefile
+++ b/kernel/Makefile
@@ -1,11 +1,11 @@
-TARGET = kernel
+TARGET = kernel.o
SRCS = $(wildcard *.c)
ASMS = $(wildcard *.s)
-OBJS = $(SRCS:.c=.o) $(ASMS:.s=.o) usrbin/usrbin_blob.o
+OBJS = $(SRCS:.c=.o) $(ASMS:.s=.o)
CFLAGS = -m32 -I../include -ffreestanding -nostdinc -nostdlib -fno-stack-protector -fno-pie -gstabs+
-LDFLAGS = -m elf_i386 -T link.ld
+LDFLAGS = -m elf_i386 -r
ASMFLAGS = -f elf32
CC = gcc $(CFLAGS)
@@ -16,9 +16,6 @@ all: build
build: $(TARGET)
-usrbin/usrbin_blob.o: $(wildcard usrbin/*.s) $(wildcard usrbin/*.c)
- $(MAKE) -C usrbin
-
.s.o:
$(ASM) -o $*.o $^
@@ -31,7 +28,3 @@ $(TARGET): $(OBJS)
clean:
rm -f $(OBJS)
rm -f $(TARGET)
- $(MAKE) -C usrbin clean
-
-run: $(TARGET)
- qemu-system-x86_64 -s -kernel $(TARGET)