Skip to content

Error building elpa: AttributeError: 'Spec' object has no attribute 'mpicc' #6143

@baip

Description

@baip

I was trying to do: spack install elpa %gcc@6.4.0 ^intel-mkl@2018.0.128 ^intel-mpi@2018.0.128 on Rocks cluster 6.2/CentOS 6.6, but in the install phase, it gives the error in the title. The spack-build.out indicates however that the build was successful:

----------------------------------------------------------------------
Libraries have been installed in:
   /share/apps/spack/opt/spack/linux-centos6-x86_64/gcc-7.2.0/elpa-2016.05.004-7r6rtnnke4rasnbmww6thzgdv57b2nmj/lib

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the '-LLIBDIR'
flag during linking and do at least one of the following:
  - add LIBDIR to the 'LD_LIBRARY_PATH' environment variable
    during execution
  - add LIBDIR to the 'LD_RUN_PATH' environment variable
    during linking
  - use the '-Wl,-rpath -Wl,LIBDIR' linker flag
  - have your system administrator add LIBDIR to '/etc/ld.so.conf'

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
 ----------------------------------------------------------------------
/bin/mkdir -p '/share/apps/spack/opt/spack/linux-centos6-x86_64/gcc-7.2.0/elpa-2016.05.004-7r6rtnnke4rasnbmww6thzgdv57b2nmj/bin'
 /bin/sh ./libtool   --mode=install /usr/bin/install -c elpa2_print_kernels '/share/apps/spack/opt/spack/linux-centos6-x86_64/gcc-7.2.0/elpa-2016.05.004-7r6rtnnke4rasnbmww6thzgdv57b2nmj/bin'
libtool: install: /usr/bin/install -c .libs/elpa2_print_kernels /share/apps/spack/opt/spack/linux-centos6-x86_64/gcc-7.2.0/elpa-2016.05.004-7r6rtnnke4rasnbmww6thzgdv57b2nmj/bin/elpa2_print_kernels
make[2]: Leaving directory `/tmp/soft/spack-stage/spack-stage-aaRYV2/elpa-2016.05.004/spack-build'
make[1]: Leaving directory `/tmp/soft/spack-stage/spack-stage-aaRYV2/elpa-2016.05.004/spack-build'

The full error logs are:

==> intel-mkl is already installed in /share/apps/spack/opt/spack/linux-centos6-x86_64/gcc-6.4.0/intel-mkl-2018.0.128-ghtmbtscrmcextiiwijcgh2pv2xftq6r                                       
==> intel-mpi is already installed in /share/apps/spack/opt/spack/linux-centos6-x86_64/gcc-6.4.0/intel-mpi-2018.0.128-hfjbyb3cljw5ej2xtil6vujvjrvywbc2                                       
==> Installing elpa                                                                                                                                                                          
('spec-mpi', ['__class__', '__contains__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__ge__', '__getattribute__', '__getitem__', '__gt__', '__hash__', '__init__', '__le__', '__lt__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_add_dependency', '_add_flag', '_add_version', '_autospec', '_cmp_key', '_cmp_key_cache', '_cmp_node', '_concrete', '_concretize_helper', '_constrain_dependencies', '_dependencies', '_dependents', '_dup', '_dup_deps', '_eq_dag', '_evaluate_dependency_conditions', '_expand_virtual_packages', '_find_deps', '_find_provider', '_hash', '_install_status', '_installed_explicitly', '_mark_concrete', '_merge_dependency', '_normal', '_normalize_helper', '_replace_with', '_set_architecture', '_set_compiler', '_set_test_prefix', 'architecture', 'cformat', 'colorized', 'command', 'common_dependencies', 'compiler', 'compiler_flags', 'concrete', 'concretize', 'concretized', 'constrain', 'constrained', 'copy', 'cshort_spec', 'dag_hash', 'dag_hash_bit_prefix', 'dep_difference', 'dep_string', 'dependencies', 'dependencies_dict', 'dependents', 'dependents_dict', 'eq_dag', 'eq_node', 'external', 'external_module', 'external_path', 'flat_dependencies', 'format', 'from_dict', 'from_json', 'from_literal', 'from_node_dict', 'from_yaml', 'fullname', 'get_dependency', 'headers', 'index', 'is_virtual', 'last_query', 'libs', 'mpicc', 'mpicxx', 'mpif77', 'mpifc', 'name', 'namespace', 'ne_dag', 'ne_node', 'normalize', 'normalized', 'package', 'package_class', 'patches', 'prefix', 'read_yaml_dep_specs', 'root', 'satisfies', 'satisfies_dependencies', 'short_spec', 'sorted_deps', 'to_dict', 'to_json', 'to_node_dict', 'to_yaml', 'traverse', 'traverse_edges', 'tree', 'validate_or_raise', 'variants', 'version', 'versions', 'virtual', 'virtual_dependencies'])
==> Warning: Suspicious requests to set or unset 'CC' found
==> Warning:            env.set('CC', join_path(link_dir, compiler.link_paths['cc'])) at /share/apps/spack/lib/spack/spack/build_environment.py:148
==> Warning:    --->    spack_env.set('CC', spec['mpi'].mpicc) at /share/apps/spack/var/spack/repos/builtin/packages/elpa/package.py:72
==> Warning: Suspicious requests to set or unset 'CXX' found
==> Warning:            env.set('CXX', join_path(link_dir, compiler.link_paths['cxx'])) at /share/apps/spack/lib/spack/spack/build_environment.py:151
==> Warning:    --->    spack_env.set('CXX', spec['mpi'].mpicxx) at /share/apps/spack/var/spack/repos/builtin/packages/elpa/package.py:74
==> Warning: Suspicious requests to set or unset 'FC' found
==> Warning:            env.set('FC', join_path(link_dir, compiler.link_paths['fc'])) at /share/apps/spack/lib/spack/spack/build_environment.py:157
==> Warning:    --->    spack_env.set('FC', spec['mpi'].mpifc) at /share/apps/spack/var/spack/repos/builtin/packages/elpa/package.py:73
==> Using cached archive: /share/apps/spack/var/spack/cache/elpa/elpa-2016.05.004.tar.gz
==> Staging archive: /share/apps/spack/var/spack/stage/elpa-2016.05.004-7r6rtnnke4rasnbmww6thzgdv57b2nmj/elpa-2016.05.004.tar.gz
==> Created stage in /share/apps/spack/var/spack/stage/elpa-2016.05.004-7r6rtnnke4rasnbmww6thzgdv57b2nmj
==> No patches needed for elpa
==> Building elpa [AutotoolsPackage]
==> Executing phase: 'autoreconf'
==> Executing phase: 'configure'
==> Executing phase: 'build'
==> Executing phase: 'install'
('spec-mpi', ['__class__', '__contains__', '__delattr__', '__dict__', '__doc__', '__eq__', '__format__', '__ge__', '__getattribute__', '__getitem__', '__gt__', '__hash__', '__init__', '__le__', '__lt__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_add_dependency', '_add_flag', '_add_version', '_autospec', '_cmp_key', '_cmp_key_cache', '_cmp_node', '_concrete', '_concretize_helper', '_constrain_dependencies', '_dependencies', '_dependents', '_dup', '_dup_deps', '_eq_dag', '_evaluate_dependency_conditions', '_expand_virtual_packages', '_find_deps', '_find_provider', '_hash', '_install_status', '_installed_explicitly', '_mark_concrete', '_merge_dependency', '_normal', '_normalize_helper', '_replace_with', '_set_architecture', '_set_compiler', '_set_test_prefix', 'architecture', 'cformat', 'colorized', 'command', 'common_dependencies', 'compiler', 'compiler_flags', 'concrete', 'concretize', 'concretized', 'constrain', 'constrained', 'copy', 'cshort_spec', 'dag_hash', 'dag_hash_bit_prefix', 'dep_difference', 'dep_string', 'dependencies', 'dependencies_dict', 'dependents', 'dependents_dict', 'eq_dag', 'eq_node', 'external', 'external_module', 'external_path', 'flat_dependencies', 'format', 'from_dict', 'from_json', 'from_literal', 'from_node_dict', 'from_yaml', 'fullname', 'get_dependency', 'headers', 'index', 'is_virtual', 'last_query', 'libs', 'name', 'namespace', 'ne_dag', 'ne_node', 'normalize', 'normalized', 'package', 'package_class', 'patches', 'prefix', 'read_yaml_dep_specs', 'root', 'satisfies', 'satisfies_dependencies', 'short_spec', 'sorted_deps', 'to_dict', 'to_json', 'to_node_dict', 'to_yaml', 'traverse', 'traverse_edges', 'tree', 'validate_or_raise', 'variants', 'version', 'versions', 'virtual', 'virtual_dependencies'])
==> Error: AttributeError: 'Spec' object has no attribute 'mpicc'

/share/apps/spack/var/spack/repos/builtin/packages/elpa/package.py:71, in setup_environment:
     3             spec = self.spec
     4
     5             print('spec-mpi', dir(spec['mpi']))
  >> 6             spack_env.set('CC', spec['mpi'].mpicc)
     7             spack_env.set('FC', spec['mpi'].mpifc)
     8             spack_env.set('CXX', spec['mpi'].mpicxx)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions