TARGET = kde.o

LD		= ld
RM		= rm -f
CP		= cp

OBJS	= editor.o texture.o kdedialogs.o misc.o widgets.o
SUBDIRS	= widgets editor texture dialogs misc

all:		debug

release:	subdirs

debug:		subdirs

subdirs:
	set -e; for i in $(SUBDIRS); do $(MAKE) -C $$i "CPPFLAGS=$(CPPFLAGS)"; done
	$(LD) -r -o $(TARGET) $(OBJS)
	$(CP) $(TARGET) ../$(TARGET)

clean:
	set -e; for i in $(SUBDIRS); do $(MAKE) -C $$i clean; done
	$(RM) $(TARGET) *.o *~

new:	clean subdirs

