CPP	=	g++
CC	=	gcc
MOC	=	moc

INCL	=	-I$(QTDIR)/include -I$(KDEDIR)/include -I../../include
CPPINCL =	$(INCL)

LDFLAGS =	-L/usr/lib -L/opt/kde/lib

OBJS	=	$(OBJDIR)/preferences.o \
		$(OBJDIR)/image.o\
		$(OBJDIR)/imconv.o

MOBJS	=	

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

all:		$(MOBJS) $(OBJS)

$(OBJS):	$(MOBJS) build

build:	
		@for OBJ in $(OBJS) ; do \
			SRC=`basename $$OBJ .o` ; \
			if test ! -f "$$OBJ" -o "$$SRC.cpp" -nt "$$OBJ" -o "$$SRC.h" -nt "$$OBJ" ; then \
				echo "Compiling $$SRC.cpp" ; \
				$(CPP) $(CPPFLAGS) $(CPPINCL) -c $$SRC.cpp -o $$OBJ ; \
			fi \
		done
			

new:		clean all

clean:
		rm -f $(MOBJS) $(OBJS) *~ icons/*~

