#************************************************************************
#*   IRC - Internet Relay Chat, Makefile
#*   Copyright (C) 1990, Jarkko Oikarinen
#*
#*   This program is free software; you can redistribute it and/or modify
#*   it under the terms of the GNU General Public License as published by
#*   the Free Software Foundation; either version 1, or (at your option)
#*   any later version.
#*
#*   This program is distributed in the hope that it will be useful,
#*   but WITHOUT ANY WARRANTY; without even the implied warranty of
#*   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#*   GNU General Public License for more details.
#*
#*   You should have received a copy of the GNU General Public License
#*   along with this program; if not, write to the Free Software
#*   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#*
#*   $Id: Makefile.in,v 1.70 2008/06/06 23:51:26 chopin Exp $
#*
#*/

# -------------------------------------------------------------------------
# Start of system configuration section.
#
prefix = @prefix@
exec_prefix = @exec_prefix@

# compiler program
CC = @CC@
# compiler flags used for the server
S_CFLAGS = @CFLAGS@ -I. -I../ircd -I../common @IRC_ZLIB_INCLUDE@
# compiler flags used for the authentication slave
A_CFLAGS = @CFLAGS@ -I. -I../iauth -I../common @IRC_ZLIB_INCLUDE@
# compiler flags used for chkconfig
CC_CFLAGS = @CFLAGS@ -I. -I../ircd -I../common
# compiler flags used for the client
C_CFLAGS = @CFLAGS@ -I. -I../ircd -I../common -DCLIENT_COMPILE
# compiler flags used for other things (in contrib/)
O_CFLAGS = @CFLAGS@ -I. -I../common -DCONTRIB_COMPILE
# linker flags
LDFLAGS = @LDFLAGS@
# required libraries, except zlib
LIBS = @LIBS@
MATHLIBS = @MATHLIBS@
# zlib, eventually
ZLIBS = @IRC_ZLIB_LIBRARY@
# for DSM support (dlopen(), dlsym(), dlclose())
DLIBS = @IRC_DLIB@
# install and related programs
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
MKDIRHIER = ../support/mkdirhier

#
# Binary names
#
# Note: $(IRCD) is basename for config, log and var files. Make sure to
# make clean after changing this one.
IRCD = ircd
IRCD_BIN = $(IRCD)
IAUTH = iauth
IRCDWATCH = ircdwatch
# TK line service binary
TKSERV = tkserv

#
# Directories definitions
#
# Directory in which to install ircd, iauth, ircdwatch, mkpasswd and chkconf.
server_bin_dir = @sbindir@
# Directory in which to install the configuration manual page.
conf_man_dir = @mandir@/man5
# Directory in which to install the server manual page.
server_man_dir = @mandir@/man8
# Directory where config files (ircd.conf, ircd.motd and iauth.conf) live.
ircd_conf_dir = @sysconfdir@
# Directory where state files (ircd.pid, ircd.tune) live.
ircd_var_dir = @rundir@
# Directory where log files (users, opers, rejects and auth) live.
ircd_log_dir = @logdir@

#
# Most of these PATHs are hardcoded in the binaries.
# They should all be absolute.
#
# Path to server binary
IRCD_PATH = $(server_bin_dir)/$(IRCD_BIN)
# Path to authentication slave binary
IAUTH_PATH = $(server_bin_dir)/$(IAUTH)
# Path to the m4 configuration file
IRCDM4_PATH = $(ircd_conf_dir)/$(IRCD).m4

# Path to the m4 executable
M4_PATH = @M4_PATH@

# server configuration file
IRCDCONF_PATH = $(ircd_conf_dir)/$(IRCD).conf
# server configuration file (only for writing klines to)
KLINE_PATH = $(ircd_conf_dir)/$(IRCD).kline
# server Message Of The Day
IRCDMOTD_PATH = $(ircd_conf_dir)/$(IRCD).motd
# authentication slave configuration file
IAUTHCONF_PATH = $(ircd_conf_dir)/$(IAUTH).conf
# server PID file
IRCDPID_PATH = $(ircd_var_dir)/$(IRCD).pid
# authentication slave PID file
IAUTHPID_PATH = $(ircd_var_dir)/$(IAUTH).pid
# server state file
IRCDTUNE_PATH = $(ircd_var_dir)/$(IRCD).tune
# ircdwatch PID file
IRCDWATCHPID_PATH = $(ircd_var_dir)/$(IRCDWATCH).pid

# Define these filenames to maintain a list of persons who log
# into this server. Logging will stop when the file does not exist.
# Logging will be disabled also if you do not define this.
FNAME_USERLOG = $(ircd_log_dir)/$(IRCD).users
FNAME_OPERLOG = $(ircd_log_dir)/$(IRCD).opers
FNAME_CONNLOG = $(ircd_log_dir)/$(IRCD).rejects
FNAME_AUTHLOG = $(ircd_log_dir)/$(IRCD).auth

# If defined in config.h, server channels will be logged at this
# location with name of server channel (without '&') appended to
# this prefix.
FNAME_SCH_PREFIX = $(ircd_log_dir)/$(IRCD)

# files used for debugging purposes
IRCDDBG_PATH = $(ircd_log_dir)/$(IRCD).debug
IAUTHDBG_PATH = $(ircd_log_dir)/$(IAUTH).debug

# Access mode for irc.
irc_mode = 755

# Access mode for ircd.
ircd_mode = 711

#
# TK line service configuration
#
# TK line service logfile
TKSERV_LOGFILE = $(ircd_log_dir)/$(TKSERV).log
# TK line service access file 
TKSERV_ACCESSFILE = $(ircd_conf_dir)/$(TKSERV).access
# TK config file to append tklines to.
# It could be $(IRCDCONF_PATH), but is not recommended.
TKSERV_CONF_PATH = $(ircd_conf_dir)/$(TKSERV).kline

# End of system configuration section.
# ------------------------------------------------------------------------
# Please don't change anything below this point - no need really - I hope.

RM = rm -f

CLIENT_COMMON_OBJS = clbsd.o cldbuf.o clpacket.o clsend.o clmatch.o \
                     clparse.o clsupport.o
IRCD_COMMON_OBJS = bsd.o dbuf.o packet.o send.o match.o parse.o \
                     support.o
IRCD_OBJS = channel.o class.o hash.o ircd.o list.o res.o s_auth.o \
              s_bsd.o s_conf.o s_debug.o s_err.o s_id.o s_misc.o s_numeric.o \
              s_send.o s_serv.o s_service.o s_user.o s_zip.o whowas.o \
              res_init.o res_comp.o res_mkquery.o patricia.o

IAUTH_COMMON_OBJS = clsupport.o clmatch.o # This is a little evil
IAUTH_OBJS = iauth.o a_conf.o a_io.o a_log.o \
             mod_lhex.o mod_pipe.o mod_rfc931.o mod_socks.o mod_webproxy.o

CHKCONF_COMMON_OBJS = match.o
CHKCONF_OBJS = chkconf.o
CHKCONF = chkconf

help:
	@echo "Choose one of the following:"
	@echo "        all            : build everything"
	@echo "        server         : build server programs"
	@echo "                $(IRCD_BIN)		: build the irc daemon"
	@echo "                $(IAUTH)		: build the authentication slave"
	@echo "                chkconf		: build the configuration file checker"
	@echo "                ircd-mkpasswd	: build ircd-mkpasswd"
	@echo "                $(IRCDWATCH)	: build ircdwatch"
	@echo "        $(TKSERV)	: build tkserv"
	@echo
	@echo "        install        : build and install server programs"
	@echo "        install-server : build and install server programs"
	@echo "        install-tkserv : build and install tkserv"

all: server

server: $(IRCD_BIN) $(IAUTH) $(CHKCONF) ircd-mkpasswd $(IRCDWATCH)

$(IRCD_BIN): $(IRCD_COMMON_OBJS) $(IRCD_OBJS)
	$(RM) $@
	./version.c.SH
	$(CC) $(S_CFLAGS) -c -o version.o version.c
	$(CC) $(LDFLAGS) -o $@ $(IRCD_COMMON_OBJS) version.o $(IRCD_OBJS) $(ZLIBS) $(MATHLIBS) $(LIBS)

$(IAUTH): $(IAUTH_COMMON_OBJS) $(IAUTH_OBJS)
	$(RM) $@
	$(CC) $(LDFLAGS) -o $@ $(IAUTH_COMMON_OBJS) $(IAUTH_OBJS) $(LIBS) $(DLIBS)

$(CHKCONF): $(CHKCONF_COMMON_OBJS) $(CHKCONF_OBJS)
	$(RM) $@
	$(CC) $(LDFLAGS) -o $@ $(CHKCONF_COMMON_OBJS) $(CHKCONF_OBJS) $(LIBS)

# stuff in contrib/

$(IRCDWATCH): ircdwatch.o clsupport.o clmatch.o
	$(RM) $(IRCDWATCH)
	$(CC) $(LDFLAGS) -o $(IRCDWATCH) clsupport.o clmatch.o ircdwatch.o $(LIBS)

ircd-mkpasswd: mkpasswd.o
	$(RM) ircd-mkpasswd
	$(CC) $(LDFLAGS) -o ircd-mkpasswd mkpasswd.o $(LIBS)

$(TKSERV): tkserv.o
	$(RM) $(TKSERV)
	$(CC) $(LDFLAGS) -o $(TKSERV) tkserv.o $(LIBS)

install: install-server

install-ircd: $(IRCD_BIN)
	-@if [ ! -d $(server_bin_dir) ]; then \
		$(MKDIRHIER) $(server_bin_dir); \
	fi
	$(INSTALL_PROGRAM) -m $(ircd_mode) $(IRCD_BIN) $(server_bin_dir)

install-server: install-ircd server
	-@if [ ! -d $(server_man_dir) ]; then \
		$(MKDIRHIER) $(server_man_dir); \
	fi
	-@if [ ! -d $(conf_man_dir) ]; then \
		$(MKDIRHIER) $(conf_man_dir); \
	fi
	-@if [ ! -d $(ircd_conf_dir) ]; then \
		$(MKDIRHIER) $(ircd_conf_dir); \
	fi
	-@if [ ! -d $(ircd_var_dir) ]; then \
		$(MKDIRHIER) $(ircd_var_dir); \
	fi
	-@if [ ! -d $(ircd_log_dir) ]; then \
		$(MKDIRHIER) $(ircd_log_dir); \
	fi
	$(INSTALL_PROGRAM) -m $(ircd_mode) $(IAUTH) $(server_bin_dir)
	$(INSTALL_PROGRAM) -m $(ircd_mode) $(CHKCONF) $(server_bin_dir)
	$(INSTALL_PROGRAM) -m $(ircd_mode) ircd-mkpasswd $(server_bin_dir)
	$(INSTALL_PROGRAM) -m $(ircd_mode) $(IRCDWATCH) $(server_bin_dir)
	$(RM) $(IRCDM4_PATH)
	../ircd/buildm4 $(IRCDM4_PATH)
	$(INSTALL_DATA) ../doc/ircd.8 $(server_man_dir)
	$(INSTALL_DATA) ../doc/iauth.8 $(server_man_dir)
	$(INSTALL_DATA) ../doc/iauth.conf.5 $(conf_man_dir)
	$(INSTALL_DATA) ../contrib/ircdwatch/ircdwatch.8 $(server_man_dir)
	$(INSTALL_DATA) ../doc/ircd.conf.example $(ircd_conf_dir)
	$(INSTALL_DATA) ../doc/iauth.conf.example $(ircd_conf_dir)
	-@if [ ! -f $(IAUTHCONF_PATH) ]; then \
		$(INSTALL_DATA) ../doc/iauth.conf.example $(IAUTHCONF_PATH); \
	fi
	-@if [ ! -f $(IRCDMOTD_PATH) ]; then \
		$(INSTALL_DATA) ../support/ircd.motd $(IRCDMOTD_PATH); \
	fi
	@echo "installation of server done."

install-tkserv: $(TKSERV)
	-@if [ ! -d $(server_bin_dir) ]; then \
	$(MKDIRHIER) $(server_bin_dir); \
	fi
	-@if [ ! -d $(ircd_conf_dir) ]; then \
	$(MKDIRHIER) $(ircd_conf_dir); \
	fi
	$(INSTALL_PROGRAM) -m $(ircd_mode) $(TKSERV) $(server_bin_dir)
	@echo "installation of tkserv done."

clbsd.o: ../common/bsd.c setup.h config.h ../common/struct_def.h
	$(CC) $(C_CFLAGS) -c -o $@ ../common/bsd.c

cldbuf.o: ../common/dbuf.c setup.h config.h ../common/struct_def.h
	$(CC) $(C_CFLAGS) -c -o $@ ../common/dbuf.c

clpacket.o: ../common/packet.c setup.h config.h ../common/struct_def.h
	$(CC) $(C_CFLAGS) -c -o $@ ../common/packet.c

clsend.o: ../common/send.c setup.h config.h ../common/struct_def.h
	$(CC) $(C_CFLAGS) -c -o $@ ../common/send.c

clmatch.o: ../common/match.c setup.h config.h ../common/struct_def.h
	$(CC) $(C_CFLAGS) -c -o $@ ../common/match.c

clparse.o: ../common/parse.c setup.h config.h ../common/struct_def.h
	$(CC) $(C_CFLAGS) -c -o $@ ../common/parse.c

clsupport.o: ../common/support.c setup.h config.h ../common/struct_def.h ../common/patchlevel.h
	$(CC) $(C_CFLAGS) -c -o $@ ../common/support.c

bsd.o: ../common/bsd.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../common/bsd.c

dbuf.o: ../common/dbuf.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../common/dbuf.c

packet.o: ../common/packet.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../common/packet.c

send.o: ../common/send.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -DFNAME_USERLOG="\"$(FNAME_USERLOG)\"" \
	-DFNAME_CONNLOG="\"$(FNAME_CONNLOG)\"" \
	-DFNAME_SCH_PREFIX="\"$(FNAME_SCH_PREFIX)\"" \
	-c -o $@ ../common/send.c

match.o: ../common/match.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../common/match.c

parse.o: ../common/parse.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../common/parse.c

support.o: ../common/support.c setup.h config.h ../common/struct_def.h ../common/patchlevel.h
	$(CC) $(S_CFLAGS) -c -o $@ ../common/support.c

channel.o: ../ircd/channel.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/channel.c

class.o: ../ircd/class.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/class.c

hash.o: ../common/struct_def.h ../common/os.h ../ircd/hash_def.h \
	../ircd/hash_ext.h ../ircd/hash.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/hash.c

ircd.o: ../ircd/ircd.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -DIRCDCONF_PATH="\"$(IRCDCONF_PATH)\"" \
	-DIRCDTUNE_PATH="\"$(IRCDTUNE_PATH)\"" \
	-DIRCDMOTD_PATH="\"$(IRCDMOTD_PATH)\""  \
	-DIRCD_PATH="\"$(IRCD_PATH)\"" -DIAUTH_PATH="\"$(IAUTH_PATH)\"" \
	-DIAUTH="\"$(IAUTH)\"" -DIRCDDBG_PATH="\"$(IRCDDBG_PATH)\"" \
	-c -o $@ ../ircd/ircd.c

list.o: ../ircd/list.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/list.c

patricia.o: ../ircd/patricia.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/patricia.c

res.o: ../ircd/res.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/res.c

s_auth.o: ../ircd/s_auth.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_auth.c

s_bsd.o: ../ircd/s_bsd.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -DIRCDPID_PATH="\"$(IRCDPID_PATH)\"" -DIAUTH_PATH="\"$(IAUTH_PATH)\"" -DIAUTH="\"$(IAUTH)\"" -c -o $@ ../ircd/s_bsd.c

s_conf.o: ../ircd/s_conf.c setup.h config.h ../common/struct_def.h ../ircd/config_read.c
	$(CC) $(S_CFLAGS) -DIRCDMOTD_PATH="\"$(IRCDMOTD_PATH)\"" \
	-DIRCDM4_PATH="\"$(IRCDM4_PATH)\"" -DIRCDCONF_PATH="\"$(IRCDCONF_PATH)\"" \
	-DKLINE_PATH="\"$(KLINE_PATH)\"" \
	-DIRCDCONF_DIR="\"$(ircd_conf_dir)/\"" \
	-DM4_PATH="\"$(M4_PATH)\"" -c -o $@ ../ircd/s_conf.c

s_debug.o: ../ircd/s_debug.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_debug.c

s_err.o: ../ircd/s_err.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_err.c

s_id.o: ../ircd/s_id.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_id.c

s_misc.o: ../ircd/s_misc.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -DFNAME_USERLOG="\"$(FNAME_USERLOG)\"" -DFNAME_CONNLOG="\"$(FNAME_CONNLOG)\"" -c -o $@ ../ircd/s_misc.c

s_numeric.o: ../ircd/s_numeric.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_numeric.c

s_serv.o: ../ircd/s_serv.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -DIRCDMOTD_PATH="\"$(IRCDMOTD_PATH)\"" -c -o $@ ../ircd/s_serv.c

s_send.o: ../ircd/s_send.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_send.c

s_service.o: ../ircd/s_service.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_service.c

s_user.o: ../ircd/s_user.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -DFNAME_USERLOG="\"$(FNAME_USERLOG)\"" -DFNAME_CONNLOG="\"$(FNAME_CONNLOG)\"" -DFNAME_OPERLOG="\"$(FNAME_OPERLOG)\"" -c -o $@ ../ircd/s_user.c

s_zip.o: ../ircd/s_zip.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/s_zip.c

whowas.o: ../ircd/whowas.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/whowas.c

res_init.o: ../ircd/res_init.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/res_init.c

res_comp.o: ../ircd/res_comp.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/res_comp.c

res_mkquery.o: ../ircd/res_mkquery.c setup.h config.h ../common/struct_def.h
	$(CC) $(S_CFLAGS) -c -o $@ ../ircd/res_mkquery.c

iauth.o: ../iauth/iauth.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -DIAUTHPID_PATH="\"$(IAUTHPID_PATH)\"" -c -o $@ ../iauth/iauth.c

a_conf.o: ../iauth/a_conf.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -DIAUTHCONF_PATH="\"$(IAUTHCONF_PATH)\"" -c -o $@ ../iauth/a_conf.c

a_dyn.o: ../iauth/a_dyn.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -c -o $@ ../iauth/a_dyn.c

a_io.o: ../iauth/a_io.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -c -o $@ ../iauth/a_io.c

a_log.o: ../iauth/a_log.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -DIAUTHDBG_PATH="\"$(IAUTHDBG_PATH)\"" -DFNAME_AUTHLOG="\"$(FNAME_AUTHLOG)\"" -c -o $@ ../iauth/a_log.c

mod_lhex.o: ../iauth/mod_lhex.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -c -o $@ ../iauth/mod_lhex.c

mod_pipe.o: ../iauth/mod_pipe.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -c -o $@ ../iauth/mod_pipe.c

mod_rfc931.o: ../iauth/mod_rfc931.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -c -o $@ ../iauth/mod_rfc931.c

mod_socks.o: ../iauth/mod_socks.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -c -o $@ ../iauth/mod_socks.c

mod_webproxy.o: ../iauth/mod_webproxy.c config.h ../common/struct_def.h setup.h
	$(CC) $(A_CFLAGS) -c -o $@ ../iauth/mod_webproxy.c

chkconf.o: ../ircd/chkconf.c setup.h config.h ../common/struct_def.h ../ircd/config_read.c
	$(CC) $(CC_CFLAGS) -DCHKCONF_COMPILE -DIRCDCONF_PATH="\"$(IRCDCONF_PATH)\"" \
	-DIRCDCONF_DIR="\"$(ircd_conf_dir)/\"" \
	-DM4_PATH="\"$(M4_PATH)\"" -DIRCDM4_PATH="\"$(IRCDM4_PATH)\"" -c -o $@ ../ircd/chkconf.c

# stuff in contrib/

ircdwatch.o: ../contrib/ircdwatch/ircdwatch.c
	$(CC) $(O_CFLAGS) -DIRCDWATCH_PID_FILENAME="\"$(IRCDWATCHPID_PATH)\"" -DIRCD_PATH="\"$(IRCD_PATH)\"" -DIRCDCONF_PATH="\"$(IRCDCONF_PATH)\"" -DIRCDPID_PATH="\"$(IRCDPID_PATH)\"" -c -o $@ ../contrib/ircdwatch/ircdwatch.c

mkpasswd.o: ../contrib/mkpasswd/mkpasswd.c
	$(CC) $(O_CFLAGS) -c -o $@ ../contrib/mkpasswd/mkpasswd.c

tkserv.o: ../contrib/tkserv/tkserv.c tkconf.h
	$(CC) $(O_CFLAGS) -DTKSERV_LOGFILE="\"$(TKSERV_LOGFILE)\"" -DTKSERV_ACCESSFILE="\"$(TKSERV_ACCESSFILE)\"" -DCPATH="\"$(TKSERV_CONF_PATH)\"" -DPPATH="\"$(IRCDPID_PATH)\"" -c -o $@ ../contrib/tkserv/tkserv.c

clean:
	$(RM) $(IRCD_BIN) $(IAUTH) $(CHKCONF) ircd-mkpasswd $(IRCDWATCH) $(TKSERV) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut "#"* version.c

distclean:
	@echo "To make distclean, just delete the current directory."

rcs:
	(cd ..; cii -H -R configure common doc include irc ircd support)
