# Makefile for eispack

srcdir =	@srcdir@
VPATH =		@srcdir@

prefix =	@prefix@
exec_prefix =	@exec_prefix@

bindir =	$(exec_prefix)/bin
libdir =	$(exec_prefix)/lib
incdir =	$(prefix)/include
infodir =	$(prefix)/info

INSTALL =	@INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA =	@INSTALL_DATA@

SHELL =		/bin/sh
CC =		@CC@
FC =		f77
AR =		ar
RM =		rm
RANLIB =	@RANLIB@
DEFS =		@DEFS@
LIBS =		@LIBS@
CFLAGS =	@CFLAGS@
LDFLAGS =	@LDFLAGS@
FFLAGS =	-O

LIB =		libeispack.a

OBJ =		bakvec.o balanc.o balbak.o bandr.o bandv.o bisect.o bqr.o \
		cbabk2.o cbal.o cdiv.o cg.o ch.o cinvit.o combak.o comhes.o \
		comlr.o comlr2.o comqr.o comqr2.o cortb.o corth.o csroot.o \
		elmbak.o elmhes.o eltran.o epslon.o figi.o figi2.o hqr.o \
		hqr2.o htrib3.o htribk.o htrid3.o htridi.o imtql1.o imtql2.o \
		imtqlv.o invit.o minfit.o ortbak.o orthes.o ortran.o \
		otqlrat.o pythag.o qzhes.o qzit.o qzval.o qzvec.o ratqr.o \
		rebak.o rebakb.o reduc.o reduc2.o rg.o rgg.o rs.o rsb.o rsg.o \
		rsgab.o rsgba.o rsm.o rsp.o rst.o rt.o svd.o tinvit.o tql1.o \
		tql2.o tqlrat.o trbak1.o trbak3.o tred1.o tred2.o tred3.o \
		tridib.o tsturm.o

#
# The default thing to do is remake the library and the test programs.
#

all :		$(LIB) buildtests

$(LIB) :	$(OBJ)
		$(AR) crv $@ $(OBJ)
		$(RANLIB) $(LIB)

buildtests :	$(LIB)
		(cd tests; $(MAKE) all)

#
# Clean up the local directory.
#

clean :
		rm -f *~ *! *.BAK nohup.out

clobber :	clean
		$(RM) -f *.o $(LIB)
		$(RM) -f config.status configure Makefile

#
# Install the link time library.
#

install :	$(LIB)
		-if test -d $(libdir) ;then true ;else mkdir $(libdir) ;fi
		$(INSTALL_DATA) $(LIB) $(libdir)/$(LIB)
		$(RANLIB) $(libdir)/$(LIB)

#
# Normally the source distribution includes a few files that
# are created from other "pure source" files, like "configure"
# for example.

srcdist :
		autoconf
