2 CCFLAGS=-m32 -Wall -Wextra -Werror -fno-stack-protector -nostdinc -fno-builtin
6 LDFLAGS=-melf_i386 -T link.ld
7 LIBS=$(shell $(CC) $(CCFLAGS) -print-libgcc-file-name)
9 all: mmap.elf modules.elf
11 mmap.elf: start.o mmap.o libc.o
12 $(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
14 modules.elf: start.o modules.o libc.o
15 $(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
18 $(CC) $(CCFLAGS) -c -o $@ $^
21 $(CC) $(ASFLAGS) -c -o $@ $^