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

Subversion Repositories eco32

[/] [eco32/] [trunk/] [stdalone/] [mkpart/] [Makefile] - Blame information for rev 153

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 18 hellwig
#
2
# Makefile for "mkpart", a program to write the partition table
3
# and the bootblock on a hard disk
4
#
5
 
6
BUILD = ../../build
7
 
8
SRC = start.s main.c iolib.c biolib.c end.s
9
BIN = mkpart.bin
10
MAP = mkpart.map
11 108 hellwig
EXO = mkpart.exo
12 18 hellwig
 
13
.PHONY:         all install run clean
14
 
15 108 hellwig
all:            $(BIN) $(EXO)
16 18 hellwig
 
17 108 hellwig
install:        $(BIN) $(EXO)
18 18 hellwig
                mkdir -p $(BUILD)/stdalone
19
                cp $(BIN) $(BUILD)/stdalone
20
                cp $(MAP) $(BUILD)/stdalone
21 108 hellwig
                cp $(EXO) $(BUILD)/stdalone
22 18 hellwig
 
23
run:            $(BIN)
24 108 hellwig
                $(BUILD)/bin/sim -i -t 1 -l $(BIN) -a 0x10000 \
25
                  -d $(BUILD)/run/disk.img
26 18 hellwig
 
27 108 hellwig
$(EXO):         $(BIN)
28
                $(BUILD)/bin/bin2exo -S2 0x10000 $(BIN) $(EXO)
29
 
30 18 hellwig
$(BIN):         $(SRC) mboot.dump
31
                $(BUILD)/bin/lcc -A -Wo-kernel \
32
                  -Wl-m -Wl$(MAP) -o $(BIN) $(SRC)
33
 
34
mboot.dump:     dump/dump mboot
35
                ./dump/dump mboot mboot.dump
36
 
37
dump/dump:
38
                $(MAKE) -C dump all
39
 
40
mboot:          mkmboot/mbootblk mkptbl/parttbl
41
                dd if=/dev/zero of=mboot bs=512 count=32
42
                dd if=mkmboot/mbootblk of=mboot bs=512 conv=notrunc
43
                dd if=mkptbl/parttbl of=mboot bs=512 seek=1 conv=notrunc
44
 
45
mkptbl/parttbl:
46
                $(MAKE) -C mkptbl all
47
 
48
mkmboot/mbootblk:
49
                $(MAKE) -C mkmboot all
50
 
51
clean:
52
                $(MAKE) -C dump clean
53
                $(MAKE) -C mkptbl clean
54
                $(MAKE) -C mkmboot clean
55 108 hellwig
                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.