2002-01-05 10:13:25 +00:00
|
|
|
LIBNAME = libvidix.a
|
2002-01-07 09:28:22 +00:00
|
|
|
SUBDIRS = drivers
|
|
|
|
DO_MAKE = @ for i in $(SUBDIRS); do $(MAKE) -C $$i $@; done
|
2002-01-05 10:13:25 +00:00
|
|
|
|
|
|
|
include ../config.mak
|
|
|
|
|
|
|
|
SRCS = vidixlib.c
|
|
|
|
OBJS = $(SRCS:.c=.o)
|
|
|
|
|
2002-08-22 23:29:46 +00:00
|
|
|
CFLAGS = $(OPTFLAGS)
|
2002-01-05 10:13:25 +00:00
|
|
|
|
|
|
|
.SUFFIXES: .c .o
|
|
|
|
|
|
|
|
# .PHONY: all clean
|
|
|
|
|
|
|
|
.c.o:
|
|
|
|
$(CC) -c $(CFLAGS) -o $@ $<
|
|
|
|
|
2002-01-07 09:28:22 +00:00
|
|
|
all: $(SUBDIRS) $(LIBNAME)
|
|
|
|
$(DO_MAKE)
|
|
|
|
|
2002-01-05 10:13:25 +00:00
|
|
|
$(LIBNAME): $(OBJS)
|
|
|
|
$(AR) r $(LIBNAME) $(OBJS)
|
|
|
|
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f *.o *.a *~
|
2002-01-07 09:28:22 +00:00
|
|
|
$(DO_MAKE)
|
2002-01-05 10:13:25 +00:00
|
|
|
|
|
|
|
distclean:
|
|
|
|
rm -f test *.o *.a *~ .depend
|
2002-01-07 09:28:22 +00:00
|
|
|
$(DO_MAKE)
|
2002-01-05 10:13:25 +00:00
|
|
|
|
|
|
|
dep: depend
|
2002-01-07 09:28:22 +00:00
|
|
|
$(DO_MAKE)
|
2002-01-05 10:13:25 +00:00
|
|
|
|
|
|
|
depend:
|
|
|
|
$(CC) -MM $(CFLAGS) $(SRCS) 1>.depend
|
|
|
|
|
2002-01-07 09:28:22 +00:00
|
|
|
install:
|
|
|
|
$(DO_MAKE)
|
|
|
|
|
2002-01-05 10:13:25 +00:00
|
|
|
#
|
|
|
|
# include dependency files if they exist
|
|
|
|
#
|
|
|
|
ifneq ($(wildcard .depend),)
|
|
|
|
include .depend
|
|
|
|
endif
|