# $Id: Makefile.in,v 1.26.2.1 2004/07/09 04:56:43 musirc Exp $

INSTALL		= @INSTALL@
INSTALL_DATA	= @INSTALL_DATA@
RM		= @RM@
TEST		= @TEST@
prefix		= $(DESTDIR)@prefix@
sysconfdir	= @sysconfdir@
exec_prefix	= @exec_prefix@
DISTFILES	= example.conf example.conf.quick

all:

install:
	@if $(TEST) $(sysconfdir) -ef `pwd`; then exit; fi; \
	mkdir -p $(sysconfdir); \
	for i in $(DISTFILES); do \
		$(INSTALL_DATA) $$i $(sysconfdir); \
	done

	@if test ! -f "$(sysconfdir)/ircd.motd"; then \
		echo "This is the default MusIRCd MOTD" > $(sysconfdir)/ircd.motd; \
	fi

	@if test ! -f "$(sysconfdir)/ircd.max"; then \
		touch $(sysconfdir)/ircd.max; \
	fi

	@for i in d k x; do \
		if test ! -f "$(sysconfdir)/$${i}line.conf"; then \
			touch $(sysconfdir)/$${i}line.conf; \
		fi; \
	done

	@for i in n c; do \
		if test ! -f "$(sysconfdir)/$${i}jupes.conf"; then \
			touch $(sysconfdir)/$${i}jupes.conf; \
		fi; \
	done

distclean:
	${RM} -f Makefile

.PHONY: install distclean
