CPP=@CPP@
CXX=@CXX@
CC=@CC@

AFLAGS=-g
CFLAGS=@CFLAGS@ -I. -I.. -I../video -I@top_srcdir@/../lib/ccvt @DEFS@
CXXFLAGS=$(CFLAGS)

LIBS=@LIBS@
MOC=@MOC@


OBJS=	VideoDevice.o VideoDevice.moc.o \
	VideoDeviceInput.o VideoDeviceInput.moc.o\
	VideoDeviceTuner.o VideoDeviceTuner.moc.o\
	VideoAudioInput.o VideoAudioInput.moc.o\
	VideoCollector.o 

# Not all object require the MOC preprocessor
MOCH=	VideoDevice.h VideoDeviceInput.h VideoDeviceTuner.h
MOBJS := $(patsubst %.h, %.moc.o, $(MOCH))

all:	devices.a

%.moc.cc: %.h
	$(MOC) -o $@ $<


%.o:	%.S
	$(CC) $(CFLAGS) -c -o $@ $<

clean:
	rm -f *.o *.a *~ *.moc.cc *.bak core

distclean:	clean
	rm -f config.h config.cache config.log config.status
	rm -f DEADJOE Makefile 

dep:
	makedepend -- $(CXXFLAGS) *.cc

devices.a: $(OBJS) $(MOBJS)
	ar rcs $@ $(OBJS) $(MOBJS)

