# *************************************************************
#       ldi: LOTOS Data Interpreter
# *************************************************************
#***********************************
#  (C) Copyright 1994; dit/upm
#  Distributed under the conditions stated in the
#  TOPO General Public License (see file LICENSE)
#***********************************
#

TOOL=   ldi
TRGT=   libldi.a

INCDIRS= -I$(EPSINC) -I$(TOPOINC)
LIBDIRS= -L$(EPSLIB) -L$(TOPOLIB)
CFLAGS= $(CF_DBX) $(INCDIRS) 
CLIBS= -ldtok -lalga -lcast -lrag

SRCS=	$(TOOL).c intkaos.c 
OBJS=	$(TOOL).o intkaos.o 
HS=	$(TOOL).hh intkaos.hh 

# make target ---------------------------------------

ALL:	$(TRGT) llib-l$(TOOL).ln
	@echo "Done"

$(TRGT):	$(OBJS)
	ar rcv $@ $(OBJS)
	-ranlib libldi.a

# make install -------------------------------------

install::	ldi.hh intkaos.hh
	cp intkaos.hh $(TOPOINC)
	chmod a+r $(TOPOINC)/intkaos.hh
	cp ldi.hh $(TOPOINC)
	chmod a+r $(TOPOINC)/ldi.hh

install::	$(TRGT)
	cp $(TRGT) $(TOPOLIB)
	-cd $(TOPOLIB); ranlib $(TRGT)
	chmod a+r $(TOPOLIB)/$(TRGT)

install::
	touch install

# make clean ---------------------------------------

clean::
	-rm -f $(TRGT) $(OBJS)
	-rm -f core *~
	-rm -f llib-l$(TOOL).ln

#------------------------------------------------------------------
