py-python-meep: remove install_options (#28461)

* py-python-meep: remove install_options

* Remove unused import
This commit is contained in:
Adam J. Stewart 2022-01-19 05:27:38 -06:00 committed by GitHub
parent e6ba8eb060
commit d6c841f67c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
from spack import *
@ -38,31 +36,3 @@ class PyPythonMeep(PythonPackage):
def patch(self):
if '+mpi' in self.spec:
copy('setup-mpi.py', 'setup.py')
def install_options(self, spec, prefix):
include_dirs = [
spec['meep'].prefix.include,
os.path.join(
spec['py-numpy'].prefix,
spec['python'].package.include
)
]
library_dirs = [
spec['meep'].prefix.lib
]
if '+mpi' in spec:
include_dirs.append(spec['mpi'].prefix.include)
library_dirs.append(spec['mpi'].prefix.lib)
include_flags = '-I{0}'.format(','.join(include_dirs))
library_flags = '-L{0}'.format(','.join(library_dirs))
# FIXME: For some reason, this stopped working.
# The -I and -L are no longer being properly forwarded to setup.py:
# meep_common.i:87: Error: Unable to find 'meep/mympi.hpp'
# meep_common.i:88: Error: Unable to find 'meep/vec.hpp'
# meep_common.i:89: Error: Unable to find 'meep.hpp'
return [include_flags, library_flags]