2002-05-03 11:59:53 +00:00
|
|
|
FIRMWARE = ../..
|
2002-04-26 16:44:58 +00:00
|
|
|
DRIVERS = ../../drivers
|
|
|
|
|
2002-05-03 11:59:53 +00:00
|
|
|
CFLAGS = -g -Wall -DTEST_FAT -I$(DRIVERS) -I$(FIRMWARE)/common -I$(FIRMWARE) -I. -DDEBUG -DCRT_DISPLAY
|
2002-04-26 16:44:58 +00:00
|
|
|
|
|
|
|
TARGET = fat
|
|
|
|
|
2002-05-07 16:01:53 +00:00
|
|
|
$(TARGET): fat.o ata-sim.o main.o disk.o debug.o dir.o file.o
|
2002-04-26 16:44:58 +00:00
|
|
|
gcc -g -o fat $+ -lfl
|
|
|
|
|
|
|
|
fat.o: $(DRIVERS)/fat.c $(DRIVERS)/fat.h $(DRIVERS)/ata.h
|
|
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
|
2002-05-03 11:59:53 +00:00
|
|
|
disk.o: $(FIRMWARE)/common/disk.c
|
|
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
|
2002-05-03 15:36:52 +00:00
|
|
|
dir.o: $(FIRMWARE)/common/dir.c
|
|
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
|
2002-05-07 16:01:53 +00:00
|
|
|
file.o: $(FIRMWARE)/common/file.c
|
|
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
|
2002-05-03 11:59:53 +00:00
|
|
|
debug.o: $(FIRMWARE)/debug.c
|
2002-05-08 12:13:47 +00:00
|
|
|
$(CC) $(CFLAGS) -DSIMULATOR -c $< -o $@
|
2002-05-03 11:59:53 +00:00
|
|
|
|
2002-04-26 16:44:58 +00:00
|
|
|
ata-sim.o: ata-sim.c $(DRIVERS)/ata.h
|
|
|
|
|
2002-05-03 11:59:53 +00:00
|
|
|
main.o: main.c $(DRIVERS)/ata.h
|
2002-04-26 16:44:58 +00:00
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f *.o $(TARGET)
|
|
|
|
rm -f *~
|
|
|
|
rm -f cmd.tab.h lex.yy.c cmd.tab.c
|
|
|
|
rm -f core
|
|
|
|
|
|
|
|
tar:
|
|
|
|
rm -f $(TARGET).tar
|
|
|
|
tar cvf $(TARGET).tar -C .. fat
|