See also

You will need to understand how to use the terminal.


Our spack package is still in beta state and is continuously improved. Please feel free to report any issues that you might encounter.


Section author: Axel Huebl


First install spack itself via:

# get spack
git clone $HOME/src/spack

# activate the spack environment
source $HOME/src/spack/share/spack/

# install a supported compiler
spack compiler list | grep -q gcc@7.3.0 || spack install gcc@7.3.0 && spack load gcc@7.3.0 && spack compiler add

# add the PIConGPU repository
git clone $HOME/src/spack-repo
spack repo add $HOME/src/spack-repo


When you open a terminal next time or log back into the machine, make sure to activate the spack environment again via:

source $HOME/src/spack/share/spack/


The installation of the latest version of PIConGPU is now as easy as:

spack install picongpu %gcc@7.3.0


PIConGPU can now be loaded with

spack load picongpu

For more information on variants of the picongpu package in spack run spack info picongpu and refer to the official spack documentation.


PIConGPU can also run without a GPU! For example, to use our OpenMP backend, just add backend=omp2b to the two commands above:

spack install picongpu backend=omp2b
spack load picongpu backend=omp2b


If the install fails or you want to compile for CUDA 9.2, try using GCC 5.5.0:

spack compiler list | grep gcc@5.5.0 | spack install gcc@5.5.0 && spack load gcc@5.5.0 && spack compiler add
spack install picongpu %gcc@5.5.0
spack load picongpu %gcc@5.5.0