kern

diff fstools/mkfs/Makefile @ 90:7ff2b4971216

started work on the filesystem
author John Tsiombikas <nuclear@member.fsf.org>
date Fri, 09 Dec 2011 13:44:15 +0200
parents
children
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/fstools/mkfs/Makefile	Fri Dec 09 13:44:15 2011 +0200
     1.3 @@ -0,0 +1,23 @@
     1.4 +ksrc = ../../src
     1.5 +
     1.6 +obj = mkfs.o fs.o
     1.7 +dep = $(obj:.o=.d)
     1.8 +bin = mkfs
     1.9 +
    1.10 +CC = gcc
    1.11 +CFLAGS = -pedantic -Wall -g -I$(ksrc)
    1.12 +
    1.13 +$(bin): $(obj)
    1.14 +	$(CC) -o $@ $(obj) $(LDFLAGS)
    1.15 +
    1.16 +-include $(dep)
    1.17 +
    1.18 +fs.o: $(ksrc)/fs.c
    1.19 +	$(CC) $(CFLAGS) -c $< -o $@
    1.20 +
    1.21 +%.d: %.c
    1.22 +	@$(CPP) $(CFLAGS) $< -MM -MT $(@:.d=.o) >$@
    1.23 +
    1.24 +.PHONY: clean
    1.25 +clean:
    1.26 +	rm -f $(obj) $(bin) $(dep)