2009-06-29 17:37:40 +04:00
|
|
|
all: build-all
|
2009-07-31 16:18:32 +04:00
|
|
|
# Dummy command so that make thinks it has done something
|
|
|
|
@true
|
2009-06-29 17:37:40 +04:00
|
|
|
|
|
|
|
include ../../config-host.mak
|
2009-07-27 23:59:36 +04:00
|
|
|
include $(SRC_PATH)/rules.mak
|
2009-06-29 17:37:40 +04:00
|
|
|
|
2009-12-21 12:06:55 +03:00
|
|
|
$(call set-vpath, $(SRC_PATH)/pc-bios/optionrom)
|
|
|
|
|
2009-10-06 23:11:13 +04:00
|
|
|
.PHONY : all clean build-all
|
2009-06-29 17:37:40 +04:00
|
|
|
|
2009-09-11 20:45:40 +04:00
|
|
|
CFLAGS := -Wall -Wstrict-prototypes -Werror -fomit-frame-pointer -fno-builtin
|
2009-08-03 16:46:21 +04:00
|
|
|
CFLAGS += -I$(SRC_PATH)
|
2009-09-11 20:45:40 +04:00
|
|
|
CFLAGS += $(call cc-option, $(CFLAGS), -fno-stack-protector)
|
2013-12-11 04:49:08 +04:00
|
|
|
CFLAGS += $(CFLAGS_NOPIE)
|
2009-08-31 02:48:46 +04:00
|
|
|
QEMU_CFLAGS = $(CFLAGS)
|
2009-06-29 17:37:40 +04:00
|
|
|
|
2012-02-17 21:31:18 +04:00
|
|
|
build-all: multiboot.bin linuxboot.bin kvmvapic.bin
|
2009-06-29 17:37:40 +04:00
|
|
|
|
2012-01-30 14:27:33 +04:00
|
|
|
# suppress auto-removal of intermediate files
|
|
|
|
.SECONDARY:
|
|
|
|
|
2009-06-29 17:37:40 +04:00
|
|
|
%.img: %.o
|
2013-12-11 04:49:08 +04:00
|
|
|
$(call quiet-command,$(LD) $(LDFLAGS_NOPIE) -Ttext 0 -e _start -s -o $@ $<," Building $(TARGET_DIR)$@")
|
2009-06-29 17:37:40 +04:00
|
|
|
|
2009-07-11 17:48:29 +04:00
|
|
|
%.raw: %.img
|
2009-07-21 16:11:19 +04:00
|
|
|
$(call quiet-command,$(OBJCOPY) -O binary -j .text $< $@," Building $(TARGET_DIR)$@")
|
2009-07-11 17:48:29 +04:00
|
|
|
|
|
|
|
%.bin: %.raw
|
2012-01-27 22:44:53 +04:00
|
|
|
$(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/signrom.py $< $@," Signing $(TARGET_DIR)$@")
|
2009-06-29 17:37:40 +04:00
|
|
|
|
|
|
|
clean:
|
2009-10-06 23:11:11 +04:00
|
|
|
rm -f *.o *.d *.raw *.img *.bin *~
|