OpenCores
URL https://opencores.org/ocsvn/eco32/eco32/trunk

Subversion Repositories eco32

[/] [eco32/] [trunk/] [stdalone/] [mkpart/] [Makefile] - Diff between revs 18 and 108

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 18 Rev 108
#
#
# Makefile for "mkpart", a program to write the partition table
# Makefile for "mkpart", a program to write the partition table
# and the bootblock on a hard disk
# and the bootblock on a hard disk
#
#
BUILD = ../../build
BUILD = ../../build
SRC = start.s main.c iolib.c biolib.c end.s
SRC = start.s main.c iolib.c biolib.c end.s
BIN = mkpart.bin
BIN = mkpart.bin
MAP = mkpart.map
MAP = mkpart.map
 
EXO = mkpart.exo
 
 
.PHONY:         all install run clean
.PHONY:         all install run clean
 
 
all:            $(BIN)
all:            $(BIN) $(EXO)
 
 
install:        $(BIN)
install:        $(BIN) $(EXO)
                mkdir -p $(BUILD)/stdalone
                mkdir -p $(BUILD)/stdalone
                cp $(BIN) $(BUILD)/stdalone
                cp $(BIN) $(BUILD)/stdalone
                cp $(MAP) $(BUILD)/stdalone
                cp $(MAP) $(BUILD)/stdalone
 
                cp $(EXO) $(BUILD)/stdalone
 
 
run:            $(BIN)
run:            $(BIN)
                $(BUILD)/bin/sim -i -t 1 -l $(BIN) -d $(BUILD)/disk/disk.img
                $(BUILD)/bin/sim -i -t 1 -l $(BIN) -a 0x10000 \
 
                  -d $(BUILD)/run/disk.img
 
 
 
$(EXO):         $(BIN)
 
                $(BUILD)/bin/bin2exo -S2 0x10000 $(BIN) $(EXO)
 
 
$(BIN):         $(SRC) mboot.dump
$(BIN):         $(SRC) mboot.dump
                $(BUILD)/bin/lcc -A -Wo-kernel \
                $(BUILD)/bin/lcc -A -Wo-kernel \
                  -Wl-m -Wl$(MAP) -o $(BIN) $(SRC)
                  -Wl-m -Wl$(MAP) -o $(BIN) $(SRC)
mboot.dump:     dump/dump mboot
mboot.dump:     dump/dump mboot
                ./dump/dump mboot mboot.dump
                ./dump/dump mboot mboot.dump
dump/dump:
dump/dump:
                $(MAKE) -C dump all
                $(MAKE) -C dump all
mboot:          mkmboot/mbootblk mkptbl/parttbl
mboot:          mkmboot/mbootblk mkptbl/parttbl
                dd if=/dev/zero of=mboot bs=512 count=32
                dd if=/dev/zero of=mboot bs=512 count=32
                dd if=mkmboot/mbootblk of=mboot bs=512 conv=notrunc
                dd if=mkmboot/mbootblk of=mboot bs=512 conv=notrunc
                dd if=mkptbl/parttbl of=mboot bs=512 seek=1 conv=notrunc
                dd if=mkptbl/parttbl of=mboot bs=512 seek=1 conv=notrunc
mkptbl/parttbl:
mkptbl/parttbl:
                $(MAKE) -C mkptbl all
                $(MAKE) -C mkptbl all
mkmboot/mbootblk:
mkmboot/mbootblk:
                $(MAKE) -C mkmboot all
                $(MAKE) -C mkmboot all
clean:
clean:
                $(MAKE) -C dump clean
                $(MAKE) -C dump clean
                $(MAKE) -C mkptbl clean
                $(MAKE) -C mkptbl clean
                $(MAKE) -C mkmboot clean
                $(MAKE) -C mkmboot clean
                rm -f *~ mboot mboot.dump $(BIN) $(MAP)
                rm -f *~ mboot mboot.dump $(BIN) $(MAP) $(EXO)
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.