style: bring packages in compliance with pep8-naming
This commit is contained in:
@@ -46,44 +46,44 @@ class Gslib(Package):
|
||||
conflicts('~mpi', when='+mpiio')
|
||||
|
||||
def install(self, spec, prefix):
|
||||
srcDir = 'src'
|
||||
libDir = 'lib'
|
||||
src_dir = 'src'
|
||||
lib_dir = 'lib'
|
||||
libname = 'libgs.a'
|
||||
|
||||
if self.version == Version('1.0.1'):
|
||||
makeFile = 'Makefile'
|
||||
makefile = 'Makefile'
|
||||
else:
|
||||
makeFile = 'src/Makefile'
|
||||
makefile = 'src/Makefile'
|
||||
|
||||
CC = self.compiler.cc
|
||||
cc = self.compiler.cc
|
||||
|
||||
if '+mpiio' not in spec:
|
||||
filter_file(r'MPIIO.*?=.*1', 'MPIIO = 0', makeFile)
|
||||
filter_file(r'MPIIO.*?=.*1', 'MPIIO = 0', makefile)
|
||||
|
||||
if '+mpi' in spec:
|
||||
CC = spec['mpi'].mpicc
|
||||
cc = spec['mpi'].mpicc
|
||||
else:
|
||||
filter_file(r'MPI.*?=.*1', 'MPI = 0', makeFile)
|
||||
filter_file(r'MPIIO.*?=.*1', 'MPIIO = 0', makeFile)
|
||||
filter_file(r'MPI.*?=.*1', 'MPI = 0', makefile)
|
||||
filter_file(r'MPIIO.*?=.*1', 'MPIIO = 0', makefile)
|
||||
|
||||
makeCmd = "CC=" + CC
|
||||
make_cmd = "CC=" + cc
|
||||
|
||||
if '+blas' in spec:
|
||||
filter_file(r'BLAS.*?=.*0', 'BLAS = 1', makeFile)
|
||||
filter_file(r'BLAS.*?=.*0', 'BLAS = 1', makefile)
|
||||
blas = spec['blas'].libs
|
||||
ldFlags = blas.ld_flags
|
||||
filter_file(r'\$\(LDFLAGS\)', ldFlags, makeFile)
|
||||
ld_flags = blas.ld_flags
|
||||
filter_file(r'\$\(LDFLAGS\)', ld_flags, makefile)
|
||||
|
||||
if self.version == Version('1.0.1'):
|
||||
make(makeCmd)
|
||||
make(make_cmd)
|
||||
make('install')
|
||||
install_tree(libDir, prefix.lib)
|
||||
install_tree(lib_dir, prefix.lib)
|
||||
elif self.version == Version('1.0.0'):
|
||||
with working_dir(srcDir):
|
||||
make(makeCmd)
|
||||
with working_dir(src_dir):
|
||||
make(make_cmd)
|
||||
mkdir(prefix.lib)
|
||||
install(libname, prefix.lib)
|
||||
|
||||
# Should only install the headers (this will be fixed in gslib on
|
||||
# future releases).
|
||||
install_tree(srcDir, prefix.include)
|
||||
install_tree(src_dir, prefix.include)
|
||||
|
Reference in New Issue
Block a user