# MAKEFILE for MELANGE CHAT SERVER 1.10
# (C) 1998,1999 by Christian Walter, All rights reserved.

DIR_SERVER=../../
DIR_CONFIGFILE=../../
DIR_DOC=../../doc
CC = gcc  -O2 -Wall

OBJS =	main.o util.o chatutil.o sysutil.o comm.o interpret.o admin.o signals.o

all: eng 

static: $(OBJS)
	$(CC) $(OBJS) -o melange -static

melange: $(OBJS)
	$(CC) $(OBJS) -o melange

main.o : main.c melange.h
util.o : util.c melange.h
chatutil.o: chatutil.c melange.h
sysutil.o: sysutil.c melange.h
comm.o: comm.c melange.h
interpret.o: interpret.c melange.h
admin.o: admin.c melange.h
signals.o: signals.c melange.h

ger:	
	ln -sf ./langs/language.ger ./language.h
	make melange
eng:	
	ln -sf ./langs/language.eng ./language.h
	make melange
fra:	
	ln -sf ./langs/language.fra ./language.h
	make melange
ita:	
	ln -sf ./langs/language.ita ./language.h
	make melange
cat:	
	ln -sf ./langs/language.cat ./language.h
	make melange
clean:
	rm -f *.o *~ melange language.h core
#install:
#	install -c -m 711 melange $(DIR_SERVER)
#	install -c -m 755 melange.conf $(DIR_CONFIGFILE)

install-doc:
	mkdir $(DIR_DOC)
	mkdir $(DIR_DOC)/printable
	cp ../doc/*.html $(DIR_DOC)
	cp ../doc/printable/*.html $(DIR_DOC)/printable
info:
	@echo
	@echo "Melange Chat Server - Version 1.10"
	@echo "Select the language you want to use for your server:"
	@echo 
	@echo "CATALAN AND FRENCH USERS PLEASE READ THE DOC !"
	@echo
	@echo "make eng ... English"
	@echo "make ger ... German"
	@echo "make ita ... Italian (by Pietro Femmino')"
	@echo "make fra ... French (by Oliver Mueller)"
	@echo "make cat ... Catalan (by David Diaz)"
	@echo
