APPS = $(OBJS:.o=)
-all: $(APPS) sizes
-
-$(OBJS): $(SRCS)
+all: $(APPS) size.report
$(APPS): $(CRT0)
-%: %.o
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $<
+$(APPS): %: %.o
+ $(LINKER) -o $@ $(LINKER_OPT) $^
expr.c: expr.y
byacc -o expr.c expr.y
find.c: find.y
byacc -o find.c find.y
-sizes: $(APPS)
- ls -l $(APPS) > size.report
+size.report: $(APPS)
+ ls -l $^ > $@
clean:
rm -f $(OBJS) $(APPS) $(SRCS:.c=) core *~ *.asm *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *.bin size.report
APPS = $(OBJS:.o=)
-all: $(APPS) sizes
-
-$(OBJS): $(SRCS)
+all: $(APPS) size.report
$(APPS): $(CRT0)
-%: %.o
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $<
+$(APPS): %: %.o
+ $(LINKER) -o $@ $(LINKER_OPT) $^
-sizes: $(APPS)
- ls -l $(APPS) > size.report
+size.report: $(APPS)
+ ls -l $^ > $@
clean:
rm -f $(OBJS) $(APPS) $(SRCS:.c=) core *~ *.asm *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *.bin size.report
$(OBJS): %.o : %.c
$(CC) -c $(CFLAGS) $(COPT) $<
-sh: $(OBJS)
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $(OBJS)
+sh: $(OBJS) $(CRT0)
+ $(LINKER) -o $@ $(LINKER_OPT) $^
clean:
rm -f $(OBJS) sh $(SRCS:.c=) core *~
APPS = $(OBJS:.o=)
-all: $(APPS) sizes
-
-$(OBJS): $(SRCS)
+all: $(APPS) size.report
$(APPS): $(CRT0)
-%: %.o
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $<
+$(APPS): %: %.o
+ $(LINKER) -o $@ $(LINKER_OPT) $^
-sizes: $(APPS)
- ls -l $(APPS) > size.report
+size.report: $(APPS)
+ ls -l $^ > $@
clean:
rm -f $(OBJS) $(APPS) $(SRCS:.c=) core *~ *.asm *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *.bin size.report
SRC = advent.c adventdb.c database.c english.c itverb.c lib.c saveadv.c \
turn.c verb.c
+
+
OBJ = $(SRC:.c=.o)
.SUFFIXES: .c .o
.c.o:
$(CC) $(CFLAGS) $(CCOPTS) -c $<
-advent: $(OBJ)
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $(OBJ)
+advent: $(OBJ) $(CRT0)
+ $(LINKER) -o $@ $(LINKER_OPT) $^
clean:
rm -f advent advent.db advgen *.rel *.asm *.lst core *.sym *.map *.noi *.lk *.ihx *.tmp *.bin *.o
APPS = $(OBJS:.o=)
-all: $(APPS) sizes
-
-$(OBJS): $(SRCS)
+all: $(APPS) size.report
$(APPS): $(CRT0)
-%: %.o
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $<
+$(APPS): %: %.o
+ $(LINKER) -o $@ $(LINKER_OPT) $^
-sizes: $(APPS)
- ls -l $(APPS) > size.report
+size.report: $(APPS)
+ ls -l $^ > $@
clean:
rm -f $(OBJS) $(APPS) $(SRCS:.c=) core *~ *.asm *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *.bin size.report
APPS = $(OBJS:.o=)
-all: $(APPS) sizes
-
-$(OBJS): $(SRCS)
+all: $(APPS) size.report
$(APPS): $(CRT0)
$(APPSNS): OPTS = --nostdio
-%: %.o
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $<
+$(APPS): %: %.o
+ $(LINKER) -o $@ $(LINKER_OPT) $^
-sizes: $(APPS)
- ls -l $(APPS) > size.report
+size.report: $(APPS)
+ ls -l $^ > $@
clean:
rm -f $(OBJS) $(APPS) $(SRCS:.c=) core *~ *.asm *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *.bin size.report
OBJS = $(CSRCS:.c=.o)
-levee: $(OBJS)
- $(LINKER) -o levee $(LINKER_OPT) $(CRT0) $(OBJS)
+levee: $(OBJS) $(CRT0)
+ $(LINKER) -o levee $(LINKER_OPT) $^
-$(OBJS): $(CSRCS)
-
-.c.o:
- $(CC) $(CFLAGS) $(COPT) -c $(@:.o=.c)
+$(OBJS): %.o: %.c
+ $(CC) $(CFLAGS) $(COPT) -c $<
clean:
rm -rf $(OBJS) *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *~ *.o *.asm levee levee.bin
APPS = $(OBJS:.o=)
-all: $(APPS) sizes
-
-$(OBJS): $(SRCS)
+all: $(APPS) size.report
$(APPS): $(CRT0)
-%: %.o
- $(LINKER) -o $@ $(LINKER_OPT) $(CRT0) $<
+$(APPS): %: %.o
+ $(LINKER) -o $@ $(LINKER_OPT) $^
-sizes: $(APPS)
- ls -l $(APPS) > size.report
+size.report: $(APPS)
+ ls -l $^ > $@
clean:
rm -f $(OBJS) $(APPS) $(SRCS:.c=) core *~ *.asm *.lst *.sym *.map *.noi *.lk *.ihx *.tmp *.bin size.report