include config.mk .PHONY: all clean distclean emulate install all: $(kernel) clean: @echo " (RM) iso" $(QUIET)$(RM) -r iso @echo " (RM) $(kernel_iso)" $(QUIET)$(RM) $(kernel_iso) @echo " (RM) $(objects)" $(QUIET)$(RM) $(objects) @echo " (RM) $(dependencies)" $(QUIET)$(RM) $(dependencies) emulate: $(kernel_iso) @echo " (QEMU) $^" $(QUIET)$(QEMU) -cdrom $^ distclean: clean @echo " (RM) $(kernel)" $(QUIET)$(RM) $(kernel) install: $(kernel) @echo " (CP) $^" $(QUIET)$(CP) $< $(INSTALL_DIR) %.o: %.c @echo " (CC) $@" $(QUIET)$(CC) -c $(CPPFLAGS) $(CFLAGS) $< -o $@ %.o: %.s @echo " (AS) $@" $(QUIET)$(AS) $(ASFLAGS) $< -o $@ $(kernel): $(memmap) $(objects) @echo " (LD) $@" $(QUIET) $(LD) $(LDFLAGS) -T $< -o $@ $(objects) $(kernel_iso): $(kernel) misc/grub.cfg mkdir -p iso/boot/grub cp $^ iso/boot cp misc/grub.cfg iso/boot/grub grub-mkrescue --output=$@ iso -include $(dependencies)