pfft: fix to handle 'precision' variant in fftw (#16029)
* pfft: fix to handle 'precision' variant in fftw pfft had been checking for +double, etc. in fftw spec, which no longer are present (replaced by Multivalued variant precision). * pfft: fix to handle 'precision' variant in fftw pfft had been checking for +double, etc. in fftw spec, which no longer are present (replaced by Multivalued variant precision). (amended to use more idiomatic checks as suggested by @alalazo)
This commit is contained in:
parent
71fb29fccf
commit
e10c134745
@ -27,46 +27,50 @@ def configure(self, spec, prefix):
|
|||||||
|
|
||||||
configure = Executable('../configure')
|
configure = Executable('../configure')
|
||||||
|
|
||||||
if '+double' in spec['fftw']:
|
fftw = spec['fftw']
|
||||||
|
if 'precision=double' in fftw:
|
||||||
with working_dir('double', create=True):
|
with working_dir('double', create=True):
|
||||||
configure(*options)
|
configure(*options)
|
||||||
if '+float' in spec['fftw']:
|
if 'precision=float' in fftw:
|
||||||
with working_dir('float', create=True):
|
with working_dir('float', create=True):
|
||||||
configure('--enable-float', *options)
|
configure('--enable-float', *options)
|
||||||
if '+long_double' in spec['fftw']:
|
if 'precision=long_double' in fftw:
|
||||||
with working_dir('long-double', create=True):
|
with working_dir('long-double', create=True):
|
||||||
configure('--enable-long-double', *options)
|
configure('--enable-long-double', *options)
|
||||||
|
|
||||||
def build(self, spec, prefix):
|
def build(self, spec, prefix):
|
||||||
if '+double' in spec['fftw']:
|
fftw = spec['fftw']
|
||||||
|
if 'precision=double' in fftw:
|
||||||
with working_dir('double'):
|
with working_dir('double'):
|
||||||
make()
|
make()
|
||||||
if '+float' in spec['fftw']:
|
if 'precision=float' in fftw:
|
||||||
with working_dir('float'):
|
with working_dir('float'):
|
||||||
make()
|
make()
|
||||||
if '+long_double' in spec['fftw']:
|
if 'precision=long_double' in fftw:
|
||||||
with working_dir('long-double'):
|
with working_dir('long-double'):
|
||||||
make()
|
make()
|
||||||
|
|
||||||
def check(self):
|
def check(self):
|
||||||
spec = self.spec
|
spec = self.spec
|
||||||
if '+double' in spec['fftw']:
|
fftw = spec['fftw']
|
||||||
|
if 'precision=double' in fftw:
|
||||||
with working_dir('double'):
|
with working_dir('double'):
|
||||||
make("check")
|
make("check")
|
||||||
if '+float' in spec['fftw']:
|
if 'precision=float' in fftw:
|
||||||
with working_dir('float'):
|
with working_dir('float'):
|
||||||
make("check")
|
make("check")
|
||||||
if '+long_double' in spec['fftw']:
|
if 'precision=long_double' in fftw:
|
||||||
with working_dir('long-double'):
|
with working_dir('long-double'):
|
||||||
make("check")
|
make("check")
|
||||||
|
|
||||||
def install(self, spec, prefix):
|
def install(self, spec, prefix):
|
||||||
if '+double' in spec['fftw']:
|
fftw = spec['fftw']
|
||||||
|
if 'precision=double' in fftw:
|
||||||
with working_dir('double'):
|
with working_dir('double'):
|
||||||
make("install")
|
make("install")
|
||||||
if '+float' in spec['fftw']:
|
if 'precision=float' in fftw:
|
||||||
with working_dir('float'):
|
with working_dir('float'):
|
||||||
make("install")
|
make("install")
|
||||||
if '+long_double' in spec['fftw']:
|
if 'precision=long_double' in fftw:
|
||||||
with working_dir('long-double'):
|
with working_dir('long-double'):
|
||||||
make("install")
|
make("install")
|
||||||
|
Loading…
Reference in New Issue
Block a user