Subversion Repositories slepc-dev

Rev

Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1377 slepc 1
#
2
#  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1672 slepc 3
#  SLEPc - Scalable Library for Eigenvalue Problem Computations
4
#  Copyright (c) 2002-2009, Universidad Politecnica de Valencia, Spain
1377 slepc 5
#
1672 slepc 6
#  This file is part of SLEPc.
7
#    
8
#  SLEPc is free software: you can redistribute it and/or modify it under  the
9
#  terms of version 3 of the GNU Lesser General Public License as published by
10
#  the Free Software Foundation.
11
#
12
#  SLEPc  is  distributed in the hope that it will be useful, but WITHOUT  ANY
13
#  WARRANTY;  without even the implied warranty of MERCHANTABILITY or  FITNESS
14
#  FOR  A  PARTICULAR PURPOSE. See the GNU Lesser General Public  License  for
15
#  more details.
16
#
17
#  You  should have received a copy of the GNU Lesser General  Public  License
18
#  along with SLEPc. If not, see <http://www.gnu.org/licenses/>.
1377 slepc 19
#  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
20
#
21
 
808 dsic.upv.es!antodo 22
import os
23
import sys
24
 
912 dsic.upv.es!antodo 25
import petscconf
26
import check
808 dsic.upv.es!antodo 27
 
912 dsic.upv.es!antodo 28
def Check(conf,directory,libs):
808 dsic.upv.es!antodo 29
 
912 dsic.upv.es!antodo 30
  if petscconf.SCALAR == 'complex':
808 dsic.upv.es!antodo 31
    sys.exit('ERROR: TRLAN does not support complex numbers.')
32
 
912 dsic.upv.es!antodo 33
  if petscconf.PRECISION == 'single':
808 dsic.upv.es!antodo 34
    sys.exit('ERROR: TRLAN does not support single precision.')
35
 
36
  functions = ['trlan77']
912 dsic.upv.es!antodo 37
  if libs:
38
    libs = [libs]
808 dsic.upv.es!antodo 39
  else:
1651 slepc 40
    libs = [['-ltrlan_mpi']]
808 dsic.upv.es!antodo 41
 
42
  if directory:
43
    dirs = [directory]
44
  else:
912 dsic.upv.es!antodo 45
    dirs = check.GenerateGuesses('TRLan')
808 dsic.upv.es!antodo 46
 
912 dsic.upv.es!antodo 47
  return check.FortranLib(conf,'TRLAN',dirs,libs,functions)