(doc_install)= # Install :::{note} PETSc is available from multiple package managers. Depending on your exact needs (for example limited use of {any}`external packages `) they are possibly the easiest way for you to install PETSc. Always verify that the package manager is providing a recent enough release of PETSc with support for the external packages you need. Some package managers provide separate packages for the complex number installation of PETSc. - Archlinux - Conda: : `conda install -c conda-forge petsc` - Debian: : `sudo apt install petsc-dev` - Fedora: : `sudo yum install petsc-mpich-devel` - Homebrew: : `brew install petsc` - MacPorts: : `sudo port install petsc` - MSYS2 (Windows) - openSUSE - Python: : `python -m pip install mpi4py petsc petsc4py` - Slackware: - Spack: : - debug install - `spack install petsc +debug` - optimized install -`spack install petsc cflags='-g -O3 -march=native -mtune=native' fflags='-g -O3 -march=native -mtune=native' cxxflags='-g -O3 -march=native -mtune=native'` - install with some external packages - `spack install petsc +superlu-dist +metis +hypre +hdf5` - list available variants (configurations) - `spack info petsc` - Ubuntu: : `sudo apt install petsc-dev` ::: Information and tutorials on setting up a PETSc installation. ```{toctree} :maxdepth: 2 download install_tutorial install windows multibuild external_software license ```