com32/lib: clean up unused files
[syslinux/sherbszt.git] / mbr / Makefile
blobbe2bded7bd8640b64d09d090b6b9e2276d772fbc
1 ## -----------------------------------------------------------------------
2 ##
3 ## Copyright 2007-2009 H. Peter Anvin - All Rights Reserved
4 ## Copyright 2009 Intel Corporation; author: H. Peter Anvin
5 ##
6 ## This program is free software; you can redistribute it and/or modify
7 ## it under the terms of the GNU General Public License as published by
8 ## the Free Software Foundation, Inc., 53 Temple Place Ste 330,
9 ## Boston MA 02111-1307, USA; either version 2 of the License, or
10 ## (at your option) any later version; incorporated herein by reference.
12 ## -----------------------------------------------------------------------
15 # Makefile for MBR
18 VPATH = $(SRC)
20 include $(MAKEDIR)/embedded.mk
22 all: mbr.bin altmbr.bin gptmbr.bin isohdpfx.bin isohdppx.bin \
23 mbr_c.bin altmbr_c.bin gptmbr_c.bin isohdpfx_c.bin isohdppx_c.bin \
24 mbr_f.bin altmbr_f.bin gptmbr_f.bin isohdpfx_f.bin isohdppx_f.bin
26 %.o: %.S
27 $(CC) $(MAKEDEPS) $(SFLAGS) -Wa,-a=$*.lst -c -o $@ $<
29 %_c.o: %.S
30 $(CC) $(MAKEDEPS) $(SFLAGS) -Wa,-a=$*_c.lst -DCTRL_80 -c -o $@ $<
32 %_f.o: %.S
33 $(CC) $(MAKEDEPS) $(SFLAGS) -Wa,-a=$*_f.lst -DFORCE_80 -c -o $@ $<
35 .PRECIOUS: %.elf
36 #%.elf: %.o mbr.ld
37 %.elf: %.o $(SRC)/$(ARCH)/mbr.ld
38 $(LD) $(LDFLAGS) -T $(SRC)/$(ARCH)/mbr.ld -e _start -o $@ $<
40 %.bin: %.elf $(SRC)/checksize.pl
41 $(OBJCOPY) -O binary $< $@
42 $(PERL) $(SRC)/checksize.pl $@
43 $(CHMOD) -x $@
45 mbr_bin.c: mbr.bin
47 install:
49 tidy dist:
50 rm -f *.o *.elf *.lst .*.d
52 clean: tidy
54 spotless: clean
55 rm -f *.bin
57 -include .*.d