spack/var/spack/repos/builtin/packages/ppopen-appl-dem-util/package.py
Todd Gamblin a8ccb8e116 copyrights: update all files with license headers for 2021
- [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
2021-01-02 12:12:00 -08:00

51 lines
1.7 KiB
Python
Executable File

# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
class PpopenApplDemUtil(MakefilePackage):
"""
ppOpen-APPL/DEM provides fundamental components of the particle
simulations based on the discrete element method (DEM).
ppOpen-APPL/DEM (ver.1.0.0) includes the libraries for the DEM,
sample codes, and data sets. ppOpen-APPL/DEM-Util provides the
preconditioning utilities. This utility prepares data sets of distributed
data files from the mesh data sets.
"""
homepage = "http://ppopenhpc.cc.u-tokyo.ac.jp/ppopenhpc/"
git = "https://github.com/Post-Peta-Crest/ppOpenHPC.git"
version('master', branch='APPL/DEM')
depends_on('mpi')
def edit(self, spec, prefix):
mkdirp('bin')
mkdirp('lib')
mkdirp('include')
makefile_in = FileFilter('Makefile.in')
makefile_in.filter('PREFIX += .*', 'PREFIX = {0}'.format(prefix))
makefile_in.filter('F90 += .*', 'F90 = {0}'.format(spack_fc))
makefile_in.filter('F77 += .*', 'F77 = {0}'.format(spack_fc))
makefile_in.filter(
'MPIF90 += .*',
'MPIF90 = {0}'.format(spec['mpi'].mpifc)
)
makefile_in.filter(
'MPIF77 += .*',
'MPIF77 = {0}'.format(spec['mpi'].mpifc)
)
makefile_in.filter(
'F90MPFLAGS += .*',
'F90MPFLAGS = -O3 {0}'.format(self.compiler.openmp_flag)
)
def install(self, spec, prefix):
make('install')
install_tree('doc', prefix.doc)