| 1 | #
|
|---|
| 2 | # Makefile
|
|---|
| 3 | #
|
|---|
| 4 | # Copyright (C) 1996 Limit Point Systems, Inc.
|
|---|
| 5 | #
|
|---|
| 6 | # Author: Curtis Janssen <cljanss@ca.sandia.gov>
|
|---|
| 7 | # Maintainer: LPS
|
|---|
| 8 | #
|
|---|
| 9 | # This file is part of the SC Toolkit.
|
|---|
| 10 | #
|
|---|
| 11 | # The SC Toolkit is free software; you can redistribute it and/or modify
|
|---|
| 12 | # it under the terms of the GNU Library General Public License as published by
|
|---|
| 13 | # the Free Software Foundation; either version 2, or (at your option)
|
|---|
| 14 | # any later version.
|
|---|
| 15 | #
|
|---|
| 16 | # The SC Toolkit is distributed in the hope that it will be useful,
|
|---|
| 17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|---|
| 19 | # GNU Library General Public License for more details.
|
|---|
| 20 | #
|
|---|
| 21 | # You should have received a copy of the GNU Library General Public License
|
|---|
| 22 | # along with the SC Toolkit; see the file COPYING.LIB. If not, write to
|
|---|
| 23 | # the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
|
|---|
| 24 | #
|
|---|
| 25 | # The U.S. Government is granted a limited license as per AL 91-7.
|
|---|
| 26 | #
|
|---|
| 27 |
|
|---|
| 28 | TOPDIR=../../../..
|
|---|
| 29 | ifndef SRCDIR
|
|---|
| 30 | SRCDIR=$(shell pwd)
|
|---|
| 31 | endif
|
|---|
| 32 |
|
|---|
| 33 | include $(SRCDIR)/$(TOPDIR)/lib/GlobalMakefile
|
|---|
| 34 | DEFINES += -DSRCDIR=\"$(SRCDIR)\"
|
|---|
| 35 |
|
|---|
| 36 | CLASS2TEXFLAGS = -clssection subsection -clssubsection subsubsection
|
|---|
| 37 |
|
|---|
| 38 | default:: $(DEPENDINCLUDE)
|
|---|
| 39 |
|
|---|
| 40 | CXXSRC = dim.cc \
|
|---|
| 41 | abstract.cc matrix.cc matrix_i.cc \
|
|---|
| 42 | block.cc blkiter.cc elemop.cc result.cc \
|
|---|
| 43 | local.cc localrect.cc localdiag.cc localsymm.cc localvect.cc \
|
|---|
| 44 | disthql.cc \
|
|---|
| 45 | dist.cc distrect.cc distdiag.cc distsymm.cc distvect.cc \
|
|---|
| 46 | repl.cc replrect.cc repldiag.cc replsymm.cc replvect.cc \
|
|---|
| 47 | blocked.cc \
|
|---|
| 48 | blockedvect.cc blockedrect.cc blockeddiag.cc blockedsymm.cc \
|
|---|
| 49 | matrix3.cc vector3.cc vector3_i.cc \
|
|---|
| 50 | util.cc
|
|---|
| 51 |
|
|---|
| 52 | TESTSRC = disttest.cc localtest.cc repltest.cc blockedtest.cc
|
|---|
| 53 |
|
|---|
| 54 | TESTPROGS = disttest localtest repltest blockedtest
|
|---|
| 55 |
|
|---|
| 56 | CSRC = cmatrix.c svd.c
|
|---|
| 57 |
|
|---|
| 58 | FSRC = pdsteqr.f
|
|---|
| 59 |
|
|---|
| 60 | LIBOBJ = $(CXXSRC:%.cc=%.$(OBJSUF)) $(CSRC:%.c=%.$(OBJSUF)) $(FSRC:%.f=%.$(OBJSUF))
|
|---|
| 61 |
|
|---|
| 62 | INC = cmatrix.h matrix_i.h cmatrix.h matrix.h abstract.h blkiter.h local.h \
|
|---|
| 63 | result.h vector3.h vector3_i.h block.h matrix3.h elemop.h repl.h \
|
|---|
| 64 | blocked.h disthql.h dim.h
|
|---|
| 65 |
|
|---|
| 66 | GENINC =
|
|---|
| 67 |
|
|---|
| 68 | DEPENDINCLUDE = $(INC) $(GENINC)
|
|---|
| 69 |
|
|---|
| 70 | BIN_OR_LIB = LIB
|
|---|
| 71 | TARGET_TO_MAKE = libSCscmat
|
|---|
| 72 |
|
|---|
| 73 | TESTOBJ = matrixtest.$(OBJSUF)
|
|---|
| 74 |
|
|---|
| 75 | DISTFILES = $(CXXSRC) $(INC) scmat.h $(WEBSRC) Makefile LIBS.h \
|
|---|
| 76 | $(TESTSRC) $(TESTFILES)
|
|---|
| 77 |
|
|---|
| 78 | LIBS = $(shell $(LISTLIBS) $(INCLUDE) $(SRCDIR)/LIBS.h)
|
|---|
| 79 |
|
|---|
| 80 | matrixtest:
|
|---|
| 81 | @echo The target must be a specialization such as localtest.
|
|---|
| 82 |
|
|---|
| 83 | localtest: localtest.$(OBJSUF) $(TESTOBJ) $(LIBS)
|
|---|
| 84 | $(LTLINK) $(LD) $(LDFLAGS) -o localtest $^ $(SYSLIBS) $(LTLINKBINOPTS)
|
|---|
| 85 |
|
|---|
| 86 | repltest: repltest.$(OBJSUF) $(TESTOBJ) $(LIBS)
|
|---|
| 87 | $(LTLINK) $(LD) $(LDFLAGS) -o repltest $^ $(SYSLIBS) $(LTLINKBINOPTS)
|
|---|
| 88 |
|
|---|
| 89 | disttest: disttest.$(OBJSUF) $(TESTOBJ) $(LIBS)
|
|---|
| 90 | $(LTLINK) $(LD) $(LDFLAGS) -o disttest $^ $(SYSLIBS) $(LTLINKBINOPTS)
|
|---|
| 91 |
|
|---|
| 92 | blockedtest: blockedtest.$(OBJSUF) $(TESTOBJ) $(LIBS)
|
|---|
| 93 | $(LTLINK) $(LD) $(LDFLAGS) -o blockedtest $^ $(SYSLIBS) $(LTLINKBINOPTS)
|
|---|
| 94 |
|
|---|
| 95 | repltest.$(OBJSUF): repltest.cc
|
|---|
| 96 | $(LTCOMP) $(CXX) $(CPPFLAGS) $(CXXFLAGS) -DSRCDIR=\"$(SRCDIR)\" -c $< -o $@
|
|---|
| 97 |
|
|---|
| 98 | disttest.$(OBJSUF): disttest.cc
|
|---|
| 99 | $(LTCOMP) $(CXX) $(CPPFLAGS) $(CXXFLAGS) -DSRCDIR=\"$(SRCDIR)\" -c $< -o $@
|
|---|
| 100 |
|
|---|
| 101 | TAGS: $(CXXSRC) $(CSRC)
|
|---|
| 102 | etags $^
|
|---|
| 103 |
|
|---|
| 104 | disthql.$(OBJSUF) disthql.d: f77sym.h
|
|---|
| 105 |
|
|---|
| 106 | f77sym.h: f77sym.in
|
|---|
| 107 | $(MKF77SYM) $< $@
|
|---|
| 108 |
|
|---|
| 109 | include $(SRCDIR)/$(TOPDIR)/lib/GlobalRules
|
|---|
| 110 |
|
|---|
| 111 | distclean::
|
|---|
| 112 | /bin/rm -f f77sym.h
|
|---|
| 113 |
|
|---|
| 114 | $(LIBOBJ:.$(OBJSUF)=.d): $(DEPENDINCLUDE)
|
|---|
| 115 | ifneq ($(DODEPEND),no)
|
|---|
| 116 | include $(CXXSRC:.cc=.d) $(CSRC:.c=.d) $(TESTSRC:%.cc=%.d)
|
|---|
| 117 | endif
|
|---|
| 118 |
|
|---|