#
# Copyright (c) 1991 University College London
# All rights reserved.
#
# Redistribution and use in source and binary forms are permitted
# provided that the above copyright notice and this paragraph are
# duplicated in all such forms and that any documentation,
# advertising materials, and other materials related to such
# distribution and use acknowledge that the software was developed
# by the Department of Computer Science, University College London.
# The name of the University may not be used to
# endorse or promote products derived from this software without
# specific prior written permission.
# THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#

PROGS	 =	simagent simmgr simos

MISLIBS =	../library/libsimtime.a \
		$(TOP)/manager/rmib/librmib.a \
		$(TOP)/agent/gms/libgms.a $(TOP)/agent/smi/libsmisntx.a
KERNELIB =	$(TOP)/kernel/libkernel.a
UTILIB	 =	$(TOP)/util/util/libutil.a
OSILIBS	 =	$(TOP)/msap/libmsap.a $(LT_LIB) \
		$(TOP)/util/sntx/libsntx.a $(X500_LIB) \
		$(ISODE)/libisode$(LPP).a
XTLIBS	 =	-lXm -lXt $(X11) -lX11
TKLIBS	 =	$(TK)/libtcl.a $(TK)/libtk.a $(X11) -lX11

all:		$(PROGS)

prog:		all

install:

install-prog:	install

clean:;		rm -f *.o core $(PROGS)

simagent:	SimAgent.o TestKS.o $(MISLIBS) $(OSILIBS)
		$(PURIFYPLUS) $(CCPLUS) $(LDFLAGS) -o $@ $(CCFLAGS) SimAgent.o TestKS.o \
		$(MISLIBS) $(KERNELIB) $(UTILIB) $(OSILIBS) $(LSOCKET) -lm

simmgr:		SimMgr.o AlarmManager.o $(MISLIBS) $(KERNELIB) $(UTILIB)
		$(PURIFYPLUS) $(CCPLUS) $(LDFLAGS) -o $@ $(CCFLAGS) \
		SimMgr.o AlarmManager.o \
		$(MISLIBS) $(KERNELIB) $(UTILIB) $(OSILIBS) $(LSOCKET) -lm

simos:		SimOS.o $(MISLIBS) $(KERNELIB) $(UTILIB) $(OSILIBS)
		$(PURIFYPLUS) $(CCPLUS) $(LDFLAGS) -o $@ $(CCFLAGS) SimOS.o \
		$(MISLIBS) $(KERNELIB) $(UTILIB) $(OSILIBS) $(LSOCKET) -lm

SimAgent.o:	SimAgent.h TestKS.h
TestKS.o:	TestKS.h

SimMgr.o:	AlarmManager.h
AlarmManager.o:	AlarmManager.h

SimOS.o:	SimOS.h

