Explicitly import package utilities in all packages, and corresponding fallout.
This includes:
* rename `spack.package` to `spack.package_base`
* rename `spack.pkgkit` to `spack.package`
* update all packages in builtin, builtin_mock and tutorials to include `from spack.package import *`
* update spack style
* ensure packages include the import
* automatically add the new import and remove any/all imports of `spack` and `spack.pkgkit`
from packages when using `--fix`
* add support for type-checking packages with mypy when SPACK_MYPY_CHECK_PACKAGES
is set in the environment
* fix all type checking errors in packages in spack upstream
* update spack create to include the new imports
* update spack repo to inject the new import, injection persists to allow for a deprecation period
Original message below:
As requested @adamjstewart, update all packages to use pkgkit. I ended up using isort to do this,
so repro is easy:
```console
$ isort -a 'from spack.pkgkit import *' --rm 'spack' ./var/spack/repos/builtin/packages/*/package.py
$ spack style --fix
```
There were several line spacing fixups caused either by space manipulation in isort or by packages
that haven't been touched since we added requirements, but there are no functional changes in here.
* [x] add config to isort to make sure this is maintained going forward
* fix remaining flake8 errors
* imports: sort imports everywhere in Spack
We enabled import order checking in #23947, but fixing things manually drives
people crazy. This used `spack style --fix --all` from #24071 to automatically
sort everything in Spack so PR submitters won't have to deal with it.
This should go in after #24071, as it assumes we're using `isort`, not
`flake8-import-order` to order things. `isort` seems to be more flexible and
allows `llnl` mports to be in their own group before `spack` ones, so this
seems like a good switch.
- [x] add `concretize.lp`, `spack.yaml`, etc. to licensed files
- [x] update all licensed files to say 2013-2021 using
`spack license update-copyright-year`
- [x] appease mypy with some additions to package.py that needed
for oneapi.py
- remove the old LGPL license headers from all files in Spack
- add SPDX headers to all files
- core and most packages are (Apache-2.0 OR MIT)
- a very small number of remaining packages are LGPL-2.1-only
* Added a package for the MDAnalysis toolkit.
* Added some flags to fix the build RPATHs and OpenMP for LBANN on OS X.
* Fixed Hydrogen branch of Elemental to find OpenMP on OS X.
* Added a package for the MDAnalysis toolkit.
* Added a patch that allows Elemental to use cuBLAS internally.
* Added support for LBANN to use the new cuBLAS extension in Elemental.
* Added a proper variant for when LBANN does not want to use cuBLAS in
elemental.
* Added a package for the cnpy project and used it in the lbann package.
* Removed unnecessary comment lines.
* Removed blank lines
* Removed debug variant
* Add support for libjpeg-turbo
* Added additional variants for OpenCV features. Fixed bug when linking
in TIFF support, where libtiff used the regular JPEG library and
OpenCV used libjpeg-turbo. Now libtiff can use libjpeg-turbo.
* Removed the variant for getting Elemental to use the cublas variant.
Updated the requirements for OpenCV to add new options.
* Fixed a flake8 error in OpenCV and added a path to find cnpy in lbann.
* Fixed line too long flake8 error.
* Added a flag to specify the datatype size in lbann and fixed a flake8 error.
* Added a debug build variant using hte new build_type
* Fixed flake8
* Fixed how the debug build is pushed to Elemental
* Fixed a bug in the Elemental package where the blas search flags were
being overridden by the blas link flags. Changed how the sequential
initialization variant is implemented in LBANN.
* Added support via a variant to explicitly use mkl or openblas. This
helps work around variant forwarding problems.
* Updated package files to address pull request comments.