LIBTOOLFILES = conf/config.guess conf/config.sub conf/ltconfig conf/ltmain.sh
AUTOMAKEFILES = conf/mkinstalldirs conf/missing conf/install-sh
CONFIGHIN = include/config.h.in
ACLOCAL = conf/aclocal.m4
GETTEXT = intl/Makefile.in

all:
	@echo "Use make devel for development, make dist for distribution"

build: devel
	./configure --prefix=/usr --mandir=/usr/share/man --enable-debug --enable-kde
	make

devel: $(GETTEXT) $(LIBTOOLFILES) $(AUTOMAKEFILES)
	autoconf
	touch include/stamp-h.in

dist: $(GETTEXT) $(LIBTOOLFILES) $(AUTOMAKEFILES)
	autoconf
	touch include/stamp-h.in
	./configure --enable-kde
	$(MAKE) dist

$(ACLOCAL):
	aclocal -I conf/m4/plptools -I conf/m4/kde

$(CONFIGHIN): acconfig.h
	autoheader

$(LIBTOOLFILES):
	libtoolize

$(GETTEXT): $(ACLOCAL)
	echo n | gettextize -f
	-test -f po/ChangeLog~ && mv -f po/ChangeLog~ po/ChangeLog

$(AUTOMAKEFILES): $(ACLOCAL) $(CONFIGHIN)
	automake --add-missing
	make -C kde2 -f Makefile.am am_edit