view cos/kernel/Makefile @ 206:6c6bf8890d8a

Added push and pop encodings
author Windel Bouwman
date Fri, 28 Jun 2013 16:49:38 +0200
parents 5c20bd53cccd
children
line wrap: on
line source

# vim: set noexpandtab:

all: lcfos.bin Makefile

CRT0 = goto64.o

CFLAGS = -g -m64 -nostdinc	-nostdlib -nostartfiles -mno-red-zone \
	-fno-builtin -mcmodel=large -Wall -Wextra -Werror

OBJECTS = video.o snprintf.o kernel.o asmcode.o handlers.o keyboard.o \
			klib.o malloc.o task.o mm.o timer.o fs.o initrd.o multiboot.o \
			shell.o

lcfos.bin: $(CRT0) $(OBJECTS) kernel.ld
	ld -g -T kernel.ld -s --cref -Map=kernel.map -o lcfos.bin $(CRT0) $(OBJECTS)

%.o : %.asm
	nasm -f elf64 -o $@ $<

%.o : %.c kernel.h
	gcc $(CFLAGS) -o $@ -c $<

clean:
	rm $(OBJECTS) $(CRT0) lcfos.bin